From 8b82f40009502ea64e5df749bc890fd9547e8b40 Mon Sep 17 00:00:00 2001 From: "Paul S. Owen" Date: Fri, 27 Jul 2001 23:16:09 +0000 Subject: Removed header frame, reduced timezone naming, added DB size for MySQL, no major technical changes git-svn-id: file:///svn/phpbb/trunk@753 89ea8834-ac86-4346-8a33-228a782c2dd0 --- phpBB/admin/admin_board.php | 94 ++++++++++++++++++++------------------ phpBB/admin/admin_db_utilities.php | 3 +- phpBB/admin/admin_forum_prune.php | 21 +++++++-- phpBB/admin/admin_forumauth.php | 6 +-- phpBB/admin/admin_userauth.php | 2 +- phpBB/admin/page_header_admin.php | 22 +++++---- 6 files changed, 85 insertions(+), 63 deletions(-) (limited to 'phpBB/admin') diff --git a/phpBB/admin/admin_board.php b/phpBB/admin/admin_board.php index 36f3dbc2cd..0715123f27 100644 --- a/phpBB/admin/admin_board.php +++ b/phpBB/admin/admin_board.php @@ -25,7 +25,7 @@ if($setmodules == 1) { $file = basename(__FILE__); - $module['General']['config'] = "$file?mode=config"; + $module['General']['Configuration'] = "$file?mode=config"; return; } @@ -138,54 +138,58 @@ switch($mode) $template->pparse("reg_header"); } - $template->set_filenames(array("body" => "admin/admin_config_body.tpl")); + $template->set_filenames(array( + "body" => "admin/admin_config_body.tpl") + ); - $template->assign_vars(array("S_CONFIG_ACTION" => append_sid("admin/admin_board.$phpEx"), - "SITENAME" => $sitename, - "ACTIVATION_YES" => $activation_yes, - "ACTIVATION_NO" => $activation_no, - "FLOOD_INTERVAL" => $flood_interval, - "TOPICS_PER_PAGE" => $topics_per_page, - "POSTS_PER_PAGE" => $posts_per_page, - "HOT_TOPIC" => $hot_topic, - "TEMPLATE_SELECT" => $template_select, - "THEME_SELECT" => $theme_select, - "LANG_SELECT" => $lang_select, - "L_DATE_FORMAT_EXPLAIN" => $lang['Date_format_explain'], - "DATE_FORMAT" => $date_format, - "TIMEZONE_SELECT" => $timezone_select, - "GZIP_YES" => $gzip_yes, - "GZIP_NO" => $gzip_no, - "HTML_YES" => $html_yes, - "HTML_NO" => $html_no, - "BBCODE_YES" => $bbcode_yes, - "BBCODE_NO" => $bbcode_no, - "SMILE_YES" => $smile_yes, - "SMILE_NO" => $smile_no, - "SIG_YES" => $sig_yes, - "SIG_NO" => $sig_no, - "NAMECHANGE_YES" => $namechange_yes, - "NAMECHANGE_NO" => $namechange_no, - "AVATARS_LOCAL_YES" => $avatars_local_yes, - "AVATARS_LOCAL_NO" => $avatars_local_no, - "AVATARS_REMOTE_YES" => $avatars_remote_yes, - "AVATARS_REMOTE_NO" => $avatars_remote_no, - "AVATARS_UPLOAD_YES" => $avatars_upload_yes, - "AVATARS_UPLOAD_NO" => $avatars_upload_no, - "AVATAR_FILESIZE" => $avatar_filesize, - "AVATAR_HEIGHT" => $avatar_height, - "AVATAR_WIDTH" => $avatar_width, - "AVATAR_PATH" => $avatar_path, - "ADMIN_EMAIL" => $admin_email, - "EMAIL_SIG" => $email_sig, - "SMTP_YES" => $smtp_yes, - "SMTP_NO" => $smtp_no, - "SMTP_SERVER" => $smtp_server)); + $template->assign_vars(array( + "S_CONFIG_ACTION" => append_sid("admin/admin_board.$phpEx"), + "SITENAME" => $sitename, + "ACTIVATION_YES" => $activation_yes, + "ACTIVATION_NO" => $activation_no, + "FLOOD_INTERVAL" => $flood_interval, + "TOPICS_PER_PAGE" => $topics_per_page, + "POSTS_PER_PAGE" => $posts_per_page, + "HOT_TOPIC" => $hot_topic, + "TEMPLATE_SELECT" => $template_select, + "THEME_SELECT" => $theme_select, + "LANG_SELECT" => $lang_select, + "L_DATE_FORMAT_EXPLAIN" => $lang['Date_format_explain'], + "DATE_FORMAT" => $date_format, + "TIMEZONE_SELECT" => $timezone_select, + "GZIP_YES" => $gzip_yes, + "GZIP_NO" => $gzip_no, + "HTML_YES" => $html_yes, + "HTML_NO" => $html_no, + "BBCODE_YES" => $bbcode_yes, + "BBCODE_NO" => $bbcode_no, + "SMILE_YES" => $smile_yes, + "SMILE_NO" => $smile_no, + "SIG_YES" => $sig_yes, + "SIG_NO" => $sig_no, + "NAMECHANGE_YES" => $namechange_yes, + "NAMECHANGE_NO" => $namechange_no, + "AVATARS_LOCAL_YES" => $avatars_local_yes, + "AVATARS_LOCAL_NO" => $avatars_local_no, + "AVATARS_REMOTE_YES" => $avatars_remote_yes, + "AVATARS_REMOTE_NO" => $avatars_remote_no, + "AVATARS_UPLOAD_YES" => $avatars_upload_yes, + "AVATARS_UPLOAD_NO" => $avatars_upload_no, + "AVATAR_FILESIZE" => $avatar_filesize, + "AVATAR_HEIGHT" => $avatar_height, + "AVATAR_WIDTH" => $avatar_width, + "AVATAR_PATH" => $avatar_path, + "ADMIN_EMAIL" => $admin_email, + "EMAIL_SIG" => $email_sig, + "SMTP_YES" => $smtp_yes, + "SMTP_NO" => $smtp_no, + "SMTP_SERVER" => $smtp_server) + ); $template->pparse("body"); - break; - + break; } 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 3c0dc9274d..ef4e9da39a 100644 --- a/phpBB/admin/admin_db_utilities.php +++ b/phpBB/admin/admin_db_utilities.php @@ -307,8 +307,7 @@ function get_table_def_postgres($table, $crlf) if (!$result) { - $error = $db->sql_error(); - message_die(GENERAL_ERROR, 'Failed in get_table_def (show fields) : ' . $error['message']); + message_die(GENERAL_ERROR, "Failed in get_table_def (show fields)", "", __LINE__, __FILE__, $sql_checks); } while ($row = $db->sql_fetchrow($result)) diff --git a/phpBB/admin/admin_forum_prune.php b/phpBB/admin/admin_forum_prune.php index a72eafdcd6..ac6a9a84bb 100644 --- a/phpBB/admin/admin_forum_prune.php +++ b/phpBB/admin/admin_forum_prune.php @@ -34,7 +34,7 @@ if( $setmodules == 1 ) { $filename = basename(__FILE__); - $module['Forums']['prune'] = $filename; + $module['Forums']['Prune'] = $filename; return; } @@ -117,22 +117,29 @@ else if($submit == "Prune") { $prunedays = $HTTP_POST_VARS['prunedays']; + // Convert days to seconds for timestamp functions... $prunesecs = $prunedays * 1440 * 60; $prunedate = time() - $prunesecs; + + include('page_header_admin.'.$phpEx); + $template->set_filenames(array( "body" => "admin/forum_prune_result_body.tpl") ); + reset($forum_rows); while(list(, $forum_data) = each ($forum_rows)) { $p_result = prune($forum_data['forum_id'], $prunedate); + $template->assign_block_vars("prune_results", array( "FORUM_NAME" => $forum_data['forum_name'], "FORUM_TOPICS" => $p_result['topics'], "FORUM_POSTS" => $p_result['posts']) ); } + $template->assign_vars(array( "PRUNE_MSG" => "Pruning of forums was successful") ); @@ -148,17 +155,21 @@ else // // Output a selection table if no forum id has been specified. // + include('page_header_admin.'.$phpEx); + $template->set_filenames(array( "body" => "admin/forum_prune_select_body.tpl") ); + $select_list = "\n"; + // // Assign the template variables. // @@ -172,13 +183,17 @@ else // // Output the form to retrieve Prune information. // + include('page_header_admin.'.$phpEx); + $template->set_filenames(array( "body" => "admin/forum_prune_body.tpl") ); $forum_name = ($forum_id == "ALL") ? 'All Forums' : $forum_rows[0]['forum_name']; + $prune_data = "Prune Topics that haven't been posted to in the last "; $prune_data .= " Days."; + $hidden_input = ""; // @@ -199,4 +214,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 6562a3ca4e..feb76a1cb3 100644 --- a/phpBB/admin/admin_forumauth.php +++ b/phpBB/admin/admin_forumauth.php @@ -59,7 +59,7 @@ else if( $userdata['user_level'] != ADMIN ) // Start program - define vars // $simple_auth_ary = array( - 0 => array(0, 0, 0, 0, 1, 0, 3, 3), + 0 => array(0, 0, 0, 0, 1, 1, 3, 3), 1 => array(0, 0, 0, 0, 3, 3, 3, 3), 2 => array(0, 0, 1, 1, 1, 1, 3, 3), 3 => array(1, 1, 1, 1, 1, 1, 3, 3), @@ -67,8 +67,8 @@ $simple_auth_ary = array( 5 => array(2, 2, 2, 2, 2, 2, 2, 3), 6 => array(0, 3, 3, 3, 3, 3, 3, 3), 7 => array(3, 3, 3, 3, 3, 3, 3, 3), - 8 => array(0, 0, 3, 0, 0, 0, 3, 3), - 9 => array(0, 0, 3, 1, 0, 0, 3, 3) + 8 => array(0, 0, 3, 0, 1, 1, 3, 3), + 9 => array(0, 0, 3, 1, 1, 1, 3, 3) ); $simple_auth_types = array("Public", "Test Restricted", "Registered", "Registered [Hidden]", "Private", "Private [Hidden]", "Moderators", "Moderators [Hidden]", "Moderator Post + All Reply", "Moderator Post + Reg Reply"); diff --git a/phpBB/admin/admin_userauth.php b/phpBB/admin/admin_userauth.php index d5ae0517f5..19027be152 100644 --- a/phpBB/admin/admin_userauth.php +++ b/phpBB/admin/admin_userauth.php @@ -583,7 +583,7 @@ if(isset($HTTP_POST_VARS['submit']) && !empty($HTTP_POST_VARS[POST_USERS_URL])) } else { - header("Location: admin_userauth.$phpEx?" . POST_USERS_URL . "=$user_id"); + header("Location: " . append_sid("admin_userauth.$phpEx?" . POST_USERS_URL . "=$user_id")); } } diff --git a/phpBB/admin/page_header_admin.php b/phpBB/admin/page_header_admin.php index 336af4ac08..d0a727e1c1 100644 --- a/phpBB/admin/page_header_admin.php +++ b/phpBB/admin/page_header_admin.php @@ -52,12 +52,8 @@ if($board_config['gzip_compress']) } } -if(empty($template_header)) -{ - $template_header = "admin/page_header.tpl"; -} $template->set_filenames(array( - "header" => $template_header) + "header" => "admin/page_header.tpl") ); // @@ -129,12 +125,21 @@ $template->assign_vars(array( "T_TR_COLOR1" => "#".$theme['tr_color1'], "T_TR_COLOR2" => "#".$theme['tr_color2'], "T_TR_COLOR3" => "#".$theme['tr_color3'], + "T_TR_CLASS1" => $theme['tr_class1'], + "T_TR_CLASS2" => $theme['tr_class2'], + "T_TR_CLASS3" => $theme['tr_class3'], "T_TH_COLOR1" => "#".$theme['th_color1'], "T_TH_COLOR2" => "#".$theme['th_color2'], "T_TH_COLOR3" => "#".$theme['th_color3'], + "T_TH_CLASS1" => $theme['th_class1'], + "T_TH_CLASS2" => $theme['th_class2'], + "T_TH_CLASS3" => $theme['th_class3'], "T_TD_COLOR1" => "#".$theme['td_color1'], "T_TD_COLOR2" => "#".$theme['td_color2'], "T_TD_COLOR3" => "#".$theme['td_color3'], + "T_TD_CLASS1" => $theme['td_class1'], + "T_TD_CLASS2" => $theme['td_class2'], + "T_TD_CLASS3" => $theme['td_class3'], "T_FONTFACE1" => $theme['fontface1'], "T_FONTFACE2" => $theme['fontface2'], "T_FONTFACE3" => $theme['fontface3'], @@ -144,10 +149,9 @@ $template->assign_vars(array( "T_FONTCOLOR1" => "#".$theme['fontcolor1'], "T_FONTCOLOR2" => "#".$theme['fontcolor2'], "T_FONTCOLOR3" => "#".$theme['fontcolor3'], - "T_IMG1" => $theme['img1'], - "T_IMG2" => $theme['img2'], - "T_IMG3" => $theme['img3'], - "T_IMG4" => $theme['img4']) + "T_SPAN_CLASS1" => $theme['span_class1'], + "T_SPAN_CLASS2" => $theme['span_class2'], + "T_SPAN_CLASS3" => $theme['span_class3']) ); header ("Expires: " . gmdate("D, d M Y H:i:s", time()) . " GMT"); -- cgit v1.2.1