diff options
| author | Drae <paul@starstreak.net> | 2012-07-05 18:56:14 +0100 |
|---|---|---|
| committer | Drae <paul@starstreak.net> | 2012-07-18 14:31:21 +0100 |
| commit | dc71c0629e60acccd39b59538f2e7f5b09b32509 (patch) | |
| tree | b87e23a0e29124f25abecb06e2b1252e1d3655c3 /phpBB/includes/mcp/mcp_topic.php | |
| parent | 922147f05a75d5a0e00b34f0102bc014583df984 (diff) | |
| download | forums-dc71c0629e60acccd39b59538f2e7f5b09b32509.tar forums-dc71c0629e60acccd39b59538f2e7f5b09b32509.tar.gz forums-dc71c0629e60acccd39b59538f2e7f5b09b32509.tar.bz2 forums-dc71c0629e60acccd39b59538f2e7f5b09b32509.tar.xz forums-dc71c0629e60acccd39b59538f2e7f5b09b32509.zip | |
[feature/pagination-as-list] Various fixes and improvements
Extracted common template code for prosilver as per subsilver2.
Various other fixups and oversight corrections, changed name
of the "new" template function and re-introduced existing
version. Altered on_page to compensate for removal of some
templating vars from pagination routine.
PHPBB3-10968
Diffstat (limited to 'phpBB/includes/mcp/mcp_topic.php')
| -rw-r--r-- | phpBB/includes/mcp/mcp_topic.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/phpBB/includes/mcp/mcp_topic.php b/phpBB/includes/mcp/mcp_topic.php index c2f44bd360..e4f796f781 100644 --- a/phpBB/includes/mcp/mcp_topic.php +++ b/phpBB/includes/mcp/mcp_topic.php @@ -306,9 +306,10 @@ function mcp_topic_view($id, $mode, $action) 'post_ids' => $post_id_list, )); + $base_url = append_sid("{$phpbb_root_path}mcp.$phpEx", "i=$id&t={$topic_info['topic_id']}&mode=$mode&action=$action&to_topic_id=$to_topic_id&posts_per_page=$posts_per_page&st=$sort_days&sk=$sort_key&sd=$sort_dir"); if ($posts_per_page) { - generate_pagination(append_sid("{$phpbb_root_path}mcp.$phpEx", "i=$id&t={$topic_info['topic_id']}&mode=$mode&action=$action&to_topic_id=$to_topic_id&posts_per_page=$posts_per_page&st=$sort_days&sk=$sort_key&sd=$sort_dir"), $total, $posts_per_page, $start); + generate_template_pagination($base_url, 'pagination', $total, $posts_per_page, $start); } $template->assign_vars(array( @@ -349,7 +350,7 @@ function mcp_topic_view($id, $mode, $action) 'RETURN_TOPIC' => sprintf($user->lang['RETURN_TOPIC'], '<a href="' . append_sid("{$phpbb_root_path}viewtopic.$phpEx", "f={$topic_info['forum_id']}&t={$topic_info['topic_id']}&start=$start") . '">', '</a>'), 'RETURN_FORUM' => sprintf($user->lang['RETURN_FORUM'], '<a href="' . append_sid("{$phpbb_root_path}viewforum.$phpEx", "f={$topic_info['forum_id']}&start=$start") . '">', '</a>'), - 'PAGE_NUMBER' => on_page($total, $posts_per_page, $start), + 'PAGE_NUMBER' => on_page($base_url, $total, $posts_per_page, $start), 'TOTAL_POSTS' => $user->lang('VIEW_TOPIC_POSTS', (int) $total), )); } |
