diff --git a/.htaccess b/.htaccess index 53bce76..0be28ab 100644 --- a/.htaccess +++ b/.htaccess @@ -36,6 +36,13 @@ RewriteRule ^(.*)$ app.php [QSA,L] #Options +FollowSymLinks +# Apache content negotation tries to interpret non-existent paths as files if +# MultiViews is enabled. This will however cause issues with paths containg +# dots, e.g. for the cron tasks + + Options -MultiViews + + # With Apache 2.4 the "Order, Deny" syntax has been deprecated and moved from # module mod_authz_host to a new module called mod_access_compat (which may be # disabled) and a new "Require" syntax has been introduced to mod_authz_host. diff --git a/adm/images/phpbb_logo.svg b/adm/images/phpbb_logo.svg new file mode 100644 index 0000000..2a24106 --- /dev/null +++ b/adm/images/phpbb_logo.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/adm/index.php b/adm/index.php index d27f56f..c648fdf 100644 --- a/adm/index.php +++ b/adm/index.php @@ -49,7 +49,6 @@ if (!$auth->acl_get('a_')) define('IN_ADMIN', true); // Some oft used variables -$safe_mode = (@ini_get('safe_mode') == '1' || strtolower(@ini_get('safe_mode')) === 'on') ? true : false; $file_uploads = (@ini_get('file_uploads') == '1' || strtolower(@ini_get('file_uploads')) === 'on') ? true : false; $module_id = $request->variable('i', ''); $mode = $request->variable('mode', ''); diff --git a/adm/style/acp_attachments.html b/adm/style/acp_attachments.html index 868e256..7a66f17 100644 --- a/adm/style/acp_attachments.html +++ b/adm/style/acp_attachments.html @@ -110,7 +110,7 @@ -

-

@@ -52,7 +54,11 @@

- + {% for providers in providers %} + {% for values in providers.values %} + + {% endfor %} + {% endfor %}

