From eef332eea5d299784dc31891e84c11017548681d Mon Sep 17 00:00:00 2001 From: Ludovic Arnaud Date: Sun, 15 Sep 2002 17:21:08 +0000 Subject: Cleanups git-svn-id: file:///svn/phpbb/trunk@2889 89ea8834-ac86-4346-8a33-228a782c2dd0 --- phpBB/admin/admin_forums.php | 89 ++++++-------------------------------------- 1 file changed, 11 insertions(+), 78 deletions(-) (limited to 'phpBB/admin/admin_forums.php') diff --git a/phpBB/admin/admin_forums.php b/phpBB/admin/admin_forums.php index 19b9b6fc00..2336bec824 100644 --- a/phpBB/admin/admin_forums.php +++ b/phpBB/admin/admin_forums.php @@ -40,28 +40,6 @@ require($phpbb_root_path . 'extension.inc'); require('pagestart.' . $phpEx); include($phpbb_root_path . 'includes/functions_admin.'.$phpEx); -// -// Additional lang strings and constants -// -$lang['Category_name'] = 'Category name'; -$lang['Type'] = 'Type'; - -$lang['Parent'] = 'Parent'; -$lang['Locked'] = 'Locked'; -$lang['Unlocked'] = 'Unlocked'; - -$lang['General_settings'] = 'General settings'; -$lang['Forum_settings'] = 'Forum settings'; -$lang['Disable_post_count'] = 'Disable post count'; - -$lang['Default_style'] = 'Default style'; - -$lang['Move_posts'] = 'Move posts to'; -$lang['Delete_subforums'] = 'Delete subforums and associated posts'; -$lang['Move_subforums'] = 'Move subforums to'; - -define('ITEM_CATEGORY', 3); - // // Do we have forum admin permissions? // @@ -307,10 +285,7 @@ switch ($mode) $parents_list = make_forums_list('all', $parent_id, $subforums_id); - // - // TODO: Make 'Edit_forum' and 'Edit_Category' use the same case - // - $l_title = ($forum_status != ITEM_CATEGORY) ? $lang['Edit_forum'] : $lang['Edit_Category']; + $l_title = ($forum_status != ITEM_CATEGORY) ? $lang['Edit_forum'] : $lang['Edit_category']; $newmode = 'modify'; $buttonvalue = $lang['Update']; $prune_enabled = ($prune_enable) ? 'checked="checked" ' : ''; @@ -382,7 +357,7 @@ switch ($mode) { ?> - + />   /> - - Change this forum into a category and
+ +
     
-      Move all posts to +       - + - + Forum Index'; - $sql = 'SELECT f2.forum_id, f2.forum_name - FROM ' . FORUMS_TABLE . ' f1 - LEFT JOIN ' . FORUMS_TABLE . " f2 ON f1.left_id BETWEEN f2.left_id AND f2.right_id - WHERE f1.forum_id = $parent_id - ORDER BY f2.left_id"; - - $result = $db->sql_query($sql); - while ($row = $db->sql_fetchrow($result)) + $forums_nav = get_forum_branch($parent_id, 'parents', 'descending'); + foreach ($forums_nav as $row) { if ($row['forum_id'] == $parent_id) { @@ -654,7 +623,7 @@ while ($row = $db->sql_fetchrow($result)) } ?> - + >
@@ -666,7 +635,7 @@ while ($row = $db->sql_fetchrow($result)) } ?> - + sql_query($sql); - while ($row = $db->sql_fetchrow($result)) - { - if (!$include_forum && $row['forum_id'] == $forum_id) - { - continue; - } - $rows[] = $row; - } - return $rows; -} - function get_forum_info($forum_id) { global $db; -- cgit v1.2.1