1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-05 00:07:44 +02:00

Loads of bug fixes and updates

git-svn-id: file:///svn/phpbb/branches/phpBB-2_0_0@2564 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
Paul S. Owen
2002-05-12 00:47:41 +00:00
parent 88214ed58d
commit 0735fb32b9
39 changed files with 1538 additions and 1559 deletions

View File

@@ -23,9 +23,9 @@ if( !empty($setmodules) )
//
// Let's set the root dir for phpBB
//
$phpbb_root_path = "../";
$phpbb_root_path = "./../";
require($phpbb_root_path . 'extension.inc');
require('pagestart.' . $phpEx);
require('./pagestart.' . $phpEx);
include($phpbb_root_path . 'includes/functions_selects.'.$phpEx);
//
@@ -311,6 +311,6 @@ $template->assign_vars(array(
$template->pparse("body");
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
?>

View File

@@ -42,6 +42,7 @@ if( !empty($setmodules) )
{
$file_uploads = @get_cfg_var('file_uploads');
}
if( ($file_uploads != 0 || empty($file_uploads)) && (strtolower($file_uploads) != 'off') && (@phpversion() != '4.0.4pl1') )
{
$module['General']['Restore_DB'] = $filename . "?perform=restore";
@@ -54,9 +55,9 @@ if( !empty($setmodules) )
// Load default header
//
$no_page_header = TRUE;
$phpbb_root_path = "../";
$phpbb_root_path = "./../";
require($phpbb_root_path . 'extension.inc');
require('pagestart.' . $phpEx);
require('./pagestart.' . $phpEx);
include($phpbb_root_path . 'includes/sql_parse.'.$phpEx);
//
@@ -695,7 +696,7 @@ if( isset($HTTP_GET_VARS['perform']) || isset($HTTP_POST_VARS['perform']) )
break;
}
include('page_header_admin.'.$phpEx);
include('./page_header_admin.'.$phpEx);
$template->set_filenames(array(
"body" => "admin/admin_message_body.tpl")
@@ -740,7 +741,7 @@ if( isset($HTTP_GET_VARS['perform']) || isset($HTTP_POST_VARS['perform']) )
if( !isset($HTTP_POST_VARS['backupstart']) && !isset($HTTP_GET_VARS['backupstart']))
{
include('page_header_admin.'.$phpEx);
include('./page_header_admin.'.$phpEx);
$template->set_filenames(array(
"body" => "admin/db_utils_backup_body.tpl")
@@ -782,11 +783,11 @@ if( isset($HTTP_GET_VARS['perform']) || isset($HTTP_POST_VARS['perform']) )
"MESSAGE_TEXT" => $lang['Backup_download'])
);
include('page_header_admin.'.$phpEx);
include('./page_header_admin.'.$phpEx);
$template->pparse("body");
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
}
header("Pragma: no-cache");
@@ -873,7 +874,7 @@ if( isset($HTTP_GET_VARS['perform']) || isset($HTTP_POST_VARS['perform']) )
//
// Define Template files...
//
include('page_header_admin.'.$phpEx);
include('./page_header_admin.'.$phpEx);
$template->set_filenames(array(
"body" => "admin/db_utils_restore_body.tpl")
@@ -907,7 +908,6 @@ if( isset($HTTP_GET_VARS['perform']) || isset($HTTP_POST_VARS['perform']) )
if($backup_file_tmpname == "" || $backup_file_name == "")
{
include('page_header_admin.'.$phpEx);
message_die(GENERAL_MESSAGE, $lang['Restore_Error_no_file']);
}
//
@@ -943,7 +943,6 @@ if( isset($HTTP_GET_VARS['perform']) || isset($HTTP_POST_VARS['perform']) )
}
else
{
include('page_header_admin.'.$phpEx);
message_die(GENERAL_ERROR, $lang['Restore_Error_decompress']);
}
}
@@ -958,13 +957,11 @@ if( isset($HTTP_GET_VARS['perform']) || isset($HTTP_POST_VARS['perform']) )
}
else
{
include('page_header_admin.'.$phpEx);
message_die(GENERAL_ERROR, $lang['Restore_Error_filename'] ." $backup_file_type $backup_file_name");
}
}
else
{
include('page_header_admin.'.$phpEx);
message_die(GENERAL_ERROR, $lang['Restore_Error_uploading']);
}
@@ -991,15 +988,13 @@ if( isset($HTTP_GET_VARS['perform']) || isset($HTTP_POST_VARS['perform']) )
if(!$result && ( !(SQL_LAYER == 'postgresql' && eregi("drop table", $sql) ) ) )
{
//include('page_header_admin.'.$phpEx);
// echo "~~$sql~~";
message_die(GENERAL_ERROR, "Error importing backup file", "", __LINE__, __FILE__, $sql);
}
}
}
}
include('page_header_admin.'.$phpEx);
include('./page_header_admin.'.$phpEx);
$template->set_filenames(array(
"body" => "admin/admin_message_body.tpl")
@@ -1019,6 +1014,6 @@ if( isset($HTTP_GET_VARS['perform']) || isset($HTTP_POST_VARS['perform']) )
}
}
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
?>

