diff options
author | Joas Schilling <nickvergessen@gmx.de> | 2014-11-21 20:05:19 +0100 |
---|---|---|
committer | Joas Schilling <nickvergessen@gmx.de> | 2014-11-21 20:05:19 +0100 |
commit | bc52a84998c5562f73ab5c84f82971dcc5ba3c65 (patch) | |
tree | 8e5309bfcca1ebbbd4cd7a72b51605d1b5bcda97 | |
parent | d6e8cce44b63efe69fa698708fbd3d169ca5ed71 (diff) | |
parent | b648d3eb4c00aca936274978a427473aaa98138f (diff) | |
download | forums-bc52a84998c5562f73ab5c84f82971dcc5ba3c65.tar forums-bc52a84998c5562f73ab5c84f82971dcc5ba3c65.tar.gz forums-bc52a84998c5562f73ab5c84f82971dcc5ba3c65.tar.bz2 forums-bc52a84998c5562f73ab5c84f82971dcc5ba3c65.tar.xz forums-bc52a84998c5562f73ab5c84f82971dcc5ba3c65.zip |
Merge pull request #3131 from omniError/ticket/13328
[ticket/13328] add core.mcp_view_forum_modify_sql
-rw-r--r-- | phpBB/includes/mcp/mcp_forum.php | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/phpBB/includes/mcp/mcp_forum.php b/phpBB/includes/mcp/mcp_forum.php index 0c6acaa908..c18ca1aa1d 100644 --- a/phpBB/includes/mcp/mcp_forum.php +++ b/phpBB/includes/mcp/mcp_forum.php @@ -165,6 +165,22 @@ function mcp_forum_view($id, $mode, $action, $forum_info) AND ' . $phpbb_content_visibility->get_visibility_sql('topic', $forum_id, 't.') . " $limit_time_sql ORDER BY t.topic_type DESC, $sort_order_sql"; + + /** + * Modify SQL query before MCP forum view topic list is queried + * + * @event core.mcp_view_forum_modify_sql + * @var string sql SQL query for forum view topic list + * @var int forum_id ID of the forum + * @var string limit_time_sql SQL query part for limit time + * @var string sort_order_sql SQL query part for sort order + * @var int topics_per_page Number of topics per page + * @var int start Start value + * @since 3.1.2-RC1 + */ + $vars = array('sql', 'forum_id', 'limit_time_sql', 'sort_order_sql', 'topics_per_page', 'start'); + extract($phpbb_dispatcher->trigger_event('core.mcp_view_forum_modify_sql', compact($vars))); + $result = $db->sql_query_limit($sql, $topics_per_page, $start); $topic_list = $topic_tracking_info = array(); |