diff options
Diffstat (limited to 'phpBB/includes/acp')
63 files changed, 65 insertions, 222 deletions
| diff --git a/phpBB/includes/acp/acp_attachments.php b/phpBB/includes/acp/acp_attachments.php index fc5f44e14f..3179be7de7 100644 --- a/phpBB/includes/acp/acp_attachments.php +++ b/phpBB/includes/acp/acp_attachments.php @@ -1235,6 +1235,7 @@ class acp_attachments  	function perform_site_list()  	{  		global $db, $user; +		global $request;  		if (isset($_REQUEST['securesubmit']))  		{ @@ -1243,7 +1244,7 @@ class acp_attachments  			$ip_list = array_unique(explode("\n", $ips));  			$ip_list_log = implode(', ', $ip_list); -			$ip_exclude = (!empty($_POST['ipexclude'])) ? 1 : 0; +			$ip_exclude = (int) $request->variable('ipexclude', false, false, phpbb_request_interface::POST);  			$iplist = array();  			$hostlist = array(); @@ -1455,5 +1456,3 @@ class acp_attachments  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_ban.php b/phpBB/includes/acp/acp_ban.php index a7ea57b753..00e68367fd 100644 --- a/phpBB/includes/acp/acp_ban.php +++ b/phpBB/includes/acp/acp_ban.php @@ -248,5 +248,3 @@ class acp_ban  		);  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_bbcodes.php b/phpBB/includes/acp/acp_bbcodes.php index 0644b38eb1..ecbaff6274 100644 --- a/phpBB/includes/acp/acp_bbcodes.php +++ b/phpBB/includes/acp/acp_bbcodes.php @@ -317,16 +317,7 @@ class acp_bbcodes  		$bbcode_tpl = trim($bbcode_tpl);  		$utf8 = strpos($bbcode_match, 'INTTEXT') !== false; -		// make sure we have utf8 support -		$utf8_pcre_properties = false; -		if (version_compare(PHP_VERSION, '5.1.0', '>=') || (version_compare(PHP_VERSION, '5.0.0-dev', '<=') && version_compare(PHP_VERSION, '4.4.0', '>='))) -		{ -			// While this is the proper range of PHP versions, PHP may not be linked with the bundled PCRE lib and instead with an older version -			if (@preg_match('/\p{L}/u', 'a') !== false) -			{ -				$utf8_pcre_properties = true; -			} -		} +		$utf8_pcre_properties = pcre_utf8_support();  		$fp_match = preg_quote($bbcode_match, '!');  		$fp_replace = preg_replace('#^\[(.*?)\]#', '[$1:$uid]', $bbcode_match); @@ -472,5 +463,3 @@ class acp_bbcodes  		);  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_board.php b/phpBB/includes/acp/acp_board.php index a5e80e1f6d..d77fbca7c2 100644 --- a/phpBB/includes/acp/acp_board.php +++ b/phpBB/includes/acp/acp_board.php @@ -351,6 +351,7 @@ class acp_board  					'vars'	=> array(  						'legend1'				=> 'ACP_SERVER_SETTINGS',  						'gzip_compress'			=> array('lang' => 'ENABLE_GZIP',		'validate' => 'bool',	'type' => 'radio:yes_no', 'explain' => true), +						'use_system_cron'		=> array('lang' => 'USE_SYSTEM_CRON',		'validate' => 'bool',	'type' => 'radio:yes_no', 'explain' => true),  						'legend2'				=> 'PATH_SETTINGS',  						'smilies_path'			=> array('lang' => 'SMILIES_PATH',		'validate' => 'rpath',	'type' => 'text:20:255', 'explain' => true), @@ -435,7 +436,7 @@ class acp_board  		$cfg_array = (isset($_REQUEST['config'])) ? utf8_normalize_nfc(request_var('config', array('' => ''), true)) : $this->new_config;  		$error = array(); -		// We validate the complete config if whished +		// We validate the complete config if wished  		validate_config_vars($display_vars['vars'], $cfg_array, $error);  		if ($submit && !check_form_key($form_key)) @@ -985,5 +986,3 @@ class acp_board  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_bots.php b/phpBB/includes/acp/acp_bots.php index d08cabb062..d253064e81 100644 --- a/phpBB/includes/acp/acp_bots.php +++ b/phpBB/includes/acp/acp_bots.php @@ -414,5 +414,3 @@ class acp_bots  		return ($row) ? false : true;  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_captcha.php b/phpBB/includes/acp/acp_captcha.php index 1893eed14f..8116fce6f0 100644 --- a/phpBB/includes/acp/acp_captcha.php +++ b/phpBB/includes/acp/acp_captcha.php @@ -144,5 +144,3 @@ class acp_captcha  		exit_handler();  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_database.php b/phpBB/includes/acp/acp_database.php index 193dd001c0..96542986d3 100644 --- a/phpBB/includes/acp/acp_database.php +++ b/phpBB/includes/acp/acp_database.php @@ -1007,43 +1007,8 @@ class sqlite_extractor extends base_extractor  	function write_data($table_name)  	{  		global $db; -		static $proper; -		if (is_null($proper)) -		{ -			$proper = version_compare(PHP_VERSION, '5.1.3', '>='); -		} - -		if ($proper) -		{ -			$col_types = sqlite_fetch_column_types($db->db_connect_id, $table_name); -		} -		else -		{ -			$sql = "SELECT sql -				FROM sqlite_master -				WHERE type = 'table' -					AND name = '" . $table_name . "'"; -			$table_data = sqlite_single_query($db->db_connect_id, $sql); -			$table_data = preg_replace('#CREATE\s+TABLE\s+"?' . $table_name . '"?#i', '', $table_data); -			$table_data = trim($table_data); - -			preg_match('#\((.*)\)#s', $table_data, $matches); - -			$table_cols = explode(',', trim($matches[1])); -			foreach ($table_cols as $declaration) -			{ -				$entities = preg_split('#\s+#', trim($declaration)); -				$column_name = preg_replace('/"?([^"]+)"?/', '\1', $entities[0]); - -				// Hit a primary key, those are not what we need :D -				if (empty($entities[1]) || (strtolower($entities[0]) === 'primary' && strtolower($entities[1]) === 'key')) -				{ -					continue; -				} -				$col_types[$column_name] = $entities[1]; -			} -		} +		$col_types = sqlite_fetch_column_types($db->db_connect_id, $table_name);  		$sql = "SELECT *  			FROM $table_name"; @@ -2455,5 +2420,3 @@ function fgetd_seekless(&$fp, $delim, $read, $seek, $eof, $buffer = 8192)  	return false;  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_disallow.php b/phpBB/includes/acp/acp_disallow.php index 9549955cc8..e3496bfc8b 100644 --- a/phpBB/includes/acp/acp_disallow.php +++ b/phpBB/includes/acp/acp_disallow.php @@ -104,5 +104,3 @@ class acp_disallow  		);  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_email.php b/phpBB/includes/acp/acp_email.php index 350693a630..b4f0e50029 100644 --- a/phpBB/includes/acp/acp_email.php +++ b/phpBB/includes/acp/acp_email.php @@ -258,5 +258,3 @@ class acp_email  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_forums.php b/phpBB/includes/acp/acp_forums.php index 4d9b9f01e0..4d605e1b82 100644 --- a/phpBB/includes/acp/acp_forums.php +++ b/phpBB/includes/acp/acp_forums.php @@ -1950,5 +1950,3 @@ class acp_forums  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_groups.php b/phpBB/includes/acp/acp_groups.php index 486616c33d..d47c12eafd 100644 --- a/phpBB/includes/acp/acp_groups.php +++ b/phpBB/includes/acp/acp_groups.php @@ -794,5 +794,3 @@ class acp_groups  		}  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_icons.php b/phpBB/includes/acp/acp_icons.php index 3d64a2acda..a525efb510 100644 --- a/phpBB/includes/acp/acp_icons.php +++ b/phpBB/includes/acp/acp_icons.php @@ -28,6 +28,7 @@ class acp_icons  	{  		global $db, $user, $auth, $template, $cache;  		global $config, $phpbb_root_path, $phpbb_admin_path, $phpEx; +		global $request;  		$user->add_lang('acp/posting'); @@ -338,7 +339,7 @@ class acp_icons  				$image_display_on_posting = (isset($_POST['display_on_posting'])) ? request_var('display_on_posting', array('' => 0)) : array();  				// Ok, add the relevant bits if we are adding new codes to existing emoticons... -				if (!empty($_POST['add_additional_code'])) +				if ($request->variable('add_additional_code', false, false, phpbb_request_interface::POST))  				{  					$add_image			= request_var('add_image', '');  					$add_code			= utf8_normalize_nfc(request_var('add_code', '', true)); @@ -354,7 +355,7 @@ class acp_icons  						$image_width[$add_image] = request_var('add_width', 0);  						$image_height[$add_image] = request_var('add_height', 0); -						if (!empty($_POST['add_display_on_posting'])) +						if ($request->variable('add_display_on_posting', false, false, phpbb_request_interface::POST))  						{  							$image_display_on_posting[$add_image] = 1;  						} @@ -950,5 +951,3 @@ class acp_icons  		return $item_count;  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_inactive.php b/phpBB/includes/acp/acp_inactive.php index 1a12c4967c..e4fb695a11 100644 --- a/phpBB/includes/acp/acp_inactive.php +++ b/phpBB/includes/acp/acp_inactive.php @@ -308,5 +308,3 @@ class acp_inactive  		$this->page_title = 'ACP_INACTIVE_USERS';  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_jabber.php b/phpBB/includes/acp/acp_jabber.php index 9925527b34..f010c5a5fa 100644 --- a/phpBB/includes/acp/acp_jabber.php +++ b/phpBB/includes/acp/acp_jabber.php @@ -127,5 +127,3 @@ class acp_jabber  		));  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_language.php b/phpBB/includes/acp/acp_language.php index 598b390302..8df8e5c8e5 100644 --- a/phpBB/includes/acp/acp_language.php +++ b/phpBB/includes/acp/acp_language.php @@ -34,6 +34,7 @@ class acp_language  		global $config, $db, $user, $auth, $template, $cache;  		global $phpbb_root_path, $phpbb_admin_path, $phpEx, $table_prefix;  		global $safe_mode, $file_uploads; +		global $request;  		include_once($phpbb_root_path . 'includes/functions_user.' . $phpEx); @@ -58,7 +59,7 @@ class acp_language  		if (isset($_POST['missing_file']))  		{  			$missing_file = request_var('missing_file', array('' => 0)); -			list($_REQUEST['language_file'], ) = array_keys($missing_file); +			$request->overwrite('language_file', array_shift(array_keys($missing_file)));  		}  		$selected_lang_file = request_var('language_file', '|common.' . $phpEx); @@ -68,6 +69,23 @@ class acp_language  		$this->language_directory = basename($this->language_directory);  		$this->language_file = basename($this->language_file); +		// detect language file type +		if ($this->language_directory == 'email') +		{ +			$language_file_type = 'email'; +			$request_default = ''; +		} +		else if (strpos($this->language_file, 'help_') === 0) +		{ +			$language_file_type = 'help'; +			$request_default = array(0 => array(0 => '')); +		} +		else +		{ +			$language_file_type = 'normal'; +			$request_default = array('' => ''); +		} +  		$user->add_lang('acp/language');  		$this->tpl_name = 'acp_language';  		$this->page_title = 'ACP_LANGUAGE_PACKS'; @@ -119,7 +137,7 @@ class acp_language  						'DATA'		=> $data,  						'NAME'		=> $user->lang[strtoupper($method . '_' . $data)],  						'EXPLAIN'	=> $user->lang[strtoupper($method . '_' . $data) . '_EXPLAIN'], -						'DEFAULT'	=> (!empty($_REQUEST[$data])) ? request_var($data, '') : $default +						'DEFAULT'	=> $request->variable($data, (string) $default),  					));  				} @@ -130,7 +148,7 @@ class acp_language  					'method'		=> $method)  				); -				$hidden_data .= build_hidden_fields(array('entry' => $_POST['entry']), true, STRIP); +				$hidden_data .= build_hidden_fields(array('entry' => $request->variable('entry', $request_default, true, phpbb_request_interface::POST)));  				$template->assign_vars(array(  					'S_UPLOAD'	=> true, @@ -187,12 +205,9 @@ class acp_language  					trigger_error($user->lang['FORM_INVALID']. adm_back_link($this->u_action), E_USER_WARNING);  				} -				if (!$lang_id || empty($_POST['entry'])) -				{ -					trigger_error($user->lang['NO_LANG_ID'] . adm_back_link($this->u_action), E_USER_WARNING); -				} +				$entry_value = $request->variable('entry', $request_default, true, phpbb_request_interface::POST); -				if ($this->language_directory != 'email' && !is_array($_POST['entry'])) +				if (!$lang_id || !$entry_value)  				{  					trigger_error($user->lang['NO_LANG_ID'] . adm_back_link($this->u_action), E_USER_WARNING);  				} @@ -291,10 +306,10 @@ class acp_language  					trigger_error(sprintf($user->lang['UNABLE_TO_WRITE_FILE'], $filename) . adm_back_link($this->u_action . '&id=' . $lang_id . '&action=details&language_file=' . urlencode($selected_lang_file)), E_USER_WARNING);  				} -				if ($this->language_directory == 'email') +				if ($language_file_type == 'email')  				{  					// Email Template -					$entry = $this->prepare_lang_entry($_POST['entry'], false); +					$entry = $this->prepare_lang_entry(htmlspecialchars_decode($entry_value), false);  					fwrite($fp, $entry);  				}  				else @@ -302,13 +317,13 @@ class acp_language  					$name = (($this->language_directory) ? $this->language_directory . '_' : '') . $this->language_file;  					$header = str_replace(array('{FILENAME}', '{LANG_NAME}', '{CHANGED}', '{AUTHOR}'), array($name, $row['lang_english_name'], date('Y-m-d', time()), $row['lang_author']), $this->language_file_header); -					if (strpos($this->language_file, 'help_') === 0) +					if ($language_file_type == 'help')  					{  						// Help File  						$header .= '$help = array(' . "\n";  						fwrite($fp, $header); -						foreach ($_POST['entry'] as $key => $value) +						foreach ($entry_value as $key => $value)  						{  							if (!is_array($value))  							{ @@ -319,7 +334,7 @@ class acp_language  							foreach ($value as $_key => $_value)  							{ -								$entry .= "\t\t" . (int) $_key . "\t=> '" . $this->prepare_lang_entry($_value) . "',\n"; +								$entry .= "\t\t" . (int) $_key . "\t=> '" . $this->prepare_lang_entry(htmlspecialchars_decode($_value)) . "',\n";  							}  							$entry .= "\t),\n"; @@ -329,15 +344,15 @@ class acp_language  						$footer = ");\n\n?>";  						fwrite($fp, $footer);  					} -					else +					else if ($language_file_type == 'normal')  					{  						// Language File  						$header .= $this->lang_header;  						fwrite($fp, $header); -						foreach ($_POST['entry'] as $key => $value) +						foreach ($entry_value as $key => $value)  						{ -							$entry = $this->format_lang_array($key, $value); +							$entry = $this->format_lang_array(htmlspecialchars_decode($key), htmlspecialchars_decode($value));  							fwrite($fp, $entry);  						} @@ -1454,5 +1469,3 @@ $lang = array_merge($lang, array(  		return $entry;  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_logs.php b/phpBB/includes/acp/acp_logs.php index 0f4f78fcdd..90c1a10649 100644 --- a/phpBB/includes/acp/acp_logs.php +++ b/phpBB/includes/acp/acp_logs.php @@ -27,6 +27,7 @@ class acp_logs  	{  		global $db, $user, $auth, $template, $cache;  		global $config, $phpbb_root_path, $phpbb_admin_path, $phpEx; +		global $request;  		$user->add_lang('mcp'); @@ -35,8 +36,8 @@ class acp_logs  		$forum_id	= request_var('f', 0);  		$topic_id	= request_var('t', 0);  		$start		= request_var('start', 0); -		$deletemark = (!empty($_POST['delmarked'])) ? true : false; -		$deleteall	= (!empty($_POST['delall'])) ? true : false; +		$deletemark = $request->variable('delmarked', false, false, phpbb_request_interface::POST); +		$deleteall	= $request->variable('delall', false, false, phpbb_request_interface::POST);  		$marked		= request_var('mark', array(0));  		// Sort keys @@ -172,5 +173,3 @@ class acp_logs  		}  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_main.php b/phpBB/includes/acp/acp_main.php index b8712b2a3d..a154aa5039 100644 --- a/phpBB/includes/acp/acp_main.php +++ b/phpBB/includes/acp/acp_main.php @@ -613,5 +613,3 @@ class acp_main  		$this->page_title = 'ACP_MAIN';  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_modules.php b/phpBB/includes/acp/acp_modules.php index 75bc5766a9..52033b590c 100644 --- a/phpBB/includes/acp/acp_modules.php +++ b/phpBB/includes/acp/acp_modules.php @@ -1061,5 +1061,3 @@ class acp_modules  		return $this->lang_name($target['module_langname']);  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_permission_roles.php b/phpBB/includes/acp/acp_permission_roles.php index 03ea5a39dd..3fe562b25d 100644 --- a/phpBB/includes/acp/acp_permission_roles.php +++ b/phpBB/includes/acp/acp_permission_roles.php @@ -567,5 +567,3 @@ class acp_permission_roles  		$auth_admin->acl_clear_prefetch();  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_permissions.php b/phpBB/includes/acp/acp_permissions.php index e9f0af5071..0708ed3e28 100644 --- a/phpBB/includes/acp/acp_permissions.php +++ b/phpBB/includes/acp/acp_permissions.php @@ -658,6 +658,7 @@ class acp_permissions  	function set_permissions($mode, $permission_type, &$auth_admin, &$user_id, &$group_id)  	{  		global $user, $auth; +		global $request;  		$psubmit = request_var('psubmit', array(0 => array(0 => 0))); @@ -676,18 +677,17 @@ class acp_permissions  		list($ug_id, ) = each($psubmit);  		list($forum_id, ) = each($psubmit[$ug_id]); -		if (empty($_POST['setting']) || empty($_POST['setting'][$ug_id]) || empty($_POST['setting'][$ug_id][$forum_id]) || !is_array($_POST['setting'][$ug_id][$forum_id])) +		$settings = $request->variable('setting', array(0 => array(0 => array('' => 0))), false, phpbb_request_interface::POST); +		if (empty($settings) || empty($settings[$ug_id]) || empty($settings[$ug_id][$forum_id]))  		{  			trigger_error('WRONG_PERMISSION_SETTING_FORMAT', E_USER_WARNING);  		} -		// We obtain and check $_POST['setting'][$ug_id][$forum_id] directly and not using request_var() because request_var() -		// currently does not support the amount of dimensions required. ;) -		//		$auth_settings = request_var('setting', array(0 => array(0 => array('' => 0)))); -		$auth_settings = array_map('intval', $_POST['setting'][$ug_id][$forum_id]); +		$auth_settings = $settings[$ug_id][$forum_id];  		// Do we have a role we want to set? -		$assigned_role = (isset($_POST['role'][$ug_id][$forum_id])) ? (int) $_POST['role'][$ug_id][$forum_id] : 0; +		$roles = $request->variable('role', array(0 => array(0 => 0)), false, phpbb_request_interface::POST); +		$assigned_role = (isset($roles[$ug_id][$forum_id])) ? (int) $roles[$ug_id][$forum_id] : 0;  		// Do the admin want to set these permissions to other items too?  		$inherit = request_var('inherit', array(0 => array(0))); @@ -747,6 +747,7 @@ class acp_permissions  	function set_all_permissions($mode, $permission_type, &$auth_admin, &$user_id, &$group_id)  	{  		global $user, $auth; +		global $request;  		// User or group to be set?  		$ug_type = (sizeof($user_id)) ? 'user' : 'group'; @@ -757,8 +758,8 @@ class acp_permissions  			trigger_error($user->lang['NO_AUTH_OPERATION'] . adm_back_link($this->u_action), E_USER_WARNING);  		} -		$auth_settings = (isset($_POST['setting'])) ? $_POST['setting'] : array(); -		$auth_roles = (isset($_POST['role'])) ? $_POST['role'] : array(); +		$auth_settings = $request->variable('setting', array(0 => array(0 => array('' => 0))), false, phpbb_request_interface::POST); +		$auth_roles = $request->variable('role', array(0 => array(0 => 0)), false, phpbb_request_interface::POST);  		$ug_ids = $forum_ids = array();  		// We need to go through the auth settings @@ -1311,5 +1312,3 @@ class acp_permissions  		);  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_php_info.php b/phpBB/includes/acp/acp_php_info.php index 0499095004..03561f3e30 100644 --- a/phpBB/includes/acp/acp_php_info.php +++ b/phpBB/includes/acp/acp_php_info.php @@ -80,5 +80,3 @@ class acp_php_info  		$template->assign_var('PHPINFO', $output);  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_profile.php b/phpBB/includes/acp/acp_profile.php index 2e43b0545a..ca6a5f04d2 100644 --- a/phpBB/includes/acp/acp_profile.php +++ b/phpBB/includes/acp/acp_profile.php @@ -30,6 +30,7 @@ class acp_profile  	{  		global $config, $db, $user, $auth, $template, $cache;  		global $phpbb_root_path, $phpbb_admin_path, $phpEx, $table_prefix; +		global $request;  		include($phpbb_root_path . 'includes/functions_posting.' . $phpEx);  		include($phpbb_root_path . 'includes/functions_user.' . $phpEx); @@ -487,7 +488,8 @@ class acp_profile  							$cp->vars['field_default_value_day'] = $now['mday'];  							$cp->vars['field_default_value_month'] = $now['mon'];  							$cp->vars['field_default_value_year'] = $now['year']; -							$var = $_POST['field_default_value'] = 'now'; +							$var = 'now'; +							$request->overwrite('field_default_value', $var, phpbb_request_interface::POST);  						}  						else  						{ @@ -496,7 +498,8 @@ class acp_profile  								$cp->vars['field_default_value_day'] = request_var('field_default_value_day', 0);  								$cp->vars['field_default_value_month'] = request_var('field_default_value_month', 0);  								$cp->vars['field_default_value_year'] = request_var('field_default_value_year', 0); -								$var = $_POST['field_default_value'] = sprintf('%2d-%2d-%4d', $cp->vars['field_default_value_day'], $cp->vars['field_default_value_month'], $cp->vars['field_default_value_year']); +								$var = sprintf('%2d-%2d-%4d', $cp->vars['field_default_value_day'], $cp->vars['field_default_value_month'], $cp->vars['field_default_value_year']); +								$request->overwrite('field_default_value', $var, phpbb_request_interface::POST);  							}  							else  							{ @@ -688,7 +691,7 @@ class acp_profile  							}  							else  							{ -								$_new_key_ary[$key] = (is_array($_REQUEST[$key])) ? utf8_normalize_nfc(request_var($key, array(''), true)) : utf8_normalize_nfc(request_var($key, '', true)); +								$_new_key_ary[$key] = ($field_type == FIELD_BOOL && $key == 'lang_options') ? utf8_normalize_nfc(request_var($key, array(''), true)) : utf8_normalize_nfc(request_var($key, '', true));  							}  						}  					} @@ -1622,5 +1625,3 @@ class acp_profile  		return $sql;  	}  } - -?> diff --git a/phpBB/includes/acp/acp_prune.php b/phpBB/includes/acp/acp_prune.php index ffe20f86f5..6120c15d68 100644 --- a/phpBB/includes/acp/acp_prune.php +++ b/phpBB/includes/acp/acp_prune.php @@ -462,5 +462,3 @@ class acp_prune  		$db->sql_freeresult($result);  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_ranks.php b/phpBB/includes/acp/acp_ranks.php index fcfef2a61e..5c05afbfad 100644 --- a/phpBB/includes/acp/acp_ranks.php +++ b/phpBB/includes/acp/acp_ranks.php @@ -236,5 +236,3 @@ class acp_ranks  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_reasons.php b/phpBB/includes/acp/acp_reasons.php index dbc9fcb6cc..799fcf4c3f 100644 --- a/phpBB/includes/acp/acp_reasons.php +++ b/phpBB/includes/acp/acp_reasons.php @@ -371,5 +371,3 @@ class acp_reasons  		$db->sql_freeresult($result);  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_search.php b/phpBB/includes/acp/acp_search.php index 930c8d2a26..27e636ddcc 100644 --- a/phpBB/includes/acp/acp_search.php +++ b/phpBB/includes/acp/acp_search.php @@ -232,15 +232,7 @@ class acp_search  		global $db, $user, $auth, $template, $cache;  		global $config, $phpbb_root_path, $phpbb_admin_path, $phpEx; -		if (isset($_REQUEST['action']) && is_array($_REQUEST['action'])) -		{ -			$action = request_var('action', array('' => false)); -			$action = key($action); -		} -		else -		{ -			$action = request_var('action', ''); -		} +		$action = request_var('action', '');  		$this->state = explode(',', $config['search_indexing_state']);  		if (isset($_POST['cancel'])) @@ -625,5 +617,3 @@ class acp_search  		return $error;  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_send_statistics.php b/phpBB/includes/acp/acp_send_statistics.php index b3baf54983..aef67a8b1a 100644 --- a/phpBB/includes/acp/acp_send_statistics.php +++ b/phpBB/includes/acp/acp_send_statistics.php @@ -86,5 +86,3 @@ class acp_send_statistics  		}  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_styles.php b/phpBB/includes/acp/acp_styles.php index 0f157ceff3..4f13ee376f 100644 --- a/phpBB/includes/acp/acp_styles.php +++ b/phpBB/includes/acp/acp_styles.php @@ -3946,5 +3946,3 @@ parse_css_file = {PARSE_CSS_FILE}  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_update.php b/phpBB/includes/acp/acp_update.php index b0ce8f1084..41fb0884b7 100644 --- a/phpBB/includes/acp/acp_update.php +++ b/phpBB/includes/acp/acp_update.php @@ -89,5 +89,3 @@ class acp_update  		));  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_users.php b/phpBB/includes/acp/acp_users.php index 6be0760be0..006c3617f7 100644 --- a/phpBB/includes/acp/acp_users.php +++ b/phpBB/includes/acp/acp_users.php @@ -56,7 +56,7 @@ class acp_users  			$this->page_title = 'WHOIS';  			$this->tpl_name = 'simple_body'; -			$user_ip = request_var('user_ip', ''); +			$user_ip = phpbb_ip_normalise(request_var('user_ip', ''));  			$domain = gethostbyaddr($user_ip);  			$ipwhois = user_ipwhois($user_ip); @@ -921,7 +921,7 @@ class acp_users  					}  					// Replace "error" strings with their real, localised form -					$error = preg_replace('#^([A-Z_]+)$#e', "(!empty(\$user->lang['\\1'])) ? \$user->lang['\\1'] : '\\1'", $error); +					$error = array_map(array($user, 'lang'), $error);  				}  				if ($user_id == $user->data['user_id']) @@ -1405,7 +1405,7 @@ class acp_users  					}  					// Replace "error" strings with their real, localised form -					$error = preg_replace('#^([A-Z_]+)$#e', "(!empty(\$user->lang['\\1'])) ? \$user->lang['\\1'] : '\\1'", $error); +					$error = array_map(array($user, 'lang'), $error);  				}  				$s_birthday_day_options = '<option value="0"' . ((!$data['bday_day']) ? ' selected="selected"' : '') . '>--</option>'; @@ -1588,7 +1588,7 @@ class acp_users  					}  					// Replace "error" strings with their real, localised form -					$error = preg_replace('#^([A-Z_]+)$#e', "(!empty(\$user->lang['\\1'])) ? \$user->lang['\\1'] : '\\1'", $error); +					$error = array_map(array($user, 'lang'), $error);  				}  				$dateformat_options = ''; @@ -1714,7 +1714,7 @@ class acp_users  					}  					// Replace "error" strings with their real, localised form -					$error = preg_replace('#^([A-Z_]+)$#e', "(!empty(\$user->lang['\\1'])) ? \$user->lang['\\1'] : '\\1'", $error); +					$error = array_map(array($user, 'lang'), $error);  				}  				if (!$config['allow_avatar'] && $user_row['user_avatar_type']) @@ -1857,7 +1857,7 @@ class acp_users  					}  					// Replace "error" strings with their real, localised form -					$error = preg_replace('#^([A-Z_]+)$#e', "(!empty(\$user->lang['\\1'])) ? \$user->lang['\\1'] : '\\1'", $error); +					$error = array_map(array($user, 'lang'), $error);  				}  				$signature_preview = ''; @@ -2388,5 +2388,3 @@ class acp_users  		return ($var & 1 << $user->keyoptions[$key]) ? true : false;  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/acp_words.php b/phpBB/includes/acp/acp_words.php index 88c5bbe592..450a2fad4c 100644 --- a/phpBB/includes/acp/acp_words.php +++ b/phpBB/includes/acp/acp_words.php @@ -186,5 +186,3 @@ class acp_words  		$db->sql_freeresult($result);  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/auth.php b/phpBB/includes/acp/auth.php index 10d7973da6..e0e07e51eb 100644 --- a/phpBB/includes/acp/auth.php +++ b/phpBB/includes/acp/auth.php @@ -1281,5 +1281,3 @@ class auth_admin extends auth  		return true;  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_attachments.php b/phpBB/includes/acp/info/acp_attachments.php index b77785801f..d5f57ece4e 100644 --- a/phpBB/includes/acp/info/acp_attachments.php +++ b/phpBB/includes/acp/info/acp_attachments.php @@ -36,5 +36,3 @@ class acp_attachments_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_ban.php b/phpBB/includes/acp/info/acp_ban.php index df51011ec6..7db7cf1371 100644 --- a/phpBB/includes/acp/info/acp_ban.php +++ b/phpBB/includes/acp/info/acp_ban.php @@ -35,5 +35,3 @@ class acp_ban_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_bbcodes.php b/phpBB/includes/acp/info/acp_bbcodes.php index c0206432d6..f5a3cfe10f 100644 --- a/phpBB/includes/acp/info/acp_bbcodes.php +++ b/phpBB/includes/acp/info/acp_bbcodes.php @@ -33,5 +33,3 @@ class acp_bbcodes_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_board.php b/phpBB/includes/acp/info/acp_board.php index 3e18f55940..5f73241012 100644 --- a/phpBB/includes/acp/info/acp_board.php +++ b/phpBB/includes/acp/info/acp_board.php @@ -48,5 +48,3 @@ class acp_board_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_bots.php b/phpBB/includes/acp/info/acp_bots.php index 45087f9225..6dce4b352b 100644 --- a/phpBB/includes/acp/info/acp_bots.php +++ b/phpBB/includes/acp/info/acp_bots.php @@ -33,6 +33,3 @@ class acp_bots_info  	{  	}  } - - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_captcha.php b/phpBB/includes/acp/info/acp_captcha.php index b2541c252c..cfeef20e34 100644 --- a/phpBB/includes/acp/info/acp_captcha.php +++ b/phpBB/includes/acp/info/acp_captcha.php @@ -34,5 +34,3 @@ class acp_captcha_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_database.php b/phpBB/includes/acp/info/acp_database.php index 85c3c8b21c..7d57dd4974 100644 --- a/phpBB/includes/acp/info/acp_database.php +++ b/phpBB/includes/acp/info/acp_database.php @@ -34,5 +34,3 @@ class acp_database_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_disallow.php b/phpBB/includes/acp/info/acp_disallow.php index 41315eb716..93ec5633a6 100644 --- a/phpBB/includes/acp/info/acp_disallow.php +++ b/phpBB/includes/acp/info/acp_disallow.php @@ -33,6 +33,3 @@ class acp_disallow_info  	{  	}  } - - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_email.php b/phpBB/includes/acp/info/acp_email.php index 4ad7bca58b..eb16ba05f1 100644 --- a/phpBB/includes/acp/info/acp_email.php +++ b/phpBB/includes/acp/info/acp_email.php @@ -33,6 +33,3 @@ class acp_email_info  	{  	}  } - - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_forums.php b/phpBB/includes/acp/info/acp_forums.php index 8d82eaf42d..7d4b04d384 100644 --- a/phpBB/includes/acp/info/acp_forums.php +++ b/phpBB/includes/acp/info/acp_forums.php @@ -33,5 +33,3 @@ class acp_forums_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_groups.php b/phpBB/includes/acp/info/acp_groups.php index 3910c24e6b..bbf92d670e 100644 --- a/phpBB/includes/acp/info/acp_groups.php +++ b/phpBB/includes/acp/info/acp_groups.php @@ -33,5 +33,3 @@ class acp_groups_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_icons.php b/phpBB/includes/acp/info/acp_icons.php index 16bf753940..e4939aad2a 100644 --- a/phpBB/includes/acp/info/acp_icons.php +++ b/phpBB/includes/acp/info/acp_icons.php @@ -34,5 +34,3 @@ class acp_icons_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_inactive.php b/phpBB/includes/acp/info/acp_inactive.php index e17fbda9dd..1453c51c50 100644 --- a/phpBB/includes/acp/info/acp_inactive.php +++ b/phpBB/includes/acp/info/acp_inactive.php @@ -33,5 +33,3 @@ class acp_inactive_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_jabber.php b/phpBB/includes/acp/info/acp_jabber.php index 7bcf7744e1..2259b78e19 100644 --- a/phpBB/includes/acp/info/acp_jabber.php +++ b/phpBB/includes/acp/info/acp_jabber.php @@ -33,4 +33,3 @@ class acp_jabber_info  	{  	}  } -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_language.php b/phpBB/includes/acp/info/acp_language.php index f7606631fe..40eadd0abf 100644 --- a/phpBB/includes/acp/info/acp_language.php +++ b/phpBB/includes/acp/info/acp_language.php @@ -33,5 +33,3 @@ class acp_language_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_logs.php b/phpBB/includes/acp/info/acp_logs.php index f119e10b83..a28ff57bf3 100644 --- a/phpBB/includes/acp/info/acp_logs.php +++ b/phpBB/includes/acp/info/acp_logs.php @@ -36,5 +36,3 @@ class acp_logs_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_main.php b/phpBB/includes/acp/info/acp_main.php index 5574cc40d1..2e9969d2be 100644 --- a/phpBB/includes/acp/info/acp_main.php +++ b/phpBB/includes/acp/info/acp_main.php @@ -33,5 +33,3 @@ class acp_main_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_modules.php b/phpBB/includes/acp/info/acp_modules.php index 886f17d628..6cda51ed9c 100644 --- a/phpBB/includes/acp/info/acp_modules.php +++ b/phpBB/includes/acp/info/acp_modules.php @@ -35,5 +35,3 @@ class acp_modules_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_permission_roles.php b/phpBB/includes/acp/info/acp_permission_roles.php index 3ab2fecd53..47496e3859 100644 --- a/phpBB/includes/acp/info/acp_permission_roles.php +++ b/phpBB/includes/acp/info/acp_permission_roles.php @@ -36,5 +36,3 @@ class acp_permission_roles_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_permissions.php b/phpBB/includes/acp/info/acp_permissions.php index 6f341742f3..59d1b449f0 100644 --- a/phpBB/includes/acp/info/acp_permissions.php +++ b/phpBB/includes/acp/info/acp_permissions.php @@ -50,5 +50,3 @@ class acp_permissions_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_php_info.php b/phpBB/includes/acp/info/acp_php_info.php index 7d716b0f83..a131581750 100644 --- a/phpBB/includes/acp/info/acp_php_info.php +++ b/phpBB/includes/acp/info/acp_php_info.php @@ -33,5 +33,3 @@ class acp_php_info_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_profile.php b/phpBB/includes/acp/info/acp_profile.php index 8590226038..9575477333 100644 --- a/phpBB/includes/acp/info/acp_profile.php +++ b/phpBB/includes/acp/info/acp_profile.php @@ -33,5 +33,3 @@ class acp_profile_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_prune.php b/phpBB/includes/acp/info/acp_prune.php index 46565c4f16..c688776380 100644 --- a/phpBB/includes/acp/info/acp_prune.php +++ b/phpBB/includes/acp/info/acp_prune.php @@ -34,5 +34,3 @@ class acp_prune_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_ranks.php b/phpBB/includes/acp/info/acp_ranks.php index 06b9c6d284..12afeb041b 100644 --- a/phpBB/includes/acp/info/acp_ranks.php +++ b/phpBB/includes/acp/info/acp_ranks.php @@ -33,5 +33,3 @@ class acp_ranks_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_reasons.php b/phpBB/includes/acp/info/acp_reasons.php index 65d805ee18..5bc1310088 100644 --- a/phpBB/includes/acp/info/acp_reasons.php +++ b/phpBB/includes/acp/info/acp_reasons.php @@ -33,5 +33,3 @@ class acp_reasons_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_search.php b/phpBB/includes/acp/info/acp_search.php index 4afd6c6994..979d84e63a 100644 --- a/phpBB/includes/acp/info/acp_search.php +++ b/phpBB/includes/acp/info/acp_search.php @@ -34,5 +34,3 @@ class acp_search_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_send_statistics.php b/phpBB/includes/acp/info/acp_send_statistics.php index de5dcdb8ad..93efa99b6d 100644 --- a/phpBB/includes/acp/info/acp_send_statistics.php +++ b/phpBB/includes/acp/info/acp_send_statistics.php @@ -33,5 +33,3 @@ class acp_send_statistics_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_styles.php b/phpBB/includes/acp/info/acp_styles.php index db67167e39..d6afd53cef 100644 --- a/phpBB/includes/acp/info/acp_styles.php +++ b/phpBB/includes/acp/info/acp_styles.php @@ -36,5 +36,3 @@ class acp_styles_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_update.php b/phpBB/includes/acp/info/acp_update.php index 886cdc94d5..8ecb062d4e 100644 --- a/phpBB/includes/acp/info/acp_update.php +++ b/phpBB/includes/acp/info/acp_update.php @@ -33,5 +33,3 @@ class acp_update_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_users.php b/phpBB/includes/acp/info/acp_users.php index 10081ac870..a63480d0f0 100644 --- a/phpBB/includes/acp/info/acp_users.php +++ b/phpBB/includes/acp/info/acp_users.php @@ -43,5 +43,3 @@ class acp_users_info  	{  	}  } - -?>
\ No newline at end of file diff --git a/phpBB/includes/acp/info/acp_words.php b/phpBB/includes/acp/info/acp_words.php index a2417f8a7f..4a2ddfea7f 100644 --- a/phpBB/includes/acp/info/acp_words.php +++ b/phpBB/includes/acp/info/acp_words.php @@ -33,5 +33,3 @@ class acp_words_info  	{  	}  } - -?>
\ No newline at end of file | 
