diff options
author | Paul S. Owen <psotfx@users.sourceforge.net> | 2001-08-26 14:35:39 +0000 |
---|---|---|
committer | Paul S. Owen <psotfx@users.sourceforge.net> | 2001-08-26 14:35:39 +0000 |
commit | e1fde13648731675037664d51f50e881f6844b38 (patch) | |
tree | 22a628447ed55ca43d9ee6c079b443d1d732a8e8 | |
parent | 56a52d5c47f8f3254468404e680cd5bb4bf5347e (diff) | |
download | forums-e1fde13648731675037664d51f50e881f6844b38.tar forums-e1fde13648731675037664d51f50e881f6844b38.tar.gz forums-e1fde13648731675037664d51f50e881f6844b38.tar.bz2 forums-e1fde13648731675037664d51f50e881f6844b38.tar.xz forums-e1fde13648731675037664d51f50e881f6844b38.zip |
Modified header comments
git-svn-id: file:///svn/phpbb/trunk@935 89ea8834-ac86-4346-8a33-228a782c2dd0
-rw-r--r-- | phpBB/admin/admin_board.php | 15 | ||||
-rw-r--r-- | phpBB/admin/admin_db_utilities.php | 11 | ||||
-rw-r--r-- | phpBB/admin/admin_forum_prune.php | 12 | ||||
-rw-r--r-- | phpBB/admin/admin_forumauth.php | 13 | ||||
-rw-r--r-- | phpBB/admin/admin_forums.php | 286 | ||||
-rw-r--r-- | phpBB/admin/admin_groupauth.php | 15 | ||||
-rw-r--r-- | phpBB/admin/admin_groups.php | 14 | ||||
-rw-r--r-- | phpBB/admin/admin_smilies.php | 11 | ||||
-rw-r--r-- | phpBB/admin/admin_user_ban.php | 13 | ||||
-rw-r--r-- | phpBB/admin/admin_userauth.php | 11 | ||||
-rw-r--r-- | phpBB/admin/admin_users.php | 25 | ||||
-rw-r--r-- | phpBB/admin/index.php | 15 | ||||
-rw-r--r-- | phpBB/admin/page_footer_admin.php | 11 | ||||
-rw-r--r-- | phpBB/admin/page_header_admin.php | 13 | ||||
-rw-r--r-- | phpBB/admin/pagestart.inc | 16 |
15 files changed, 79 insertions, 402 deletions
diff --git a/phpBB/admin/admin_board.php b/phpBB/admin/admin_board.php index e19d6c28f2..a053d0807d 100644 --- a/phpBB/admin/admin_board.php +++ b/phpBB/admin/admin_board.php @@ -1,6 +1,6 @@ <?php /*************************************************************************** - * + * admin_board.php * ------------------- * begin : Thursday, Jul 12, 2001 * copyright : (C) 2001 The phpBB Group @@ -11,17 +11,6 @@ * ***************************************************************************/ - -/*************************************************************************** - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * - ***************************************************************************/ - if($setmodules == 1) { $file = basename(__FILE__); @@ -209,4 +198,4 @@ switch($mode) include('page_footer_admin.'.$phpEx); -?> +?>
\ No newline at end of file diff --git a/phpBB/admin/admin_db_utilities.php b/phpBB/admin/admin_db_utilities.php index 01122f5c69..6ba089ae7b 100644 --- a/phpBB/admin/admin_db_utilities.php +++ b/phpBB/admin/admin_db_utilities.php @@ -9,15 +9,6 @@ * $Id$ * ****************************************************************************/ - -/*************************************************************************** -* -* This program is free software; you can redistribute it and/or modify -* it under the terms of the GNU General Public License as published by -* the Free Software Foundation; either version 2 of the License, or -* (at your option) any later version. -* -***************************************************************************/ /*************************************************************************** * We will attempt to create a file based backup of all of the data in the @@ -1084,4 +1075,4 @@ if( isset($HTTP_GET_VARS['perform']) || isset($HTTP_POST_VARS['perform']) ) include('page_footer_admin.'.$phpEx); -?> +?>
\ No newline at end of file diff --git a/phpBB/admin/admin_forum_prune.php b/phpBB/admin/admin_forum_prune.php index 6a5883330a..bd4639a736 100644 --- a/phpBB/admin/admin_forum_prune.php +++ b/phpBB/admin/admin_forum_prune.php @@ -9,15 +9,7 @@ * $Id$ * ****************************************************************************/ - -/*************************************************************************** -* -* This program is free software; you can redistribute it and/or modify -* it under the terms of the GNU General Public License as published by -* the Free Software Foundation; either version 2 of the License, or -* (at your option) any later version. -* -***************************************************************************/ + /*************************************************************************** * This file is for the setup of the auto_pruning and also will allow for * immediate forum pruning as well. @@ -186,4 +178,4 @@ $template->pparse("body"); include('page_footer_admin.'.$phpEx); -?> +?>
\ No newline at end of file diff --git a/phpBB/admin/admin_forumauth.php b/phpBB/admin/admin_forumauth.php index 82fb47341b..742985fec0 100644 --- a/phpBB/admin/admin_forumauth.php +++ b/phpBB/admin/admin_forumauth.php @@ -11,17 +11,6 @@ * ***************************************************************************/ - -/*************************************************************************** - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * - ***************************************************************************/ - if($setmodules == 1) { $filename = basename(__FILE__); @@ -327,4 +316,4 @@ $template->pparse("body"); include('page_footer_admin.'.$phpEx); -?> +?>
\ No newline at end of file diff --git a/phpBB/admin/admin_forums.php b/phpBB/admin/admin_forums.php index f346b030cc..2c031725d2 100644 --- a/phpBB/admin/admin_forums.php +++ b/phpBB/admin/admin_forums.php @@ -1,6 +1,6 @@ <?php /*************************************************************************** - * + * admin_forums.php * ------------------- * begin : Thursday, Jul 12, 2001 * copyright : (C) 2001 The phpBB Group @@ -11,17 +11,6 @@ * ***************************************************************************/ - -/*************************************************************************** - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * - ***************************************************************************/ - if($setmodules==1) { $file = basename(__FILE__); @@ -39,87 +28,12 @@ function check_forum_name($forumname) { message_die(GENERAL_ERROR, "Couldn't get list of Categories", "", __LINE__, __FILE__, $sql); } - if ($db->sql_numrows($result) > 0) + if ($db->sql_num_rows($result) > 0) { message_die(GENERAL_ERROR, "A forum with that name already exists", "", __LINE__, __FILE__, $sql); } } -function get_info($mode, $id) -{ - global $db; - - switch($mode) - { - case 'category': - $table = CATEGORIES_TABLE; - $idfield = 'cat_id'; - $namefield = 'cat_title'; - break; - case 'forum': - $table = FORUMS_TABLE; - $idfield = 'forum_id'; - $namefield = 'forum_name'; - break; - default: - message_die(GENERAL_ERROR, "Wrong mode for generating select list", "", __LINE__, __FILE__); - } - $sql = " SELECT * - FROM $table - WHERE $idfield = $id"; - if( !$result = $db->sql_query($sql) ) - { - message_die(GENERAL_ERROR, "Couldn't get Forum/Category information", "", __LINE__, __FILE__, $sql); - } - if( $db->sql_numrows($result) != 1 ) - { - message_die(GENERAL_ERROR, "Forum/Category doesn't exist or multiple forums/categories with ID $id", "", __LINE__, __FILE__); - } - return $db->sql_fetchrow($result); -} - -function get_list($mode, $id, $select) -{ - global $db; - - switch($mode) - { - case 'category': - $table = CATEGORIES_TABLE; - $idfield = 'cat_id'; - $namefield = 'cat_title'; - break; - case 'forum': - $table = FORUMS_TABLE; - $idfield = 'forum_id'; - $namefield = 'forum_name'; - break; - default: - message_die(GENERAL_ERROR, "Wrong mode for generating select list", "", __LINE__, __FILE__); - } - - $sql = "SELECT * FROM $table"; - if( $select == FALSE) - { - $sql .= " WHERE $idfield != '$id'"; - } - if( !$result = $db->sql_query($sql) ) - { - message_die(GENERAL_ERROR, "Couldn't get list of Categories/Forums", "", __LINE__, __FILE__, $sql); - } - $cat_list = ""; - while( $row = $db->sql_fetchrow($result) ) - { - $s = ""; - if ($row[$idfield] == $id) - { - $s = " SELECTED"; - } - $catlist .= "<OPTION VALUE=\"$row[$idfield]\"$s>$row[$namefield]</OPTION>\n"; - } - return($catlist); -} - // // Include required files, get $phpEx and check permissions // @@ -142,10 +56,6 @@ if(isset($mode)) // Are we supposed to do something? { switch($mode) { - case 'forum_sync': - sync('forum', $HTTP_GET_VARS['forum_id']); - $show_index = TRUE; - break; case 'createforum': // Create a forum in the DB $sql = "SELECT max(forum_order) as max_order @@ -226,8 +136,22 @@ if(isset($mode)) // Are we supposed to do something? $buttonvalue = 'Change'; $forum_id = $HTTP_GET_VARS['forum_id']; - - $row = get_info('forum', $forum_id); + $sql = " SELECT + forum_name, + cat_id, + forum_desc, + forum_status + FROM " . FORUMS_TABLE . " + WHERE forum_id = $forum_id"; + if( !$result = $db->sql_query($sql) ) + { + message_die(GENERAL_ERROR, "Couldn't get Forum information", "", __LINE__, __FILE__, $sql); + } + if( $db->sql_numrows($result) != 1 ) + { + message_die(GENERAL_ERROR, "Forum doesn't exist or multiple forums with ID $forum_id", "", __LINE__, __FILE__); + } + $row = $db->sql_fetchrow($result); $forumname = $row['forum_name']; $cat_id = $row['cat_id']; $forumdesc = $row['forum_desc']; @@ -245,8 +169,22 @@ if(isset($mode)) // Are we supposed to do something? $forum_id = ''; } - $catlist = get_list('category', $cat_id, TRUE); + $sql = "SELECT * FROM " . CATEGORIES_TABLE; + if( !$result = $db->sql_query($sql) ) + { + message_die(GENERAL_ERROR, "Couldn't get list of Categories", "", __LINE__, __FILE__, $sql); + } + $cat_list = ""; + while( $row = $db->sql_fetchrow($result) ) + { + $s = ""; + if ($row['cat_id'] == $cat_id) + { + $s = " SELECTED"; + } + $catlist .= "<OPTION VALUE=\"$row[cat_id]\"$s>$row[cat_title]</OPTION>\n"; + } $forumstatus == FORUM_LOCKED ? $forumlocked = "selected" : $forumunlocked = "selected"; $statuslist = "<OPTION VALUE=\"".FORUM_UNLOCKED."\" $forumunlocked>Unlocked</OPTION>\n"; $statuslist .= "<OPTION VALUE=\"".FORUM_LOCKED."\" $forumlocked>Locked</OPTION>\n"; @@ -272,7 +210,18 @@ if(isset($mode)) // Are we supposed to do something? $buttonvalue = 'Change'; $cat_id = $HTTP_GET_VARS['cat_id']; - $row = get_info('category', $catid); + $sql = " SELECT * + FROM " . CATEGORIES_TABLE . " + WHERE cat_id = $cat_id"; + if( !$result = $db->sql_query($sql) ) + { + message_die(GENERAL_ERROR, "Couldn't get Category information", "", __LINE__, __FILE__, $sql); + } + if( $db->sql_numrows($result) != 1 ) + { + message_die(GENERAL_ERROR, "Category doesn't exist or multiple categories with ID $cat_id", "", __LINE__, __FILE__); + } + $row = $db->sql_fetchrow($result); $cat_title = $row['cat_title']; $template->set_filenames(array( @@ -298,133 +247,6 @@ if(isset($mode)) // Are we supposed to do something? print "Modforum: ". $HTTP_POST_VARS['forumname']." sql= <pre>$sql</pre>"; $show_index = TRUE; break; - case 'movedelforum': - $from_id = $HTTP_POST_VARS['from_id']; - $to_id = $HTTP_POST_VARS['to_id']; - $delete_old = $HTTP_POST_VARS['delete_old']; - - print "move '$from_id' to '$to_id'"; - - $sql = "SELECT * FROM ".FORUMS_TABLE." WHERE forum_id IN ($from_id, $to_id)"; - if( !$result = $db->sql_query($sql) ) - { - message_die(GENERAL_ERROR, "Couldn't verify existence of forums", "", __LINE__, __FILE__, $sql); - } - if($db->sql_numrows($result) != 2) - { - message_die(GENERAL_ERROR, "Ambiguous forum ID's", "", __LINE__, __FILE__); - } - - // Either delete or move all posts in a forum - if($delete_old == 1) - { - include($phpbb_root_path . "/include/prune.$phpEx"); - prune($from_id, FALSE); // Delete everything from forum - } - else - { - $sql = "UPDATE ".TOPICS_TABLE." SET - forum_id = '$to_id' - WHERE forum_id = '$from_id'"; - if( !$result = $db->sql_query($sql) ) - { - message_die(GENERAL_ERROR, "Couldn't move topics to other forum", "", __LINE__, __FILE__, $sql); - } - $sql = "UPDATE ".POSTS_TABLE." SET - forum_id = '$to_id' - WHERE forum_id = '$from_id'"; - if( !$result = $db->sql_query($sql) ) - { - message_die(GENERAL_ERROR, "Couldn't move posts to other forum", "", __LINE__, __FILE__, $sql); - } - sync('forum', $to_id); - } - - $sql = "DELETE FROM ".FORUMS_TABLE." - WHERE forum_id = '$from_id'"; - if( !$result = $db->sql_query($sql) ) - { - message_die(GENERAL_ERROR, "Couldn't delete forum", "", __LINE__, __FILE__, $sql); - } - - $show_index = TRUE; - break; - case 'movedelcat': - $from_id = $HTTP_POST_VARS['from_id']; - $to_id = $HTTP_POST_VARS['to_id']; - print "move '$from_id' to '$to_id'"; - - $sql = "SELECT * FROM ".CATEGORIES_TABLE." WHERE cat_id IN ($from_id, $to_id)"; - if( !$result = $db->sql_query($sql) ) - { - message_die(GENERAL_ERROR, "Couldn't verify existence of categories", "", __LINE__, __FILE__, $sql); - } - if($db->sql_numrows($result) != 2) - { - message_die(GENERAL_ERROR, "Ambiguous category ID's", "", __LINE__, __FILE__); - } - - $sql = "UPDATE ".FORUMS_TABLE." SET - cat_id = '$to_id' - WHERE cat_id = '$from_id'"; - if( !$result = $db->sql_query($sql) ) - { - message_die(GENERAL_ERROR, "Couldn't move forums to other category", "", __LINE__, __FILE__, $sql); - } - - $sql = "DELETE FROM ".CATEGORIES_TABLE." - WHERE cat_id = '$from_id'"; - if( !$result = $db->sql_query($sql) ) - { - message_die(GENERAL_ERROR, "Couldn't delete category", "", __LINE__, __FILE__, $sql); - } - - $show_index = TRUE; - break; - case 'deletecat': - print "Deletecat"; - $cat_id = $HTTP_GET_VARS['cat_id']; - $to_ids = get_list('category', $cat_id, FALSE); - $buttonvalue = "Move&Delete"; - $newmode = 'movedelcat'; - $catinfo = get_info('category', $cat_id); - $name = $catinfo['cat_title']; - - $template->set_filenames(array( - "body" => "admin/forum_delete_body.tpl") - ); - $template->assign_vars(array( - 'NAME' => $name, - 'S_FORUM_ACTION' => $PHP_SELF, - 'S_FROM_ID' => $cat_id, - 'S_TO_IDS' => $to_ids, - 'S_NEWMODE' => $newmode, - 'BUTTONVALUE' => $buttonvalue) - ); - $template->pparse("body"); - break; - case 'deleteforum': - print 'Deleteforum'; - $forum_id = $HTTP_GET_VARS['forum_id']; - $to_ids = get_list('forum', $forum_id, FALSE); - $buttonvalue = "Move&Delete"; - $newmode = 'movedelforum'; - $foruminfo = get_info('forum', $forum_id); - $name = $foruminfo['forum_name']; - - $template->set_filenames(array( - "body" => "admin/forum_delete_body.tpl") - ); - $template->assign_vars(array( - 'NAME' => $name, - 'S_FORUM_ACTION' => $PHP_SELF, - 'S_FROM_ID' => $forum_id, - 'S_TO_IDS' => $to_ids, - 'S_NEWMODE' => $newmode, - 'BUTTONVALUE' => $buttonvalue) - ); - $template->pparse("body"); - break; case 'cat_order': case 'forum_order': message_die(GENERAL_ERROR, "Sorry, not implemented yet"); @@ -492,8 +314,7 @@ if($total_categories = $db->sql_numrows($q_categories)) $template->assign_block_vars("catrow", array( "CAT_ID" => $cat_id, "CAT_DESC" => stripslashes($category_rows[$i]['cat_title']), - "CAT_EDIT" => "<a href='$PHPSELF?mode=editcat&cat_id=$cat_id'>Edit</a>", - "CAT_DELETE" => "<a href='$PHPSELF?mode=deletecat&cat_id=$cat_id'>Delete</a>", + "CAT_EDIT" => "<a href='$PHPSELF?mode=editcat&cat_id=$cat_id'>Edit/Delete</a>", "CAT_UP" => "<a href='$PHPSELF?mode=cat_order&pos=1&cat_id=$cat_id'>Move up</a>", "CAT_DOWN" => "<a href='$PHPSELF?mode=cat_order&pos=-1&forum_id=$cat_id'>Move down</a>", "U_VIEWCAT" => append_sid("index.$phpEx?viewcat=$cat_id"), @@ -516,14 +337,10 @@ if($total_categories = $db->sql_numrows($q_categories)) "FORUM_NAME" => stripslashes($forum_rows[$j]['forum_name']), "FORUM_DESC" => stripslashes($forum_rows[$j]['forum_desc']), "ROW_COLOR" => $row_color, - "NUM_TOPICS" => $forum_rows[$j]['forum_topics'], - "NUM_POSTS" => $forum_rows[$j]['forum_posts'], - "U_VIEWFORUM" => append_sid($phpbb_root_path."viewforum.$phpEx?" . POST_FORUM_URL . "=$forum_id&" . $forum_rows[$j]['forum_posts']), - "FORUM_EDIT" => "<a href='".append_sid("$PHPSELF?mode=editforum&forum_id=$forum_id")."'>Edit</a>", - "FORUM_DELETE" => "<a href='".append_sid("$PHPSELF?mode=deleteforum&forum_id=$forum_id")."'>Delete</a>", - "FORUM_UP" => "<a href='".append_sid("$PHPSELF?forum_mode=order&pos=1&forum_id=$forum_id")."'>Move up</a>", - "FORUM_DOWN" => "<a href='".append_sid("$PHPSELF?mode=forum_order&pos=-1&forum_id=$forum_id")."'>Move down</a>", - "FORUM_SYNC" => "<a href='".append_sid("$PHPSELF?mode=forum_sync&forum_id=$forum_id")."'>Sync</a>") + "U_VIEWFORUM" => append_sid("viewforum.$phpEx?" . POST_FORUM_URL . "=$forum_id&" . $forum_rows[$j]['forum_posts']), + "FORUM_EDIT" => "<a href='$PHPSELF?mode=editforum&forum_id=$forum_id'>Edit/Delete</a>", + "FORUM_UP" => "<a href='$PHPSELF?forum_mode=order&pos=1&forum_id=$forum_id'>Move up</a>", + "FORUM_DOWN" => "<a href='$PHPSELF?mode=forum_order&pos=-1&forum_id=$forum_id'>Move down</a>") ); } // for ... forums $template->assign_block_vars("catrow.forumrow", array( @@ -559,4 +376,5 @@ $template->pparse("body"); // Page Footer // include('page_footer_admin.'.$phpEx); -?> + +?>
\ No newline at end of file diff --git a/phpBB/admin/admin_groupauth.php b/phpBB/admin/admin_groupauth.php index 32e235e1a6..ca1f35f66a 100644 --- a/phpBB/admin/admin_groupauth.php +++ b/phpBB/admin/admin_groupauth.php @@ -1,6 +1,6 @@ <?php /*************************************************************************** - * admin_userauth.php + * admin_groupauth.php * ------------------- * begin : Saturday, Feb 13, 2001 * copyright : (C) 2001 The phpBB Group @@ -11,17 +11,6 @@ * ***************************************************************************/ - -/*************************************************************************** - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * - ***************************************************************************/ - if($setmodules == 1) { $filename = basename(__FILE__); @@ -881,4 +870,4 @@ $template->pparse("body"); include('page_footer_admin.'.$phpEx); -?> +?>
\ No newline at end of file diff --git a/phpBB/admin/admin_groups.php b/phpBB/admin/admin_groups.php index 9204f00443..d84f676dba 100644 --- a/phpBB/admin/admin_groups.php +++ b/phpBB/admin/admin_groups.php @@ -11,17 +11,6 @@ * ***************************************************************************/ - -/*************************************************************************** - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * - ***************************************************************************/ - if($setmodules == 1) { $filename = basename(__FILE__); @@ -238,6 +227,7 @@ else if( $HTTP_POST_VARS['updategroup'] == "update" ) else { include("page_header_admin." . $phpEx); + $sql = "SELECT group_id, group_name FROM " . GROUPS_TABLE . " WHERE group_single_user <> " . TRUE . " @@ -271,4 +261,4 @@ else } include($phpbb_root_path . 'includes/page_tail.'.$phpEx); -?> +?>
\ No newline at end of file diff --git a/phpBB/admin/admin_smilies.php b/phpBB/admin/admin_smilies.php index d56ccba5c1..2f71d143b7 100644 --- a/phpBB/admin/admin_smilies.php +++ b/phpBB/admin/admin_smilies.php @@ -1,6 +1,6 @@ <?php /*************************************************************************** -* admin_smilies.php +* admin_smilies.php * ------------------- * begin : Thu May 31, 2001 * copyright : (C) 2001 The phpBB Group @@ -10,15 +10,6 @@ * ****************************************************************************/ -/*************************************************************************** -* -* This program is free software; you can redistribute it and/or modify -* it under the terms of the GNU General Public License as published by -* the Free Software Foundation; either version 2 of the License, or -* (at your option) any later version. -* -***************************************************************************/ - /************************************************************************** * This file will be used for modifying the smiley settings for a board. **************************************************************************/ diff --git a/phpBB/admin/admin_user_ban.php b/phpBB/admin/admin_user_ban.php index ce3ca50bca..b8c8f1de62 100644 --- a/phpBB/admin/admin_user_ban.php +++ b/phpBB/admin/admin_user_ban.php @@ -11,17 +11,6 @@ * ***************************************************************************/ - -/*************************************************************************** - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * - ***************************************************************************/ - if($setmodules == 1) { $filename = basename(__FILE__); @@ -505,4 +494,4 @@ $template->pparse("body"); include('page_footer_admin.'.$phpEx); -?> +?>
\ No newline at end of file diff --git a/phpBB/admin/admin_userauth.php b/phpBB/admin/admin_userauth.php index f382a3e765..609d5b0021 100644 --- a/phpBB/admin/admin_userauth.php +++ b/phpBB/admin/admin_userauth.php @@ -11,17 +11,6 @@ * ***************************************************************************/ - -/*************************************************************************** - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * - ***************************************************************************/ - if($setmodules == 1) { $filename = basename(__FILE__); diff --git a/phpBB/admin/admin_users.php b/phpBB/admin/admin_users.php index 91f8f53a05..09b375a34b 100644 --- a/phpBB/admin/admin_users.php +++ b/phpBB/admin/admin_users.php @@ -11,17 +11,6 @@ * ***************************************************************************/ - -/*************************************************************************** - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * - ***************************************************************************/ - if($setmodules == 1) { $filename = basename(__FILE__); @@ -53,6 +42,10 @@ else if( $userdata['user_level'] != ADMIN ) { message_die(GENERAL_MESSAGE, $lang['Not_admin']); } + +// +// Begin program +// if ( isset($HTTP_GET_VARS['submit']) ) { // // This looks familiar doesn't it? It's the user profile page! :) @@ -120,8 +113,7 @@ if ( isset($HTTP_GET_VARS['submit']) ) { $template->set_filenames(array( - "body" => "admin/user_edit_body.tpl" - ) + "body" => "admin/user_edit_body.tpl") ); $template->assign_vars(array( @@ -304,7 +296,6 @@ else if($HTTP_POST_VARS[submit] && $HTTP_POST_VARS['user_id']) $user_avatar_type = (!empty($HTTP_POST_FILES['avatar']['type'])) ? $HTTP_POST_FILES['avatar']['type'] : ""; $user_avatar = (empty($user_avatar_loc) && $mode == "editprofile") ? $userdata['user_avatar'] : ""; - if(isset($HTTP_POST_VARS['submit'])) { $error = FALSE; @@ -660,6 +651,7 @@ else if($HTTP_POST_VARS[submit] && $HTTP_POST_VARS['user_id']) { $error = TRUE; } + if( $error == TRUE ) { message_die(GENERAL_ERROR, "Could not update user table", "", __LINE__, __FILE__, $sql); @@ -691,7 +683,7 @@ else if($HTTP_POST_VARS[submit] && $HTTP_POST_VARS['user_id']) } else { - message_die(GENERAL_ERROR, $error_msg, "", __LINE__, __FILE__, ""); + message_die(GENERAL_ERROR, $error_msg, "", __LINE__, __FILE__, ""); } } else @@ -732,6 +724,7 @@ else ); $template->pparse('body'); + include('page_footer_admin.'.$phpEx); } -?> +?>
\ No newline at end of file diff --git a/phpBB/admin/index.php b/phpBB/admin/index.php index 4abbca91e5..130b8aa057 100644 --- a/phpBB/admin/index.php +++ b/phpBB/admin/index.php @@ -1,6 +1,6 @@ <?php /*************************************************************************** - * + * (admin) index.php * ------------------- * begin : Saturday, Feb 13, 2001 * copyright : (C) 2001 The phpBB Group @@ -11,17 +11,6 @@ * ***************************************************************************/ - -/*************************************************************************** - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * - ***************************************************************************/ - $phpbb_root_path = "./../"; include($phpbb_root_path . 'extension.inc'); include($phpbb_root_path . 'common.'.$phpEx); @@ -436,4 +425,4 @@ else } -?> +?>
\ No newline at end of file diff --git a/phpBB/admin/page_footer_admin.php b/phpBB/admin/page_footer_admin.php index 0c8c8f38c4..2d18791fe6 100644 --- a/phpBB/admin/page_footer_admin.php +++ b/phpBB/admin/page_footer_admin.php @@ -11,17 +11,6 @@ * ***************************************************************************/ - -/*************************************************************************** - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * - ***************************************************************************/ - // // Show the overall footer. // diff --git a/phpBB/admin/page_header_admin.php b/phpBB/admin/page_header_admin.php index d0a727e1c1..448f85f181 100644 --- a/phpBB/admin/page_header_admin.php +++ b/phpBB/admin/page_header_admin.php @@ -1,6 +1,6 @@ <?php /*************************************************************************** - * page_header.php + * page_header_admin.php * ------------------- * begin : Saturday, Feb 13, 2001 * copyright : (C) 2001 The phpBB Group @@ -11,17 +11,6 @@ * ***************************************************************************/ - -/*************************************************************************** - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * - ***************************************************************************/ - define(HEADER_INC, TRUE); // diff --git a/phpBB/admin/pagestart.inc b/phpBB/admin/pagestart.inc index 06f11fcccb..9479a24ba1 100644 --- a/phpBB/admin/pagestart.inc +++ b/phpBB/admin/pagestart.inc @@ -1,6 +1,6 @@ <? /*************************************************************************** - * + * pagestart.inc * ------------------- * begin : Thursday, Aug 2, 2001 * copyright : (C) 2001 The phpBB Group @@ -11,17 +11,6 @@ * ***************************************************************************/ - -/*************************************************************************** - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * - ***************************************************************************/ - $phpbb_root_path = "../"; include($phpbb_root_path . 'extension.inc'); include($phpbb_root_path . 'common.'.$phpEx); @@ -49,4 +38,5 @@ if ($no_page_header != TRUE) // needed in the calling script. include('page_header_admin.'.$phpEx); } -?> + +?>
\ No newline at end of file |