View File

@@ -33,16 +33,15 @@ if( !empty($setmodules) )
//
// Include required files, get $phpEx and check permissions
//
$phpbb_root_path = "../";
$phpbb_root_path = "./../";
require($phpbb_root_path . 'extension.inc');
require('pagestart.' . $phpEx);
require('./pagestart.' . $phpEx);
if( isset($HTTP_POST_VARS['add_name']) )
{
include($phpbb_root_path . 'includes/functions_validate.'.$phpEx);
$disallowed_user = ( isset($HTTP_POST_VARS['disallowed_user']) ) ? $HTTP_POST_VARS['disallowed_user'] : $HTTP_GET_VARS['disallowed_user'];
$disallowed_user = preg_replace( '/\*/', '%', $disallowed_user );
if( !validate_username($disallowed_user) )
{
@@ -110,8 +109,6 @@ else
$user = array();
for( $i = 0; $i < count($disallowed); $i++ )
{
$disallowed[$i]['disallow_username'] = preg_replace('/%/', '*', $disallowed[$i]['disallow_username']);
$disallow_select .= '<option value="' . $disallowed[$i]['disallow_id'] . '">' . $disallowed[$i]['disallow_username'] . '</option>';
}
}
@@ -140,4 +137,6 @@ $template->assign_vars(array(
$template->pparse("body");
include('./page_footer_admin.'.$phpEx);
?>

View File

@@ -32,9 +32,9 @@ if ( !empty($setmodules) )
//
// Load default header
//
$phpbb_root_path = '../';
$phpbb_root_path = "./../";
require($phpbb_root_path . 'extension.inc');
require('pagestart.' . $phpEx);
require('./pagestart.' . $phpEx);
require($phpbb_root_path . 'includes/prune.'.$phpEx);
require($phpbb_root_path . 'includes/functions_admin.'.$phpEx);
@@ -193,6 +193,6 @@ else
//
$template->pparse('body');
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
?>

View File

@@ -34,9 +34,9 @@ if( !empty($setmodules) )
// Load default header
//
$no_page_header = TRUE;
$phpbb_root_path = "../";
$phpbb_root_path = "./../";
require($phpbb_root_path . 'extension.inc');
require('pagestart.' . $phpEx);
require('./pagestart.' . $phpEx);
//
// Start program - define vars
@@ -342,10 +342,10 @@ else
}
include('page_header_admin.'.$phpEx);
include('./page_header_admin.'.$phpEx);
$template->pparse("body");
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
?>

View File

@@ -32,9 +32,9 @@ if( !empty($setmodules) )
//
// Load default header
//
$phpbb_root_path = "../";
$phpbb_root_path = "./../";
require($phpbb_root_path . 'extension.inc');
require('pagestart.' . $phpEx);
require('./pagestart.' . $phpEx);
include($phpbb_root_path . 'includes/functions_admin.'.$phpEx);
$forum_auth_ary = array(
@@ -826,7 +826,7 @@ if( !empty($mode) )
if ($show_index != TRUE)
{
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
exit;
}
}
@@ -931,6 +931,6 @@ if( $total_categories = $db->sql_numrows($q_categories) )
$template->pparse("body");
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
?>

View File

@@ -33,9 +33,9 @@ if( !empty($setmodules) )
//
// Load default header
//
$phpbb_root_path = "../";
$phpbb_root_path = "./../";
require($phpbb_root_path . 'extension.inc');
require('pagestart.' . $phpEx);
require('./pagestart.' . $phpEx);
if( isset($HTTP_POST_VARS[POST_GROUPS_URL]) || isset($HTTP_GET_VARS[POST_GROUPS_URL]) )
{
@@ -354,6 +354,6 @@ else
$template->pparse('body');
}
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
?>

View File

@@ -33,9 +33,9 @@ if( !empty($setmodules) )
// Load default header
//
$no_page_header = TRUE;
$phpbb_root_path = '../';
$phpbb_root_path = "./../";
require($phpbb_root_path . 'extension.inc');
require('pagestart.' . $phpEx);
require('./pagestart.' . $phpEx);
//
// Increase maximum execution time in case of a lot of users, but don't complain about it if it isn't
@@ -174,7 +174,7 @@ $select_list .= '</select>';
//
// Generate page
//
include('page_header_admin.'.$phpEx);
include('./page_header_admin.'.$phpEx);
$template->set_filenames(array(
'body' => 'admin/user_email_body.tpl')
@@ -199,6 +199,6 @@ $template->assign_vars(array(
$template->pparse('body');
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
?>

View File

@@ -32,9 +32,9 @@ if( !empty($setmodules) )
//
// Let's set the root dir for phpBB
//
$phpbb_root_path = "../";
$phpbb_root_path = "./../";
require($phpbb_root_path . 'extension.inc');
require('pagestart.' . $phpEx);
require('./pagestart.' . $phpEx);
if( isset($HTTP_GET_VARS['mode']) || isset($HTTP_POST_VARS['mode']) )
{
@@ -360,6 +360,6 @@ else
$template->pparse("body");
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
?>

View File

@@ -47,9 +47,9 @@ if( isset($HTTP_GET_VARS['export_pack']) )
}
}
$phpbb_root_path = "../";
$phpbb_root_path = "./../";
require($phpbb_root_path . 'extension.inc');
require('pagestart.' . $phpEx);
require('./pagestart.' . $phpEx);
//
// Check to see what mode we should operate in.
@@ -536,6 +536,6 @@ else
//
// Page Footer
//
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
?>

View File

@@ -38,7 +38,7 @@ if( !empty($setmodules) )
//
// Check if the user has cancled a confirmation message.
//
$phpbb_root_path = "../";
$phpbb_root_path = "./../";
$confirm = ( isset($HTTP_POST_VARS['confirm']) ) ? TRUE : FALSE;
$cancel = ( isset($HTTP_POST_VARS['cancel']) ) ? TRUE : FALSE;
@@ -47,7 +47,7 @@ if( empty($HTTP_POST_VARS['send_file']) )
{
$no_page_header = ( $cancel ) ? TRUE : FALSE;
require($phpbb_root_path . 'extension.inc');
require('pagestart.' . $phpEx);
require('./pagestart.' . $phpEx);
}
if( $cancel )
@@ -932,7 +932,7 @@ switch( $mode )
if( !$HTTP_POST_VARS['send_file'] )
{
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
}
?>

View File

@@ -36,9 +36,9 @@ if( !empty($setmodules) )
//
$no_page_header = TRUE;
$phpbb_root_path = "../";
$phpbb_root_path = "./../";
require($phpbb_root_path . 'extension.inc');
require('pagestart.' . $phpEx);
require('./pagestart.' . $phpEx);
$params = array('mode' => 'mode', 'user_id' => POST_USERS_URL, 'group_id' => POST_GROUPS_URL, 'adv' => 'adv');
@@ -787,7 +787,9 @@ else if ( ( $mode == 'user' && ( isset($HTTP_POST_VARS['username']) || $user_id
$t_usergroup_list = '';
for($i = 0; $i < count($ug_info); $i++)
{
$t_usergroup_list .= ( ( $t_usergroup_list != '' ) ? ', ' : '' ) . '<a href="' . append_sid("admin_ug_auth.$phpEx?mode=$mode&amp;" . POST_GROUPS_URL . "=" . $id[$i]) . '">' . $name[$i] . '</a>';
$ug = ( $mode == 'user' ) ? 'group&amp;' . POST_GROUPS_URL : 'user&amp;' . POST_USERS_URL;
$t_usergroup_list .= ( ( $t_usergroup_list != '' ) ? ', ' : '' ) . '<a href="' . append_sid("admin_ug_auth.$phpEx?mode=$ug=" . $id[$i]) . '">' . $name[$i] . '</a>';
}
}
else
@@ -819,7 +821,7 @@ else if ( ( $mode == 'user' && ( isset($HTTP_POST_VARS['username']) || $user_id
//
// Dump in the page header ...
//
include('page_header_admin.'.$phpEx);
include('./page_header_admin.'.$phpEx);
$template->set_filenames(array(
"body" => 'admin/auth_ug_body.tpl')
@@ -878,7 +880,7 @@ else
//
// Select a user/group
//
include('page_header_admin.'.$phpEx);
include('./page_header_admin.'.$phpEx);
$template->set_filenames(array(
'body' => ( $mode == 'user' ) ? 'admin/user_select_body.tpl' : 'admin/auth_select_body.tpl')
@@ -936,6 +938,6 @@ else
$template->pparse('body');
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
?>
?>

View File

@@ -33,9 +33,9 @@ if( !empty($setmodules) )
//
// Load default header
//
$phpbb_root_path = "../";
$phpbb_root_path = "./../";
require($phpbb_root_path . 'extension.inc');
require('pagestart.' . $phpEx);
require('./pagestart.' . $phpEx);
//
// Start program
@@ -480,6 +480,6 @@ else
$template->pparse('body');
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
?>

View File

@@ -30,9 +30,9 @@ if( !empty($setmodules) )
return;
}
$phpbb_root_path = "../";
$phpbb_root_path = "./../";
require($phpbb_root_path . 'extension.inc');
require('pagestart.' . $phpEx);
require('./pagestart.' . $phpEx);
require($phpbb_root_path . 'includes/bbcode.'.$phpEx);
require($phpbb_root_path . 'includes/functions_post.'.$phpEx);
require($phpbb_root_path . 'includes/functions_selects.'.$phpEx);
@@ -1068,6 +1068,6 @@ else
}
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
?>

View File

@@ -32,9 +32,9 @@ if( !empty($setmodules) )
//
// Load default header
//
$phpbb_root_path = "../";
$phpbb_root_path = "./../";
require($phpbb_root_path . 'extension.inc');
require('pagestart.' . $phpEx);
require('./pagestart.' . $phpEx);
if( isset($HTTP_GET_VARS['mode']) || isset($HTTP_POST_VARS['mode']) )
{
@@ -109,7 +109,7 @@ if( $mode != "" )
$template->pparse("body");
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
}
else if( $mode == "save" )
{
@@ -230,6 +230,6 @@ else
$template->pparse("body");
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
?>

View File

@@ -26,9 +26,9 @@ define('IN_PHPBB', 1);
// Load default header
//
$no_page_header = TRUE;
$phpbb_root_path = "../";
$phpbb_root_path = "./../";
require($phpbb_root_path . 'extension.inc');
require('pagestart.' . $phpEx);
require('./pagestart.' . $phpEx);
// ---------------
// Begin functions
@@ -68,7 +68,7 @@ if( isset($HTTP_GET_VARS['pane']) && $HTTP_GET_VARS['pane'] == 'left' )
unset($setmodules);
include('page_header_admin.'.$phpEx);
include('./page_header_admin.'.$phpEx);
$template->set_filenames(array(
"body" => "admin/index_navigate.tpl")
@@ -116,12 +116,12 @@ if( isset($HTTP_GET_VARS['pane']) && $HTTP_GET_VARS['pane'] == 'left' )
$template->pparse("body");
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
}
elseif( isset($HTTP_GET_VARS['pane']) && $HTTP_GET_VARS['pane'] == 'right' )
{
include('page_header_admin.'.$phpEx);
include('./page_header_admin.'.$phpEx);
$template->set_filenames(array(
"body" => "admin/index_body.tpl")
@@ -561,7 +561,7 @@ elseif( isset($HTTP_GET_VARS['pane']) && $HTTP_GET_VARS['pane'] == 'right' )
$template->pparse("body");
include('page_footer_admin.'.$phpEx);
include('./page_footer_admin.'.$phpEx);
}
else

View File

@@ -74,7 +74,7 @@ $template->assign_vars(array(
'L_ADMIN' => $lang['Admin'],
'L_USERNAME' => $lang['Username'],
'L_PASSWORD' => $lang['Password'],
'L_INDEX' => $lang['Forum_Index'],
'L_INDEX' => sprintf($lang['Forum_Index'], $board_config['sitename']),
'L_REGISTER' => $lang['Register'],
'L_PROFILE' => $lang['Profile'],
'L_SEARCH' => $lang['Search'],

View File

@@ -50,7 +50,7 @@ if ( empty($no_page_header) )
{
// Not including the pageheader can be neccesarry if META tags are
// needed in the calling script.
include('page_header_admin.'.$phpEx);
include('./page_header_admin.'.$phpEx);
}
?>