Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/phpmyadmin/phpmyadmin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--import.php44
-rw-r--r--tbl_replace.php3
-rw-r--r--tbl_tracking.php5
-rw-r--r--user_password.php20
-rw-r--r--view_operations.php4
5 files changed, 52 insertions, 24 deletions
diff --git a/import.php b/import.php
index 564de1d524..585ebb4cc3 100644
--- a/import.php
+++ b/import.php
@@ -92,9 +92,7 @@ if (! empty($sql_query)) {
;
if ($_POST == array() && $_GET == array()) {
$message = PMA_Message::error(
- __('You probably tried to upload a file that is too large.'
- . ' Please refer to %sdocumentation%s for a workaround for this limit.'
- )
+ __('You probably tried to upload a file that is too large. Please refer to %sdocumentation%s for a workaround for this limit.')
);
$message->addParam('[doc@faq1_16]');
$message->addParam('[/doc]');
@@ -351,7 +349,9 @@ if ($import_file != 'none' && ! $error) {
if ($cfg['BZipDump'] && @function_exists('bzopen')) {
$import_handle = @bzopen($import_file, 'r');
} else {
- $message = PMA_Message::error(__('You attempted to load file with unsupported compression (%s). Either support for it is not implemented or disabled by your configuration.'));
+ $message = PMA_Message::error(
+ __('You attempted to load file with unsupported compression (%s). Either support for it is not implemented or disabled by your configuration.')
+ );
$message->addParam($compression);
$error = true;
}
@@ -360,7 +360,9 @@ if ($import_file != 'none' && ! $error) {
if ($cfg['GZipDump'] && @function_exists('gzopen')) {
$import_handle = @gzopen($import_file, 'r');
} else {
- $message = PMA_Message::error(__('You attempted to load file with unsupported compression (%s). Either support for it is not implemented or disabled by your configuration.'));
+ $message = PMA_Message::error(
+ __('You attempted to load file with unsupported compression (%s). Either support for it is not implemented or disabled by your configuration.')
+ );
$message->addParam($compression);
$error = true;
}
@@ -379,7 +381,9 @@ if ($import_file != 'none' && ! $error) {
$import_text = $result['data'];
}
} else {
- $message = PMA_Message::error(__('You attempted to load file with unsupported compression (%s). Either support for it is not implemented or disabled by your configuration.'));
+ $message = PMA_Message::error(
+ __('You attempted to load file with unsupported compression (%s). Either support for it is not implemented or disabled by your configuration.')
+ );
$message->addParam($compression);
$error = true;
}
@@ -388,7 +392,9 @@ if ($import_file != 'none' && ! $error) {
$import_handle = @fopen($import_file, 'r');
break;
default:
- $message = PMA_Message::error(__('You attempted to load file with unsupported compression (%s). Either support for it is not implemented or disabled by your configuration.'));
+ $message = PMA_Message::error(
+ __('You attempted to load file with unsupported compression (%s). Either support for it is not implemented or disabled by your configuration.')
+ );
$message->addParam($compression);
$error = true;
break;
@@ -401,7 +407,9 @@ if ($import_file != 'none' && ! $error) {
}
} elseif (! $error) {
if (! isset($import_text) || empty($import_text)) {
- $message = PMA_Message::error(__('No data was received to import. Either no file name was submitted, or the file size exceeded the maximum size permitted by your PHP configuration. See [doc@faq1_16]FAQ 1.16[/doc].'));
+ $message = PMA_Message::error(
+ __('No data was received to import. Either no file name was submitted, or the file size exceeded the maximum size permitted by your PHP configuration. See [doc@faq1_16]FAQ 1.16[/doc].')
+ );
$error = true;
}
}
@@ -419,7 +427,9 @@ if ($GLOBALS['PMA_recoding_engine'] != PMA_CHARSET_NONE && isset($charset_of_fil
// Drizzle doesn't support other character sets,
// so we can't fallback to SET NAMES - throw an error
$error = true;
- $message = PMA_Message::error(__('Cannot convert file\'s character set without character set conversion library'));
+ $message = PMA_Message::error(
+ __('Cannot convert file\'s character set without character set conversion library')
+ );
} else {
PMA_DBI_query('SET NAMES \'' . $charset_of_file . '\'');
// We can not show query in this case, it is in different charset
@@ -497,13 +507,17 @@ if (! empty($id_bookmark) && $action_bookmark == 2) {
$message = PMA_Message::success();
} else {
if ($import_notice) {
- $message = PMA_Message::success('<em>'.__('Import has been successfully finished, %d queries executed.').'</em>');
+ $message = PMA_Message::success(
+ '<em>' . __('Import has been successfully finished, %d queries executed.') . '</em>'
+ );
$message->addParam($executed_queries);
$message->addString($import_notice);
$message->addString('(' . $_FILES['import_file']['name'] . ')');
} else {
- $message = PMA_Message::success(__('Import has been successfully finished, %d queries executed.'));
+ $message = PMA_Message::success(
+ __('Import has been successfully finished, %d queries executed.')
+ );
$message->addParam($executed_queries);
$message->addString('(' . $_FILES['import_file']['name'] . ')');
}
@@ -512,9 +526,13 @@ if (! empty($id_bookmark) && $action_bookmark == 2) {
// Did we hit timeout? Tell it user.
if ($timeout_passed) {
- $message = PMA_Message::error(__('Script timeout passed, if you want to finish import, please resubmit same file and import will resume.'));
+ $message = PMA_Message::error(
+ __('Script timeout passed, if you want to finish import, please resubmit same file and import will resume.')
+ );
if ($offset == 0 || (isset($original_skip) && $original_skip == $offset)) {
- $message->addString(__('However on last run no data has been parsed, this usually means phpMyAdmin won\'t be able to finish this import unless you increase php time limits.'));
+ $message->addString(
+ __('However on last run no data has been parsed, this usually means phpMyAdmin won\'t be able to finish this import unless you increase php time limits.')
+ );
}
}
diff --git a/tbl_replace.php b/tbl_replace.php
index 47ffaa9ff4..556de7237f 100644
--- a/tbl_replace.php
+++ b/tbl_replace.php
@@ -44,8 +44,9 @@ $scripts->addFile('sql.js');
// check whether insert row moode, if so include tbl_change.php
PMA_isInsertRow();
+$after_insert_actions = array('new_insert', 'same_insert', 'edit_next');
if (isset($_REQUEST['after_insert'])
- && in_array($_REQUEST['after_insert'], array('new_insert', 'same_insert', 'edit_next'))
+ && in_array($_REQUEST['after_insert'], $after_insert_actions)
) {
$url_params['after_insert'] = $_REQUEST['after_insert'];
if (isset($_REQUEST['where_clause'])) {
diff --git a/tbl_tracking.php b/tbl_tracking.php
index 519a474b33..634b2dce7b 100644
--- a/tbl_tracking.php
+++ b/tbl_tracking.php
@@ -62,8 +62,9 @@ if (isset($_REQUEST['report_export'])) {
*
* @return array filtered entries
*/
- function PMA_filter_tracking($data, $filter_ts_from, $filter_ts_to, $filter_users)
- {
+ function PMA_filter_tracking(
+ $data, $filter_ts_from, $filter_ts_to, $filter_users
+ ) {
$tmp_entries = array();
$id = 0;
foreach ( $data as $entry ) {
diff --git a/user_password.php b/user_password.php
index 71d2864c3b..8eb9946e5a 100644
--- a/user_password.php
+++ b/user_password.php
@@ -130,8 +130,11 @@ function PMA_changePassword($password, $message, $change_password_message)
// Defines the url to return to in case of error in the sql statement
$_url_params = array();
$hashing_function = PMA_changePassHashingFunction();
- $sql_query = 'SET password = ' . (($password == '') ? '\'\'' : $hashing_function . '(\'***\')');
- PMA_ChangePassUrlParamsAndSubmitQuery($password, $_url_params, $sql_query, $hashing_function);
+ $sql_query = 'SET password = '
+ . (($password == '') ? '\'\'' : $hashing_function . '(\'***\')');
+ PMA_ChangePassUrlParamsAndSubmitQuery(
+ $password, $_url_params, $sql_query, $hashing_function
+ );
$new_url_params = PMA_changePassAuthType($_url_params, $password);
PMA_getChangePassMessage($change_password_message, $sql_query);
@@ -163,15 +166,18 @@ function PMA_changePassHashingFunction()
*
* @return void
*/
-function PMA_ChangePassUrlParamsAndSubmitQuery($password, $_url_params, $sql_query, $hashing_function)
-{
+function PMA_ChangePassUrlParamsAndSubmitQuery(
+ $password, $_url_params, $sql_query, $hashing_function
+) {
$common_functions = PMA_CommonFunctions::getInstance();
$err_url = 'user_password.php' . PMA_generate_common_url($_url_params);
$local_query = 'SET password = ' . (($password == '')
? '\'\''
: $hashing_function . '(\'' . $common_functions->sqlAddSlashes($password) . '\')');
$result = @PMA_DBI_try_query($local_query)
- or $common_functions->mysqlDie(PMA_DBI_getError(), $sql_query, false, $err_url);
+ or $common_functions->mysqlDie(
+ PMA_DBI_getError(), $sql_query, false, $err_url
+ );
}
/**
@@ -189,12 +195,12 @@ function PMA_changePassAuthType($_url_params, $password)
* Duration = till the browser is closed for password
* (we don't want this to be saved)
*/
-
+
// include_once "libraries/plugins/auth/AuthenticationCookie.class.php";
// $auth_plugin = new AuthenticationCookie();
// the $auth_plugin is already defined in common.inc.php when this is used
global $auth_plugin;
-
+
if ($GLOBALS['cfg']['Server']['auth_type'] == 'cookie') {
$GLOBALS['PMA_Config']->setCookie(
'pmaPass-' . $GLOBALS['server'],
diff --git a/view_operations.php b/view_operations.php
index 116af4931f..db80bc28c1 100644
--- a/view_operations.php
+++ b/view_operations.php
@@ -52,7 +52,9 @@ if (isset($result)) {
// (for example, a table rename)
$_type = 'success';
if (empty($_message)) {
- $_message = $result ? __('Your SQL query has been executed successfully') : __('Error');
+ $_message = $result
+ ? __('Your SQL query has been executed successfully')
+ : __('Error');
// $result should exist, regardless of $_message
$_type = $result ? 'success' : 'error';
}