Merge branch '3.3.x'

This commit is contained in:
Marc Alexander 2022-04-30 23:02:13 +02:00
commit 5f7ce9b66a
No known key found for this signature in database
GPG key ID: 50E0D2423696F995
3 changed files with 15 additions and 13 deletions

View file

@ -396,11 +396,12 @@ class ucp_main
if ($row['forum_last_post_id']) if ($row['forum_last_post_id'])
{ {
$last_post_time = $user->format_date($row['forum_last_post_time']); $last_post_time = $user->format_date($row['forum_last_post_time']);
$last_post_time_rfc3339 = gmdate(DATE_RFC3339, $row['forum_last_post_time']);
$last_post_url = append_sid("{$phpbb_root_path}viewtopic.$phpEx", "p=" . $row['forum_last_post_id']) . '#p' . $row['forum_last_post_id']; $last_post_url = append_sid("{$phpbb_root_path}viewtopic.$phpEx", "p=" . $row['forum_last_post_id']) . '#p' . $row['forum_last_post_id'];
} }
else else
{ {
$last_post_time = $last_post_url = ''; $last_post_time = $last_post_time_rfc3339 = $last_post_url = '';
} }
$template_vars = array( $template_vars = array(
@ -413,6 +414,7 @@ class ucp_main
'FORUM_DESC' => generate_text_for_display($row['forum_desc'], $row['forum_desc_uid'], $row['forum_desc_bitfield'], $row['forum_desc_options']), 'FORUM_DESC' => generate_text_for_display($row['forum_desc'], $row['forum_desc_uid'], $row['forum_desc_bitfield'], $row['forum_desc_options']),
'LAST_POST_SUBJECT' => $row['forum_last_post_subject'], 'LAST_POST_SUBJECT' => $row['forum_last_post_subject'],
'LAST_POST_TIME' => $last_post_time, 'LAST_POST_TIME' => $last_post_time,
'LAST_POST_TIME_RFC3339' => $last_post_time_rfc3339,
'LAST_POST_AUTHOR' => get_username_string('username', $row['forum_last_poster_id'], $row['forum_last_poster_name'], $row['forum_last_poster_colour']), 'LAST_POST_AUTHOR' => get_username_string('username', $row['forum_last_poster_id'], $row['forum_last_poster_name'], $row['forum_last_poster_colour']),
'LAST_POST_AUTHOR_COLOUR' => get_username_string('colour', $row['forum_last_poster_id'], $row['forum_last_poster_name'], $row['forum_last_poster_colour']), 'LAST_POST_AUTHOR_COLOUR' => get_username_string('colour', $row['forum_last_poster_id'], $row['forum_last_poster_name'], $row['forum_last_poster_colour']),

View file

@ -104,7 +104,7 @@
{{ Icon('iconify', 'mdi:alert-decagram', lang('POSTS_UNAPPROVED_FORUM'), true, 'c-unapproved-icon') }} {{ Icon('iconify', 'mdi:alert-decagram', lang('POSTS_UNAPPROVED_FORUM'), true, 'c-unapproved-icon') }}
</a> </a>
<!-- ENDIF --> <!-- ENDIF -->
<!-- IF forumrow.LAST_POST_TIME --> <!-- IF forumrow.LAST_POST_TIME_RFC3339 -->
<dfn>{L_LAST_POST}</dfn> <dfn>{L_LAST_POST}</dfn>
<!-- IF forumrow.S_DISPLAY_SUBJECT --> <!-- IF forumrow.S_DISPLAY_SUBJECT -->
<!-- EVENT forumlist_body_last_post_title_prepend --> <!-- EVENT forumlist_body_last_post_title_prepend -->

View file

@ -43,12 +43,12 @@
</div> </div>
</dt> </dt>
<dd class="lastpost"> <dd class="lastpost">
<!-- IF forumrow.LAST_POST_TIME --> <!-- IF forumrow.LAST_POST_TIME_RFC3339 -->
<span><dfn>{L_LAST_POST} </dfn>{L_POST_BY_AUTHOR} {forumrow.LAST_POST_AUTHOR_FULL} <span><dfn>{L_LAST_POST} </dfn>{L_POST_BY_AUTHOR} {forumrow.LAST_POST_AUTHOR_FULL}
<a href="{forumrow.U_LAST_POST}"> <a href="{forumrow.U_LAST_POST}">
{{ Icon('iconify', 'fa:external-link-square', VIEW_LATEST_POST, true, 'c-last-post-icon') }} {{ Icon('iconify', 'fa:external-link-square', VIEW_LATEST_POST, true, 'c-last-post-icon') }}
</a> </a>
<br />{forumrow.LAST_POST_TIME}</span> <br /><time datetime="{forumrow.LAST_POST_TIME_RFC3339}">{forumrow.LAST_POST_TIME}</time></span>
<!-- ELSE --> <!-- ELSE -->
{L_NO_POSTS}<br />&nbsp; {L_NO_POSTS}<br />&nbsp;
<!-- ENDIF --> <!-- ENDIF -->