aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/functions_content.php
diff options
context:
space:
mode:
authorMarc Alexander <admin@m-a-styles.de>2016-02-26 23:11:16 +0100
committerMarc Alexander <admin@m-a-styles.de>2016-02-26 23:11:16 +0100
commit30db51a86e009f50920f8c0c6c05da26e2b10a56 (patch)
tree4face069b5618a66b3a13d5b714d7266fe3fb783 /phpBB/includes/functions_content.php
parent49d42e288120d1bbce3a592fb659ddb69e65eed4 (diff)
parentec70ec96e725696b2efc922ad60e802e58e97c82 (diff)
downloadforums-30db51a86e009f50920f8c0c6c05da26e2b10a56.tar
forums-30db51a86e009f50920f8c0c6c05da26e2b10a56.tar.gz
forums-30db51a86e009f50920f8c0c6c05da26e2b10a56.tar.bz2
forums-30db51a86e009f50920f8c0c6c05da26e2b10a56.tar.xz
forums-30db51a86e009f50920f8c0c6c05da26e2b10a56.zip
Merge branch '3.1.x' into 3.2.x
Diffstat (limited to 'phpBB/includes/functions_content.php')
-rw-r--r--phpBB/includes/functions_content.php38
1 files changed, 37 insertions, 1 deletions
diff --git a/phpBB/includes/functions_content.php b/phpBB/includes/functions_content.php
index df25451266..dda752c6ca 100644
--- a/phpBB/includes/functions_content.php
+++ b/phpBB/includes/functions_content.php
@@ -47,7 +47,7 @@ if (!defined('IN_PHPBB'))
*/
function 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, $def_st = false, $def_sk = false, $def_sd = false)
{
- global $user;
+ global $user, $phpbb_dispatcher;
$sort_dir_text = array('a' => $user->lang['ASCENDING'], 'd' => $user->lang['DESCENDING']);
@@ -106,6 +106,42 @@ function gen_sort_selects(&$limit_days, &$sort_by_text, &$sort_days, &$sort_key,
$u_sort_param .= ($selected !== $sort_ary['default']) ? ((strlen($u_sort_param)) ? '&amp;' : '') . "{$name}={$selected}" : '';
}
+ /**
+ * Run code before generated sort selects are returned
+ *
+ * @event core.gen_sort_selects_after
+ * @var int limit_days Days limit
+ * @var array sort_by_text Sort by text options
+ * @var int sort_days Sort by days flag
+ * @var string sort_key Sort key
+ * @var string sort_dir Sort dir
+ * @var string s_limit_days String of days limit
+ * @var string s_sort_key String of sort key
+ * @var string s_sort_dir String of sort dir
+ * @var string u_sort_param Sort URL params
+ * @var bool def_st Default sort days
+ * @var bool def_sk Default sort key
+ * @var bool def_sd Default sort dir
+ * @var array sorts Sorts
+ * @since 3.1.9-RC1
+ */
+ $vars = array(
+ 'limit_days',
+ 'sort_by_text',
+ 'sort_days',
+ 'sort_key',
+ 'sort_dir',
+ 's_limit_days',
+ 's_sort_key',
+ 's_sort_dir',
+ 'u_sort_param',
+ 'def_st',
+ 'def_sk',
+ 'def_sd',
+ 'sorts',
+ );
+ extract($phpbb_dispatcher->trigger_event('core.gen_sort_selects_after', compact($vars)));
+
return;
}