diff options
| author | Paul S. Owen <psotfx@users.sourceforge.net> | 2001-07-14 21:06:32 +0000 |
|---|---|---|
| committer | Paul S. Owen <psotfx@users.sourceforge.net> | 2001-07-14 21:06:32 +0000 |
| commit | cd35db637b2732c777089617199e3d1040941002 (patch) | |
| tree | ee7f4ff9be90fb84f94fdcd6c31e62c949022739 /phpBB/viewforum.php | |
| parent | bc5165cd5e35b44ad72cabed062e9ac9ab00f29b (diff) | |
| download | forums-cd35db637b2732c777089617199e3d1040941002.tar forums-cd35db637b2732c777089617199e3d1040941002.tar.gz forums-cd35db637b2732c777089617199e3d1040941002.tar.bz2 forums-cd35db637b2732c777089617199e3d1040941002.tar.xz forums-cd35db637b2732c777089617199e3d1040941002.zip | |
I was fed up with no posts meaning you cannot post
git-svn-id: file:///svn/phpbb/trunk@666 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/viewforum.php')
| -rw-r--r-- | phpBB/viewforum.php | 62 |
1 files changed, 32 insertions, 30 deletions
diff --git a/phpBB/viewforum.php b/phpBB/viewforum.php index e6cc2d07e7..75c81b641f 100644 --- a/phpBB/viewforum.php +++ b/phpBB/viewforum.php @@ -234,6 +234,20 @@ $template->assign_vars(array( ); // +// User authorisation levels output +// +$s_auth_can = $lang['You'] . " " . ( ($is_auth['auth_read']) ? $lang['can'] : $lang['cannot'] ) . " " . $lang['read_posts'] . "<br />"; +$s_auth_can .= $lang['You'] . " " . ( ($is_auth['auth_post']) ? $lang['can'] : $lang['cannot'] ) . " " . $lang['post_topics'] . "<br />"; +$s_auth_can .= $lang['You'] . " " . ( ($is_auth['auth_reply']) ? $lang['can'] : $lang['cannot'] ) . " " . $lang['reply_posts'] . "<br />"; +$s_auth_can .= $lang['You'] . " " . ( ($is_auth['auth_edit']) ? $lang['can'] : $lang['cannot'] ) . " " . $lang['edit_posts'] . "<br />"; +$s_auth_can .= $lang['You'] . " " . ( ($is_auth['auth_delete']) ? $lang['can'] : $lang['cannot'] ) . " " . $lang['delete_posts'] . "<br />"; + +if($is_auth['auth_mod'] || $userdata['user_level'] == ADMIN) +{ + $s_auth_can .= $lang['You'] . " " . $lang['can'] . " <a href=\"" . append_sid("modcp.$phpEx?" . POST_FORUM_URL . "=$forum_id") . "\">" . $lang['moderate_forum'] . "</a><br />"; +} + +// // Dump out the page header and load viewforum template // include($phpbb_root_path . 'includes/page_header.'.$phpEx); @@ -255,7 +269,9 @@ $template->assign_vars(array( "FORUM_NAME" => $forum_name, "MODERATORS" => $forum_moderators, - "IMG_POST" => $images['topic_new']) + "IMG_POST" => $images['topic_new'], + + "S_AUTH_LIST" => $s_auth_can) ); // // End header @@ -377,54 +393,40 @@ if($total_topics) ); } - // - // User authorisation levels output - // - $s_auth_can = $lang['You'] . " " . ( ($is_auth['auth_read']) ? $lang['can'] : $lang['cannot'] ) . " " . $lang['read_posts'] . "<br />"; - $s_auth_can .= $lang['You'] . " " . ( ($is_auth['auth_post']) ? $lang['can'] : $lang['cannot'] ) . " " . $lang['post_topics'] . "<br />"; - $s_auth_can .= $lang['You'] . " " . ( ($is_auth['auth_reply']) ? $lang['can'] : $lang['cannot'] ) . " " . $lang['reply_posts'] . "<br />"; - $s_auth_can .= $lang['You'] . " " . ( ($is_auth['auth_edit']) ? $lang['can'] : $lang['cannot'] ) . " " . $lang['edit_posts'] . "<br />"; - $s_auth_can .= $lang['You'] . " " . ( ($is_auth['auth_delete']) ? $lang['can'] : $lang['cannot'] ) . " " . $lang['delete_posts'] . "<br />"; - - if($is_auth['auth_mod'] || $userdata['user_level'] == ADMIN) - { - $s_auth_can .= $lang['You'] . " " . $lang['can'] . " <a href=\"" . append_sid("modcp.$phpEx?" . POST_FORUM_URL . "=$forum_id") . "\">" . $lang['moderate_forum'] . "</a><br />"; - } - $template->assign_vars(array( "PAGINATION" => generate_pagination("viewforum.$phpEx?" . POST_FORUM_URL . "=$forum_id&postdays=$post_days", $topics_count, $board_config['topics_per_page'], $start), "ON_PAGE" => ( floor( $start / $board_config['topics_per_page'] ) + 1 ), "TOTAL_PAGES" => ceil( $topics_count / $board_config['topics_per_page'] ), - "S_AUTH_LIST" => $s_auth_can, - "S_NO_TOPICS" => FALSE, - "L_OF" => $lang['of'], "L_PAGE" => $lang['Page'], - "L_GOTO_PAGE" => $lang['Goto_page']) + "L_GOTO_PAGE" => $lang['Goto_page'], + + "S_NO_TOPICS" => FALSE) ); - $template->pparse("body"); } else { -/* + // + // No topics + // $template->assign_vars(array( "L_NO_TOPICS" => $lang['No_topics_post_one'], - "S_AUTH_LIST" => $s_auth_can, "S_NO_TOPICS" => TRUE) ); - - $template->pparse("body"); -*/ - // - // This will be present in the templates at some future point when if...else - // constructs are available - // - message_die(GENERAL_MESSAGE, $lang['No_topics_post_one']); + } +// +// Parse the page and print +// +$template->pparse("body"); + +// +// Page footer +// include($phpbb_root_path . 'includes/page_tail.'.$phpEx); ?>
\ No newline at end of file |