diff --git a/adm/style/acp_icons.html b/adm/style/acp_icons.html index 5493cbd..45fe7f8 100644 --- a/adm/style/acp_icons.html +++ b/adm/style/acp_icons.html @@ -4,7 +4,7 @@ - - + « {L_BACK} diff --git a/adm/style/acp_posting_buttons.html b/adm/style/acp_posting_buttons.html index c3c42f8..614d6fa 100644 --- a/adm/style/acp_posting_buttons.html +++ b/adm/style/acp_posting_buttons.html @@ -1,31 +1,10 @@ - @@ -65,7 +44,7 @@ - + diff --git a/adm/style/acp_ranks.html b/adm/style/acp_ranks.html index e67c9ac..d373657 100644 --- a/adm/style/acp_ranks.html +++ b/adm/style/acp_ranks.html @@ -6,7 +6,7 @@ « {L_BACK} - -
+
diff --git a/adm/style/installer_footer.html b/adm/style/installer_footer.html index fefa8f6..81a85d1 100644 --- a/adm/style/installer_footer.html +++ b/adm/style/installer_footer.html @@ -6,12 +6,14 @@ - - - - + + + {$SCRIPTS} diff --git a/adm/style/overall_footer.html b/adm/style/overall_footer.html index 8745286..7a5b620 100644 --- a/adm/style/overall_footer.html +++ b/adm/style/overall_footer.html @@ -33,9 +33,9 @@ - - - + + + diff --git a/adm/style/overall_header.html b/adm/style/overall_header.html index 8279ac3..fa361d6 100644 --- a/adm/style/overall_header.html +++ b/adm/style/overall_header.html @@ -10,7 +10,7 @@ - - +
diff --git a/adm/style/permissions.js b/adm/style/permissions.js index 9178ada..af8e21a 100644 --- a/adm/style/permissions.js +++ b/adm/style/permissions.js @@ -279,6 +279,10 @@ function reset_role(id) { } t.options[0].selected = true; + + var parent = t.parentNode; + parent.querySelector('span.dropdown-trigger').innerText = no_role_assigned; + parent.querySelector('input[data-name^=role]').value = '0'; } /** diff --git a/adm/style/progress_bar.html b/adm/style/progress_bar.html index 1822675..1e58257 100644 --- a/adm/style/progress_bar.html +++ b/adm/style/progress_bar.html @@ -1,6 +1,6 @@ - - - + + + {$SCRIPTS} diff --git a/adm/style/simple_header.html b/adm/style/simple_header.html index 439645a..a8a32bf 100644 --- a/adm/style/simple_header.html +++ b/adm/style/simple_header.html @@ -9,7 +9,7 @@ - -
- - + + {% INCLUDEJS RECAPTCHA_SERVER ~ '.js?onload=phpbbRecaptchaOnLoad&hl=' ~ lang('RECAPTCHA_LANG') %} +
{L_RECAPTCHA_NOT_AVAILABLE} - - -
- - - diff --git a/styles/prosilver/template/forum_fn.js b/styles/prosilver/template/forum_fn.js index 3f28f8a..2e39365 100644 --- a/styles/prosilver/template/forum_fn.js +++ b/styles/prosilver/template/forum_fn.js @@ -460,7 +460,7 @@ function parseDocument($container) { $linksLast = $linksNotSkip.filter(filterLast), // The items that will be hidden last persistent = $this.attr('id') === 'nav-main', // Does this list already have a menu (such as quick-links)? html = '', - slack = 3; // Vertical slack space (in pixels). Determines how sensitive the script is in determining whether a line-break has occured. + slack = 3; // Vertical slack space (in pixels). Determines how sensitive the script is in determining whether a line-break has occurred. // Add a hidden drop-down menu to each links list (except those that already have one) if (!persistent) { diff --git a/styles/prosilver/template/forumlist_body.html b/styles/prosilver/template/forumlist_body.html index 8250a1f..4932860 100644 --- a/styles/prosilver/template/forumlist_body.html +++ b/styles/prosilver/template/forumlist_body.html @@ -101,7 +101,7 @@ {L_VIEW_LATEST_POST} -
{forumrow.LAST_POST_TIME} +
{% if forumrow.U_UNAPPROVED_TOPICS %} {{ lang('TOPIC_UNAPPROVED_FORUM', forumrow.TOPICS) }} diff --git a/styles/prosilver/template/mcp_forum.html b/styles/prosilver/template/mcp_forum.html index f6c518e..82df5d5 100644 --- a/styles/prosilver/template/mcp_forum.html +++ b/styles/prosilver/template/mcp_forum.html @@ -86,7 +86,9 @@
+ {% EVENT topiclist_row_topic_by_author_before %} {L_POST_BY_AUTHOR} {topicrow.TOPIC_AUTHOR_FULL} » {topicrow.FIRST_POST_TIME} + {% EVENT topiclist_row_topic_by_author_after %}
diff --git a/styles/prosilver/template/mcp_move.html b/styles/prosilver/template/mcp_move.html index 45a9ae8..63197ef 100644 --- a/styles/prosilver/template/mcp_move.html +++ b/styles/prosilver/template/mcp_move.html @@ -43,12 +43,14 @@

{ADDITIONAL_MSG}

+ {% EVENT mcp_move_destination_forum_before %}
+ {% EVENT mcp_move_destination_forum_after %}
 
{MESSAGE_TEXT}
diff --git a/styles/prosilver/template/mcp_topic.html b/styles/prosilver/template/mcp_topic.html index b56ed18..889cab8 100644 --- a/styles/prosilver/template/mcp_topic.html +++ b/styles/prosilver/template/mcp_topic.html @@ -118,9 +118,9 @@

- + {postrow.MINI_POST} - {L_POSTED} {postrow.POST_DATE} {L_POST_BY_AUTHOR} {postrow.POST_AUTHOR_FULL} [ {L_POST_DETAILS} ] + {L_POSTED} {postrow.POST_DATE} {L_POST_BY_AUTHOR} {% EVENT mcp_topic_post_author_full_prepend %}{postrow.POST_AUTHOR_FULL}{% EVENT mcp_topic_post_author_full_append %} [ {L_POST_DETAILS} ]

diff --git a/styles/prosilver/template/memberlist_body.html b/styles/prosilver/template/memberlist_body.html index 5f03ad9..b8ff092 100644 --- a/styles/prosilver/template/memberlist_body.html +++ b/styles/prosilver/template/memberlist_body.html @@ -28,8 +28,13 @@

{AVATAR_IMG} {% EVENT memberlist_body_group_rank_before %} - {RANK_IMG} - {GROUP_RANK} + {% if RANK_IMG %}{{ RANK_IMG }}{% endif %} + {% if GROUP_RANK %} + {% if not RANK_IMG %} + {{ lang('GROUP_RANK') ~ lang('COLON') }} + {% endif %} + {{ GROUP_RANK }} + {% endif %} {% EVENT memberlist_body_group_rank_after %}

@@ -120,7 +125,13 @@ {memberrow.RANK_IMG}{memberrow.RANK_TITLE} {memberrow.USERNAME_FULL} ({L_INACTIVE})
{L_SELECT} ] {memberrow.POSTS}{memberrow.POSTS} -
{memberrow.custom_fields.PROFILE_FIELD_VALUE}
  + + {%- for field in memberrow.custom_fields -%} +
{% if field.S_PROFILE_CONTACT %}{% endif %}{{ field.PROFILE_FIELD_VALUE }}{% if field.S_PROFILE_CONTACT %}{% endif %}
+ {%- else -%} +   + {%- endfor -%} + {memberrow.JOINED} {memberrow.LAST_ACTIVE}  {% EVENT memberlist_body_memberrow_after %} diff --git a/styles/prosilver/template/memberlist_search.html b/styles/prosilver/template/memberlist_search.html index b1c7a81..34915eb 100644 --- a/styles/prosilver/template/memberlist_search.html +++ b/styles/prosilver/template/memberlist_search.html @@ -12,7 +12,7 @@
diff --git a/styles/prosilver/template/simple_footer.html b/styles/prosilver/template/simple_footer.html index 1ef44d1..fde162a 100644 --- a/styles/prosilver/template/simple_footer.html +++ b/styles/prosilver/template/simple_footer.html @@ -25,7 +25,7 @@ - + diff --git a/styles/prosilver/template/ucp_agreement.html b/styles/prosilver/template/ucp_agreement.html index ace6525..7959925 100644 --- a/styles/prosilver/template/ucp_agreement.html +++ b/styles/prosilver/template/ucp_agreement.html @@ -43,7 +43,8 @@
- {L_COPPA_NO}  {L_COPPA_YES} + +   @@ -62,8 +63,6 @@

{SITENAME} - {AGREEMENT_TITLE}

{AGREEMENT_TEXT}

-
-

{L_BACK}

diff --git a/styles/prosilver/template/ucp_attachments.html b/styles/prosilver/template/ucp_attachments.html index 696f621..cfdbf9c 100644 --- a/styles/prosilver/template/ucp_attachments.html +++ b/styles/prosilver/template/ucp_attachments.html @@ -44,7 +44,7 @@
{attachrow.DOWNLOAD_COUNT}
{attachrow.POST_TIME}
-
+
diff --git a/styles/prosilver/template/ucp_avatar_options_upload.html b/styles/prosilver/template/ucp_avatar_options_upload.html index 63a734e..666950e 100644 --- a/styles/prosilver/template/ucp_avatar_options_upload.html +++ b/styles/prosilver/template/ucp_avatar_options_upload.html @@ -1,6 +1,6 @@
-
+
diff --git a/styles/prosilver/template/ucp_groups_manage.html b/styles/prosilver/template/ucp_groups_manage.html index f2b4f00..adc8c61 100644 --- a/styles/prosilver/template/ucp_groups_manage.html +++ b/styles/prosilver/template/ucp_groups_manage.html @@ -58,7 +58,7 @@     [ {L_COLOUR_SWATCH} ] - +
diff --git a/styles/prosilver/template/ucp_pm_history.html b/styles/prosilver/template/ucp_pm_history.html index 6362a0b..b53eb0c 100644 --- a/styles/prosilver/template/ucp_pm_history.html +++ b/styles/prosilver/template/ucp_pm_history.html @@ -36,7 +36,7 @@

{history_row.MINI_POST} {L_SENT_AT}{L_COLON} {history_row.SENT_DATE}
- {L_MESSAGE_BY_AUTHOR} {history_row.MESSAGE_AUTHOR_FULL} + {L_MESSAGE_BY_AUTHOR} {history_row.MESSAGE_AUTHOR_FULL}

{history_row.MESSAGE}{L_MESSAGE_REMOVED_FROM_OUTBOX}
@@ -54,4 +54,3 @@ {L_BACK_TO_TOP}

- diff --git a/styles/prosilver/template/ucp_pm_viewmessage_print.html b/styles/prosilver/template/ucp_pm_viewmessage_print.html index 7a88492..41ff5b8 100644 --- a/styles/prosilver/template/ucp_pm_viewmessage_print.html +++ b/styles/prosilver/template/ucp_pm_viewmessage_print.html @@ -42,7 +42,14 @@ diff --git a/styles/prosilver/template/ucp_profile_profile_info.html b/styles/prosilver/template/ucp_profile_profile_info.html index 69eda8c..ac0cd15 100644 --- a/styles/prosilver/template/ucp_profile_profile_info.html +++ b/styles/prosilver/template/ucp_profile_profile_info.html @@ -13,7 +13,7 @@
-

{L_BIRTHDAY_EXPLAIN}
+

{L_BIRTHDAY_EXPLAIN}
diff --git a/styles/prosilver/template/ucp_register.html b/styles/prosilver/template/ucp_register.html index bf39990..f44382f 100644 --- a/styles/prosilver/template/ucp_register.html +++ b/styles/prosilver/template/ucp_register.html @@ -12,6 +12,17 @@ } +{% if PROVIDER_TEMPLATE_FILE %} +
+
+ +

{{ SITENAME }} - {{ lang('OAUTH_REGISTRATION') }}

+ + {% include PROVIDER_TEMPLATE_FILE %} +
+
+{% endif %} +
diff --git a/styles/prosilver/template/ucp_reset_password.html b/styles/prosilver/template/ucp_reset_password.html new file mode 100644 index 0000000..0a05f69 --- /dev/null +++ b/styles/prosilver/template/ucp_reset_password.html @@ -0,0 +1,49 @@ + + + + +
+
+ +
+

{{ lang('RESET_PASSWORD') }}

+ +
+ {% if S_IS_PASSWORD_RESET %} + {% if PASSWORD_RESET_ERRORS %}

{{ PASSWORD_RESET_ERRORS | join('
') }}

{% endif %} +
+
+
+
+
+
+
+
+ {% else %} + {% if USERNAME_REQUIRED %} +

{{ lang('EMAIL_NOT_UNIQUE') }}

+ {% endif %} +
+

{{ lang('EMAIL_REMIND') }}
+
+
+ {% if USERNAME_REQUIRED %} +
+
+
+
+ {% endif %} + {% endif %} +
+
 
+
{{ S_HIDDEN_FIELDS }} 
+
+ {{ S_FORM_TOKEN }} +
+
+ +
+
+ + + diff --git a/styles/prosilver/template/viewforum_body.html b/styles/prosilver/template/viewforum_body.html index d7099f3..40beb78 100644 --- a/styles/prosilver/template/viewforum_body.html +++ b/styles/prosilver/template/viewforum_body.html @@ -157,7 +157,7 @@
  • - style="background-image: url({T_ICONS_PATH}{topicrow.TOPIC_ICON_IMG}); background-repeat: no-repeat;" title="{topicrow.TOPIC_FOLDER_IMG_ALT}"> + style="background-image: url('{T_ICONS_PATH}{topicrow.TOPIC_ICON_IMG}'); background-repeat: no-repeat;" title="{topicrow.TOPIC_FOLDER_IMG_ALT}">
    @@ -187,7 +187,7 @@ @@ -198,7 +198,9 @@
    - {L_POST_BY_AUTHOR} {topicrow.TOPIC_AUTHOR_FULL} » {topicrow.FIRST_POST_TIME} + {% EVENT topiclist_row_topic_by_author_before %} + {L_POST_BY_AUTHOR} {topicrow.TOPIC_AUTHOR_FULL} » + {% EVENT topiclist_row_topic_by_author_after %} » {L_IN} {topicrow.FORUM_NAME}
    @@ -230,7 +232,7 @@ {VIEW_LATEST_POST} -
    {topicrow.LAST_POST_TIME} +
  • diff --git a/styles/prosilver/template/viewtopic_body.html b/styles/prosilver/template/viewtopic_body.html index 8d7e26f..6af33f2 100644 --- a/styles/prosilver/template/viewtopic_body.html +++ b/styles/prosilver/template/viewtopic_body.html @@ -224,7 +224,7 @@
    style="display: none;"> -

    class="first">{postrow.POST_ICON_IMG_ALT} {postrow.POST_SUBJECT}

    +

    class="first">{postrow.POST_ICON_IMG_ALT} {postrow.POST_SUBJECT}

    @@ -289,11 +289,12 @@ {postrow.MINI_POST} - {L_POST_BY_AUTHOR} {postrow.POST_AUTHOR_FULL} » {postrow.POST_DATE} + {L_POST_BY_AUTHOR} {postrow.POST_AUTHOR_FULL} »

    +

    @@ -304,6 +305,12 @@ {S_FORM_TOKEN}

    + +

    + + {L_POST_UNAPPROVED_EXPLAIN} +

    +

    diff --git a/styles/prosilver/template/viewtopic_print.html b/styles/prosilver/template/viewtopic_print.html index b504949..658062f 100644 --- a/styles/prosilver/template/viewtopic_print.html +++ b/styles/prosilver/template/viewtopic_print.html @@ -38,7 +38,14 @@

    diff --git a/styles/prosilver/theme/colours.css b/styles/prosilver/theme/colours.css index ffaa710..04a8958 100644 --- a/styles/prosilver/theme/colours.css +++ b/styles/prosilver/theme/colours.css @@ -149,7 +149,7 @@ table.zebra-list tr:nth-child(even) td, ul.zebra-list li:nth-child(even) { } .site_logo { - background-image: url("./images/site_logo.gif"); + background-image: url("./images/site_logo.svg"); } /* Horizontal lists @@ -672,6 +672,11 @@ Colours and backgrounds for buttons.css box-shadow: 0 0 10px #0075B0; } +.search-results li:hover, +.search-results li.active { + background-color: #CFE1F6; +} + /* Icon images ---------------------------------------- */ diff --git a/styles/prosilver/theme/common.css b/styles/prosilver/theme/common.css index a0dc5e0..eb04c66 100644 --- a/styles/prosilver/theme/common.css +++ b/styles/prosilver/theme/common.css @@ -176,6 +176,7 @@ a:hover { text-decoration: underline; } } .site_logo { + background-repeat: no-repeat; display: inline-block; width: 149px; height: 52px; diff --git a/styles/prosilver/theme/forms.css b/styles/prosilver/theme/forms.css index 5646a7d..99c898f 100644 --- a/styles/prosilver/theme/forms.css +++ b/styles/prosilver/theme/forms.css @@ -355,7 +355,7 @@ input.button3 { font-variant: small-caps; } -input[type="button"], input[type="submit"], input[type="reset"], input[type="checkbox"], input[type="radio"] { +input[type="button"], input[type="submit"], input[type="reset"], input[type="checkbox"], input[type="radio"], .search-results li { cursor: pointer; } diff --git a/styles/prosilver/theme/icons.css b/styles/prosilver/theme/icons.css index 6643f12..3ac5984 100644 --- a/styles/prosilver/theme/icons.css +++ b/styles/prosilver/theme/icons.css @@ -5,7 +5,7 @@ /* Global module setup --------------------------------*/ -/* Renamed version of .fa class for agnostic useage of icon fonts. +/* Renamed version of .fa class for agnostic usage of icon fonts. * Just change the name of the font after the 14/1 to the name of * the font you wish to use. */ diff --git a/styles/prosilver/theme/images/site_logo.svg b/styles/prosilver/theme/images/site_logo.svg new file mode 100644 index 0000000..4ce8903 --- /dev/null +++ b/styles/prosilver/theme/images/site_logo.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/styles/prosilver/theme/plupload.css b/styles/prosilver/theme/plupload.css index f466803..b1f3ae2 100644 --- a/styles/prosilver/theme/plupload.css +++ b/styles/prosilver/theme/plupload.css @@ -3,6 +3,10 @@ margin-bottom: 1em; } +.attach-row-tpl { + display: none; +} + .file-list td { vertical-align: middle; } diff --git a/styles/prosilver/theme/print.css b/styles/prosilver/theme/print.css index 9445279..ee916dc 100644 --- a/styles/prosilver/theme/print.css +++ b/styles/prosilver/theme/print.css @@ -90,7 +90,7 @@ hr { font-size: 75%; } -/* Dont want to print url for names or titles in content area */ +/* Don't want to print url for names or titles in content area */ .postbody .author a:link, .postbody .author a:visited, html>body .postbody .author a:link:after, html>body .postbody .author a:visited:after, diff --git a/styles/prosilver/theme/stylesheet.css b/styles/prosilver/theme/stylesheet.css new file mode 100644 index 0000000..c402d56 --- /dev/null +++ b/styles/prosilver/theme/stylesheet.css @@ -0,0 +1,21 @@ +/* phpBB3 Style Sheet + -------------------------------------------------------------- + Style name: prosilver (the default phpBB 3.3.x style) + Based on style: + Original author: Tom Beddard ( http://www.subblue.com/ ) + Modified by: phpBB Limited ( https://www.phpbb.com/ ) + -------------------------------------------------------------- +*/ + +@import url("normalize.css?v=3.3"); +@import url("base.css?v=3.3"); +@import url("utilities.css?v=3.3"); +@import url("common.css?v=3.3"); +@import url("links.css?v=3.3"); +@import url("content.css?v=3.3"); +@import url("buttons.css?v=3.3"); +@import url("cp.css?v=3.3"); +@import url("forms.css?v=3.3"); +@import url("icons.css?v=3.3"); +@import url("colours.css?v=3.3"); +@import url("responsive.css?v=3.3"); diff --git a/ucp.php b/ucp.php index 96a3efe..0992e3e 100644 --- a/ucp.php +++ b/ucp.php @@ -63,8 +63,10 @@ switch ($mode) break; case 'sendpassword': - $module->load('ucp', 'remind'); - $module->display($user->lang['UCP_REMIND']); + /** @var \phpbb\controller\helper $controller_helper */ + $controller_helper = $phpbb_container->get('controller.helper'); + + redirect($controller_helper->route('phpbb_ucp_forgot_password_controller')); break; case 'register': @@ -393,6 +395,11 @@ if (!$config['allow_topic_notify'] && !$config['allow_forum_notify']) $vars = array('module', 'id', 'mode'); extract($phpbb_dispatcher->trigger_event('core.ucp_display_module_before', compact($vars))); +$template->assign_block_vars('navlinks', array( + 'BREADCRUMB_NAME' => $user->lang('UCP'), + 'U_BREADCRUMB' => append_sid("{$phpbb_root_path}ucp.$phpEx"), +)); + // Select the active module $module->set_active($id, $mode); diff --git a/viewforum.php b/viewforum.php index 5525a0d..eb6b37a 100644 --- a/viewforum.php +++ b/viewforum.php @@ -198,9 +198,6 @@ if (!($forum_data['forum_type'] == FORUM_POST || (($forum_data['forum_flags'] & // We also make this circumstance available to the template in case we want to display a notice. ;) if (!$auth->acl_gets('f_read', 'f_list_topics', $forum_id)) { - // Add form token for login box - add_form_key('login', '_LOGIN'); - $template->assign_vars(array( 'S_NO_READ_ACCESS' => true, )); @@ -225,7 +222,7 @@ if ($mark_read == 'topics') $data = array( 'NO_UNREAD_POSTS' => $user->lang['NO_UNREAD_POSTS'], 'UNREAD_POSTS' => $user->lang['UNREAD_POSTS'], - 'U_MARK_TOPICS' => ($user->data['is_registered'] || $config['load_anon_lastread']) ? append_sid("{$phpbb_root_path}viewforum.$phpEx", 'hash=' . generate_link_hash('global') . "&f=$forum_id&mark=topics&mark_time=" . time()) : '', + 'U_MARK_TOPICS' => ($user->data['is_registered'] || $config['load_anon_lastread']) ? append_sid("{$phpbb_root_path}viewforum.$phpEx", 'hash=' . generate_link_hash('global') . "&f=$forum_id&mark=topics&mark_time=" . time(), false) : '', 'MESSAGE_TITLE' => $user->lang['INFORMATION'], 'MESSAGE_TEXT' => $user->lang['TOPICS_MARKED'] ); @@ -902,6 +899,11 @@ if (count($topic_list)) // Replies $replies = $phpbb_content_visibility->get_count('topic_posts', $row, $topic_forum_id) - 1; + // Correction for case of unapproved topic visible to poster + if ($replies < 0) + { + $replies = 0; + } if ($row['topic_status'] == ITEM_MOVED) { @@ -936,9 +938,12 @@ if (count($topic_list)) 'TOPIC_AUTHOR_COLOUR' => get_username_string('colour', $row['topic_poster'], $row['topic_first_poster_name'], $row['topic_first_poster_colour']), 'TOPIC_AUTHOR_FULL' => get_username_string('full', $row['topic_poster'], $row['topic_first_poster_name'], $row['topic_first_poster_colour']), 'FIRST_POST_TIME' => $user->format_date($row['topic_time']), + 'FIRST_POST_TIME_RFC3339' => gmdate(DATE_RFC3339, $row['topic_time']), 'LAST_POST_SUBJECT' => censor_text($row['topic_last_post_subject']), 'LAST_POST_TIME' => $user->format_date($row['topic_last_post_time']), + 'LAST_POST_TIME_RFC3339' => gmdate(DATE_RFC3339, $row['topic_last_post_time']), 'LAST_VIEW_TIME' => $user->format_date($row['topic_last_view_time']), + 'LAST_VIEW_TIME_RFC3339' => gmdate(DATE_RFC3339, $row['topic_last_view_time']), 'LAST_POST_AUTHOR' => get_username_string('username', $row['topic_last_poster_id'], $row['topic_last_poster_name'], $row['topic_last_poster_colour']), 'LAST_POST_AUTHOR_COLOUR' => get_username_string('colour', $row['topic_last_poster_id'], $row['topic_last_poster_name'], $row['topic_last_poster_colour']), 'LAST_POST_AUTHOR_FULL' => get_username_string('full', $row['topic_last_poster_id'], $row['topic_last_poster_name'], $row['topic_last_poster_colour']), diff --git a/viewonline.php b/viewonline.php index d5ddb0b..1b28750 100644 --- a/viewonline.php +++ b/viewonline.php @@ -487,6 +487,11 @@ $start = $pagination->validate_start($start, $config['topics_per_page'], $counte $base_url = append_sid("{$phpbb_root_path}viewonline.$phpEx", "sg=$show_guests&sk=$sort_key&sd=$sort_dir"); $pagination->generate_template_pagination($base_url, 'pagination', 'start', $counter, $config['topics_per_page'], $start); +$template->assign_block_vars('navlinks', array( + 'BREADCRUMB_NAME' => $user->lang('WHO_IS_ONLINE'), + 'U_BREADCRUMB' => append_sid("{$phpbb_root_path}viewonline.$phpEx"), +)); + // Send data to template $template->assign_vars(array( 'TOTAL_REGISTERED_USERS_ONLINE' => $user->lang('REG_USERS_ONLINE', (int) $logged_visible_online, $user->lang('HIDDEN_USERS_ONLINE', (int) $logged_hidden_online)), diff --git a/viewtopic.php b/viewtopic.php index eb2d52c..df241a5 100644 --- a/viewtopic.php +++ b/viewtopic.php @@ -453,6 +453,38 @@ $join_user_sql = array('a' => true, 't' => false, 's' => false); $s_limit_days = $s_sort_key = $s_sort_dir = $u_sort_param = ''; +/** +* Event to add new sorting options +* +* @event core.viewtopic_gen_sort_selects_before +* @var array limit_days Limit results by time +* @var array sort_by_text Language strings for sorting options +* @var array sort_by_sql SQL conditions for sorting options +* @var array join_user_sql SQL joins required for sorting options +* @var int sort_days User selected sort days +* @var string sort_key User selected sort key +* @var string sort_dir User selected sort direction +* @var string s_limit_days Initial value of limit days selectbox +* @var string s_sort_key Initial value of sort key selectbox +* @var string s_sort_dir Initial value of sort direction selectbox +* @var string u_sort_param Initial value of sorting form action +* @since 3.2.8-RC1 +*/ +$vars = array( + 'limit_days', + 'sort_by_text', + 'sort_by_sql', + 'join_user_sql', + 'sort_days', + 'sort_key', + 'sort_dir', + 's_limit_days', + 's_sort_key', + 's_sort_dir', + 'u_sort_param', +); +extract($phpbb_dispatcher->trigger_event('core.viewtopic_gen_sort_selects_before', compact($vars))); + gen_sort_selects($limit_days, $sort_by_text, $sort_days, $sort_key, $sort_dir, $s_limit_days, $s_sort_key, $s_sort_dir, $u_sort_param, $default_sort_days, $default_sort_key, $default_sort_dir); // Obtain correct post count and ordering SQL if user has @@ -2012,6 +2044,7 @@ for ($i = 0, $end = count($post_list); $i < $end; ++$i) 'CONTACT_USER' => $user_cache[$poster_id]['contact_user'], 'POST_DATE' => $user->format_date($row['post_time'], false, ($view == 'print') ? true : false), + 'POST_DATE_RFC3339' => gmdate(DATE_RFC3339, $row['post_time']), 'POST_SUBJECT' => $row['post_subject'], 'MESSAGE' => $message, 'SIGNATURE' => ($row['enable_sig']) ? $user_cache[$poster_id]['sig'] : '', @@ -2059,6 +2092,7 @@ for ($i = 0, $end = count($post_list); $i < $end; ++$i) 'S_HAS_ATTACHMENTS' => (!empty($attachments[$row['post_id']])) ? true : false, 'S_MULTIPLE_ATTACHMENTS' => !empty($attachments[$row['post_id']]) && count($attachments[$row['post_id']]) > 1, 'S_POST_UNAPPROVED' => ($row['post_visibility'] == ITEM_UNAPPROVED || $row['post_visibility'] == ITEM_REAPPROVE) ? true : false, + 'S_CAN_APPROVE' => $auth->acl_get('m_approve', $forum_id), 'S_POST_DELETED' => ($row['post_visibility'] == ITEM_DELETED) ? true : false, 'L_POST_DELETED_MESSAGE' => $l_deleted_message, 'S_POST_REPORTED' => ($row['post_reported'] && $auth->acl_get('m_report', $forum_id)) ? true : false, @@ -2327,12 +2361,25 @@ if ($s_can_vote || $s_quick_reply) ($s_notify) ? $qr_hidden_fields['notify'] = 1 : true; ($topic_data['topic_status'] == ITEM_LOCKED) ? $qr_hidden_fields['lock_topic'] = 1 : true; - $template->assign_vars(array( + $tpl_ary = [ 'S_QUICK_REPLY' => true, 'U_QR_ACTION' => append_sid("{$phpbb_root_path}posting.$phpEx", "mode=reply&f=$forum_id&t=$topic_id"), 'QR_HIDDEN_FIELDS' => build_hidden_fields($qr_hidden_fields), 'SUBJECT' => 'Re: ' . censor_text($topic_data['topic_title']), - )); + ]; + + /** + * Event after the quick-reply has been setup + * + * @event core.viewtopic_modify_quick_reply_template_vars + * @var array tpl_ary Array with template data + * @var array topic_data Array with topic data + * @since 3.2.9-RC1 + */ + $vars = ['tpl_ary', 'topic_data']; + extract($phpbb_dispatcher->trigger_event('core.viewtopic_modify_quick_reply_template_vars', compact($vars))); + + $template->assign_vars($tpl_ary); } } // now I have the urge to wash my hands :(