The branch, master has been updated
via e67a0a2531fff325477c5babcfffbf205ca755b3 (commit)
from ac088aaee0194f28f435b63b978db96426cda642 (commit)
- Log -----------------------------------------------------------------
commit e67a0a2531fff325477c5babcfffbf205ca755b3
Author: Madhura Jayaratne <madhura.cj(a)gmail.com>
Date: Fri Sep 23 08:43:41 2011 +0530
Spaces between parameters in function calls
-----------------------------------------------------------------------
Summary of changes:
db_operations.php | 2 +-
export.php | 2 +-
libraries/List_Database.class.php | 4 +-
libraries/auth/swekey/swekey.php | 40 ++++++++++----------
libraries/header_scripts.inc.php | 2 +-
libraries/import.lib.php | 2 +-
libraries/mult_submits.inc.php | 4 +-
libraries/replication.inc.php | 2 +-
libraries/select_lang.lib.php | 4 +-
libraries/server_synchronize.lib.php | 8 ++--
libraries/svg_plot/pma_scatter_plot.php | 12 +++---
libraries/svg_plot/pma_svg_data_point.php | 8 ++--
libraries/sysinfo.lib.php | 4 +-
navigation.php | 2 +-
pmd_general.php | 18 ++++----
pmd_pdf.php | 4 +-
pmd_relation_new.php | 8 ++--
pmd_relation_upd.php | 6 +-
schema_export.php | 4 +-
server_synchronize.php | 8 ++--
server_variables.php | 14 +++---
sql.php | 6 +-
tbl_addfield.php | 2 +-
tbl_export.php | 2 +-
tbl_operations.php | 2 +-
tbl_replace.php | 2 +-
tbl_select.php | 4 +-
tbl_structure.php | 2 +-
tbl_tracking.php | 4 +-
test/Environment_test.php | 2 +-
test/classes/PMA_Config_test.php | 32 ++++++++--------
.../PMA_contains_nonprintable_ascii_test.php | 4 +-
.../common/PMA_display_html_checkbox_test.php | 8 ++--
.../common/PMA_display_html_radio_test.php | 16 ++++----
.../PMA_extractValueFromFormattedSize_test.php | 8 ++--
test/libraries/common/PMA_formatSql_test.php | 28 +++++++-------
.../common/PMA_generate_html_dropdown_test.php | 6 +-
.../common/PMA_generate_slider_effect_test.php | 6 +-
test/libraries/common/PMA_getDbLink_test.php | 6 +-
.../common/PMA_getTitleForTarget_test.php | 2 +-
test/libraries/core/PMA_array_test.php | 12 +++---
test/libraries/core/PMA_checkPageValidity_test.php | 10 ++--
test/libraries/core/PMA_getTableCount_test_dis.php | 2 +-
.../core/PMA_headerLocation_test_disabled.php | 8 ++--
.../core/PMA_warnMissingExtension_test.php | 10 ++--
45 files changed, 171 insertions(+), 171 deletions(-)
diff --git a/db_operations.php b/db_operations.php
index 512c894..b364d81 100644
--- a/db_operations.php
+++ b/db_operations.php
@@ -234,7 +234,7 @@ if (strlen($db) && (! empty($db_rename) || ! empty($db_copy))) {
// to avoid selecting alternatively the current and new db
// we would need to modify the CREATE definitions to qualify
// the db name
- $event_names = PMA_DBI_fetch_result('SELECT EVENT_NAME FROM information_schema.EVENTS WHERE EVENT_SCHEMA= \'' . PMA_sqlAddSlashes($db,true) . '\';');
+ $event_names = PMA_DBI_fetch_result('SELECT EVENT_NAME FROM information_schema.EVENTS WHERE EVENT_SCHEMA= \'' . PMA_sqlAddSlashes($db, true) . '\';');
if ($event_names) {
foreach ($event_names as $event_name) {
PMA_DBI_select_db($db);
diff --git a/export.php b/export.php
index b82ef99..0c8a644 100644
--- a/export.php
+++ b/export.php
@@ -342,7 +342,7 @@ if (!$save_on_server) {
// Download
// (avoid rewriting data containing HTML with anchors and forms;
// this was reported to happen under Plesk)
- @ini_set('url_rewriter.tags','');
+ @ini_set('url_rewriter.tags', '');
$filename = PMA_sanitize_filename($filename);
PMA_download_header($filename, $mime_type);
diff --git a/libraries/List_Database.class.php b/libraries/List_Database.class.php
index 1e1b31f..760d19d 100644
--- a/libraries/List_Database.class.php
+++ b/libraries/List_Database.class.php
@@ -453,10 +453,10 @@ require_once './libraries/List.class.php';
// TODO: db names may contain characters
// that are regexp instructions
$re = '(^|(\\\\\\\\)+|[^\])';
- $tmp_regex = preg_replace('/' . addcslashes($re,'/') . '%/', '\\1.*', preg_replace('/' . addcslashes($re,'/') . '_/', '\\1.{1}', $tmp_matchpattern));
+ $tmp_regex = preg_replace('/' . addcslashes($re, '/') . '%/', '\\1.*', preg_replace('/' . addcslashes($re,'/') . '_/', '\\1.{1}', $tmp_matchpattern));
// Fixed db name matching
// 2000-08-28 -- Benjamin Gandon
- if (preg_match('/^' . addcslashes($tmp_regex,'/') . '$/', $tmp_db)) {
+ if (preg_match('/^' . addcslashes($tmp_regex, '/') . '$/', $tmp_db)) {
$dblist[] = $tmp_db;
break;
}
diff --git a/libraries/auth/swekey/swekey.php b/libraries/auth/swekey/swekey.php
index 869d3d5..453437e 100644
--- a/libraries/auth/swekey/swekey.php
+++ b/libraries/auth/swekey/swekey.php
@@ -18,18 +18,18 @@
/**
* Errors codes
*/
-define ("SWEKEY_ERR_INVALID_DEV_STATUS",901); // The satus of the device is not SWEKEY_STATUS_OK
-define ("SWEKEY_ERR_INTERNAL",902); // Should never occurd
-define ("SWEKEY_ERR_OUTDATED_RND_TOKEN",910); // You random token is too old
-define ("SWEKEY_ERR_INVALID_OTP",911); // The otp was not correct
+define ("SWEKEY_ERR_INVALID_DEV_STATUS", 901); // The satus of the device is not SWEKEY_STATUS_OK
+define ("SWEKEY_ERR_INTERNAL", 902); // Should never occurd
+define ("SWEKEY_ERR_OUTDATED_RND_TOKEN", 910); // You random token is too old
+define ("SWEKEY_ERR_INVALID_OTP", 911); // The otp was not correct
/**
* Those errors are considered as an attack and your site will be blacklisted during one minute
* if you receive one of those errors
*/
-define ("SWEKEY_ERR_BADLY_ENCODED_REQUEST",920);
-define ("SWEKEY_ERR_INVALID_RND_TOKEN",921);
-define ("SWEKEY_ERR_DEV_NOT_FOUND",922);
+define ("SWEKEY_ERR_BADLY_ENCODED_REQUEST", 920);
+define ("SWEKEY_ERR_INVALID_RND_TOKEN", 921);
+define ("SWEKEY_ERR_DEV_NOT_FOUND", 922);
/**
* Default values for configuration.
@@ -252,7 +252,7 @@ function Swekey_HttpGet($url, &$response_code)
$r = new HttpRequest($url);
$options = array('timeout' => '3');
- if (substr($url,0, 6) == "https:")
+ if (substr($url, 0, 6) == "https:")
{
$sslOptions = array();
$sslOptions['verifypeer'] = true;
@@ -392,7 +392,7 @@ function Swekey_GetFastHalfRndToken()
{
// we unlink the file so no possible tempfile race attack
unlink($cachefile);
- $file = fopen($cachefile , "x");
+ $file = fopen($cachefile, "x");
if ($file != false)
{
@fwrite($file, $res);
@@ -442,22 +442,22 @@ function Swekey_CheckOtp($id, $rt, $otp)
* Values that are associated with a key.
* The following values can be returned by the Swekey_GetStatus() function
*/
-define ("SWEKEY_STATUS_OK",0);
-define ("SWEKEY_STATUS_NOT_FOUND",1); // The key does not exist in the db
-define ("SWEKEY_STATUS_INACTIVE",2); // The key has never been activated
-define ("SWEKEY_STATUS_LOST",3); // The user has lost his key
-define ("SWEKEY_STATUS_STOLEN",4); // The key was stolen
-define ("SWEKEY_STATUS_FEE_DUE",5); // The annual fee was not paid
-define ("SWEKEY_STATUS_OBSOLETE",6); // The hardware is no longer supported
-define ("SWEKEY_STATUS_UNKOWN",201); // We could not connect to the authentication server
+define ("SWEKEY_STATUS_OK", 0);
+define ("SWEKEY_STATUS_NOT_FOUND", 1); // The key does not exist in the db
+define ("SWEKEY_STATUS_INACTIVE", 2); // The key has never been activated
+define ("SWEKEY_STATUS_LOST", 3); // The user has lost his key
+define ("SWEKEY_STATUS_STOLEN", 4); // The key was stolen
+define ("SWEKEY_STATUS_FEE_DUE", 5); // The annual fee was not paid
+define ("SWEKEY_STATUS_OBSOLETE", 6); // The hardware is no longer supported
+define ("SWEKEY_STATUS_UNKOWN", 201); // We could not connect to the authentication server
/**
* Values that are associated with a key.
* The Javascript Api can also return the following values
*/
-define ("SWEKEY_STATUS_REPLACED",100); // This key has been replaced by a backup key
-define ("SWEKEY_STATUS_BACKUP_KEY",101); // This key is a backup key that is not activated yet
-define ("SWEKEY_STATUS_NOTPLUGGED",200); // This key is not plugged in the computer
+define ("SWEKEY_STATUS_REPLACED", 100); // This key has been replaced by a backup key
+define ("SWEKEY_STATUS_BACKUP_KEY", 101); // This key is a backup key that is not activated yet
+define ("SWEKEY_STATUS_NOTPLUGGED", 200); // This key is not plugged in the computer
/**
diff --git a/libraries/header_scripts.inc.php b/libraries/header_scripts.inc.php
index 0563868..21c5d9a 100644
--- a/libraries/header_scripts.inc.php
+++ b/libraries/header_scripts.inc.php
@@ -61,7 +61,7 @@ if (typeof(parent.document) != 'undefined' && typeof(parent.document) != 'unknow
}
<?php
if(count($GLOBALS['js_script']) > 0) {
- echo implode("\n",$GLOBALS['js_script'])."\n";
+ echo implode("\n", $GLOBALS['js_script'])."\n";
}
foreach ($GLOBALS['js_events'] as $js_event) {
diff --git a/libraries/import.lib.php b/libraries/import.lib.php
index c2de669..c44cb16 100644
--- a/libraries/import.lib.php
+++ b/libraries/import.lib.php
@@ -407,7 +407,7 @@ function PMA_getColumnNumberFromName($name)
// base26 to base10 conversion : multiply each number
// with corresponding value of the position, in this case
// $i=0 : 1; $i=1 : 26; $i=2 : 676; ...
- $column_number += $number * pow(26,$i);
+ $column_number += $number * pow(26, $i);
}
return $column_number;
} else {
diff --git a/libraries/mult_submits.inc.php b/libraries/mult_submits.inc.php
index 6a4c242..1c3713b 100644
--- a/libraries/mult_submits.inc.php
+++ b/libraries/mult_submits.inc.php
@@ -430,14 +430,14 @@ elseif ($mult_btn == __('Yes')) {
case 'replace_prefix_tbl':
$current = $selected[$i];
- $newtablename = preg_replace("/^" . $from_prefix . "/" , $to_prefix , $current);
+ $newtablename = preg_replace("/^" . $from_prefix . "/", $to_prefix, $current);
$a_query = 'ALTER TABLE ' . PMA_backquote($selected[$i]) . ' RENAME ' . PMA_backquote($newtablename) ; // CHANGE PREFIX PATTERN
$run_parts = true;
break;
case 'copy_tbl_change_prefix':
$current = $selected[$i];
- $newtablename = preg_replace("/^" . $from_prefix . "/" , $to_prefix , $current);
+ $newtablename = preg_replace("/^" . $from_prefix . "/", $to_prefix, $current);
$a_query = 'CREATE TABLE ' . PMA_backquote($newtablename) . ' SELECT * FROM ' . PMA_backquote($selected[$i]) ; // COPY TABLE AND CHANGE PREFIX PATTERN
$run_parts = true;
break;
diff --git a/libraries/replication.inc.php b/libraries/replication.inc.php
index 0871d32..b057680 100644
--- a/libraries/replication.inc.php
+++ b/libraries/replication.inc.php
@@ -369,7 +369,7 @@ function PMA_replication_synchronize_db($db, $src_link, $trg_link, $data = true)
$target_columns, $alter_str_array, $add_column_array, $uncommon_columns, $criteria, $target_tables_keys, $counter);
PMA_indexesDiffInTables($src_db, $trg_db, $src_link, $trg_link, $matching_tables, $source_indexes, $target_indexes,
- $add_indexes_array, $alter_indexes_array,$remove_indexes_array, $counter);
+ $add_indexes_array, $alter_indexes_array, $remove_indexes_array, $counter);
}
/**
diff --git a/libraries/select_lang.lib.php b/libraries/select_lang.lib.php
index 62b1ea7..a755511 100644
--- a/libraries/select_lang.lib.php
+++ b/libraries/select_lang.lib.php
@@ -149,8 +149,8 @@ function PMA_langDetect($str, $envType)
if (strpos($expr, '[-_]') === false) {
$expr = str_replace('|', '([-_][[:alpha:]]{2,3})?|', $expr);
}
- if (($envType == 1 && preg_match('/^(' . addcslashes($expr,'/') . ')(;q=[0-9]\\.[0-9])?$/i', $str))
- || ($envType == 2 && preg_match('/(\(|\[|;[[:space:]])(' . addcslashes($expr,'/') . ')(;|\]|\))/i', $str))) {
+ if (($envType == 1 && preg_match('/^(' . addcslashes($expr, '/') . ')(;q=[0-9]\\.[0-9])?$/i', $str))
+ || ($envType == 2 && preg_match('/(\(|\[|;[[:space:]])(' . addcslashes($expr, '/') . ')(;|\]|\))/i', $str))) {
if (PMA_langSet($lang)) {
return true;
}
diff --git a/libraries/server_synchronize.lib.php b/libraries/server_synchronize.lib.php
index 8947b00..0bc7ae5 100644
--- a/libraries/server_synchronize.lib.php
+++ b/libraries/server_synchronize.lib.php
@@ -467,7 +467,7 @@ function PMA_updateTargetTables($table, $update_array, $src_db, $trg_db, $trg_li
*/
function PMA_insertIntoTargetTable($matching_table, $src_db, $trg_db, $src_link, $trg_link, $table_fields, &$array_insert, $matching_table_index,
$matching_tables_keys, $source_columns, &$add_column_array, $criteria, $target_tables_keys, $uncommon_tables, &$uncommon_tables_fields, $uncommon_cols,
- &$alter_str_array,&$source_indexes, &$target_indexes, &$add_indexes_array, &$alter_indexes_array, &$delete_array, &$update_array, $display)
+ &$alter_str_array, &$source_indexes, &$target_indexes, &$add_indexes_array, &$alter_indexes_array, &$delete_array, &$update_array, $display)
{
if (isset($array_insert[$matching_table_index])) {
if (sizeof($array_insert[$matching_table_index])) {
@@ -519,7 +519,7 @@ function PMA_insertIntoTargetTable($matching_table, $src_db, $trg_db, $src_link,
unset($delete_array[$table_index[0]]);
}
PMA_addColumnsInTargetTable($src_db, $trg_db, $src_link, $trg_link, $matching_tables, $source_columns, $add_column_array,
- $matching_tables_fields, $criteria, $matching_tables_keys, $target_tables_keys, $uncommon_tables,$uncommon_tables_fields,
+ $matching_tables_fields, $criteria, $matching_tables_keys, $target_tables_keys, $uncommon_tables, $uncommon_tables_fields,
$table_index[0], $uncommon_cols, $display);
unset($add_column_array[$table_index[0]]);
}
@@ -1125,8 +1125,8 @@ function PMA_indexesDiffInTables($src_db, $trg_db, $src_link, $trg_link, $matchi
&$alter_indexes_array, &$remove_indexes_array, $table_counter)
{
//Gets indexes information for source and target table
- $source_indexes[$table_counter] = PMA_DBI_get_table_indexes($src_db, $matching_tables[$table_counter],$src_link);
- $target_indexes[$table_counter] = PMA_DBI_get_table_indexes($trg_db, $matching_tables[$table_counter],$trg_link);
+ $source_indexes[$table_counter] = PMA_DBI_get_table_indexes($src_db, $matching_tables[$table_counter], $src_link);
+ $target_indexes[$table_counter] = PMA_DBI_get_table_indexes($trg_db, $matching_tables[$table_counter], $trg_link);
for ($a = 0; $a < sizeof($source_indexes[$table_counter]); $a++) {
$found = false;
$z = 0;
diff --git a/libraries/svg_plot/pma_scatter_plot.php b/libraries/svg_plot/pma_scatter_plot.php
index c0be405..e7ef90e 100644
--- a/libraries/svg_plot/pma_scatter_plot.php
+++ b/libraries/svg_plot/pma_scatter_plot.php
@@ -119,7 +119,7 @@ class PMA_Scatter_Plot
$this->_dataPoints = array();
if (! is_null($this->_userSpecifiedSettings)) {
foreach (array_keys($this->_userSpecifiedSettings) as $key){
- $this->_settings[$key] = $this->_userSpecifiedSettings[$key];
+ $this->_settings[$key] = $this->_userSpecifiedSettings[$key];
}
}
if ($this->_settings['dataLabel'] == '') {
@@ -188,17 +188,17 @@ class PMA_Scatter_Plot
*
* @return an array containing the scale, x and y offsets
*/
- private function _scaleDataSet($data,$xField,$yField)
+ private function _scaleDataSet($data, $xField, $yField)
{
- // Currently assuming only numeric fields are selected
+ // Currently assuming only numeric fields are selected
$coordinates = array();
foreach ($data as $row) {
$coordinates[0][] = $row[$xField];
$coordinates[1][] = $row[$yField];
}
for ($i = 0 ; $i < 2 ; $i++) {
- $maxC = ($i == 0) ? 500 : 320;
+ $maxC = ($i == 0) ? 500 : 320;
if ( !is_numeric($coordinates[$i][0])) {
$uniqueC = array_unique($coordinates[$i]);
@@ -244,8 +244,8 @@ class PMA_Scatter_Plot
for ($i = 0 ; $i < count($data) ; $i++) {
$index = $color_number % sizeof($this->_settings['colors']);
-
- $data_element = new PMA_SVG_Data_Point($scale_data[0][$i],$scale_data[1][$i],$data[$i][$label],$data[$i]);
+
+ $data_element = new PMA_SVG_Data_Point($scale_data[0][$i], $scale_data[1][$i], $data[$i][$label], $data[$i]);
$options = array('color' => $this->_settings['colors'][$index], 'id' => $i);
$this->_dataPoints[] = $data_element;
diff --git a/libraries/svg_plot/pma_svg_data_point.php b/libraries/svg_plot/pma_svg_data_point.php
index ceaa8bc..cc07bff 100644
--- a/libraries/svg_plot/pma_svg_data_point.php
+++ b/libraries/svg_plot/pma_svg_data_point.php
@@ -13,7 +13,7 @@ class PMA_SVG_Data_Point extends PMA_SVG_Data_Element
* X-Coordinate of the point
*/
private $cx;
-
+
/*
* Y-Coordinate of the point
*/
@@ -24,7 +24,7 @@ class PMA_SVG_Data_Point extends PMA_SVG_Data_Element
*/
public function __construct($cx, $cy, $label, $dataRow)
{
- parent::__construct($label,$dataRow);
+ parent::__construct($label, $dataRow);
$this->cx = $cx;
$this->cy = $cy;
}
@@ -50,7 +50,7 @@ class PMA_SVG_Data_Point extends PMA_SVG_Data_Element
'stroke' => $options['color'],
'stroke-width'=> 2,
);
-
+
$row = '<circle cx="' . $this->cx . '" cy="' . $this->cy . '" r=".1"';
foreach ($point_options as $option => $val) {
$row .= ' ' . $option . '="' . trim($val) . '"';
@@ -59,7 +59,7 @@ class PMA_SVG_Data_Point extends PMA_SVG_Data_Element
return $row;
}
-
+
public function getCx()
{
return $this->cx;
diff --git a/libraries/sysinfo.lib.php b/libraries/sysinfo.lib.php
index 96ac0e2..e5f18b7 100644
--- a/libraries/sysinfo.lib.php
+++ b/libraries/sysinfo.lib.php
@@ -14,7 +14,7 @@
*/
function getSysInfo()
{
- $supported = array('Linux','WINNT');
+ $supported = array('Linux', 'WINNT');
$sysinfo = array();
@@ -110,7 +110,7 @@ class Linux
function loadavg() {
$buf = file_get_contents('/proc/stat');
- $nums=preg_split("/\s+/", substr($buf,0,strpos($buf,"\n")));
+ $nums=preg_split("/\s+/", substr($buf, 0, strpos($buf, "\n")));
return Array('busy' => $nums[1]+$nums[2]+$nums[3], 'idle' => intval($nums[4]));
}
diff --git a/navigation.php b/navigation.php
index 26716ac..1db459c 100644
--- a/navigation.php
+++ b/navigation.php
@@ -315,7 +315,7 @@ if ($GLOBALS['cfg']['LeftFrameLight'] && strlen($GLOBALS['db'])) {
echo '</div>' . "\n";
$common_url_query = PMA_generate_common_url();
- PMA_displayDbList($GLOBALS['pma']->databases->getGroupedDetails($_SESSION['tmp_user_values']['navi_limit_offset'],$GLOBALS['cfg']['MaxDbList']), $_SESSION['tmp_user_values']['navi_limit_offset'],$GLOBALS['cfg']['MaxDbList']);
+ PMA_displayDbList($GLOBALS['pma']->databases->getGroupedDetails($_SESSION['tmp_user_values']['navi_limit_offset'], $GLOBALS['cfg']['MaxDbList']), $_SESSION['tmp_user_values']['navi_limit_offset'], $GLOBALS['cfg']['MaxDbList']);
}
/**
diff --git a/pmd_general.php b/pmd_general.php
index 73c6543..3f59a4c 100644
--- a/pmd_general.php
+++ b/pmd_general.php
@@ -287,17 +287,17 @@ for ($i = 0; $i < count($GLOBALS['PMD']["TABLE_NAME"]); $i++) {
} else {
?>
<img src="<?php echo $_SESSION['PMA_Theme']->getImgPath(); ?>pmd/Field_small<?php
- if (strstr($tab_column[$t_n]["TYPE"][$j],'char')
- || strstr($tab_column[$t_n]["TYPE"][$j],'text')) {
+ if (strstr($tab_column[$t_n]["TYPE"][$j], 'char')
+ || strstr($tab_column[$t_n]["TYPE"][$j], 'text')) {
echo '_char';
- } elseif (strstr($tab_column[$t_n]["TYPE"][$j],'int')
- || strstr($tab_column[$t_n]["TYPE"][$j],'float')
- || strstr($tab_column[$t_n]["TYPE"][$j],'double')
- || strstr($tab_column[$t_n]["TYPE"][$j],'decimal')) {
+ } elseif (strstr($tab_column[$t_n]["TYPE"][$j], 'int')
+ || strstr($tab_column[$t_n]["TYPE"][$j], 'float')
+ || strstr($tab_column[$t_n]["TYPE"][$j], 'double')
+ || strstr($tab_column[$t_n]["TYPE"][$j], 'decimal')) {
echo '_int';
- } elseif (strstr($tab_column[$t_n]["TYPE"][$j],'date')
- || strstr($tab_column[$t_n]["TYPE"][$j],'time')
- || strstr($tab_column[$t_n]["TYPE"][$j],'year')) {
+ } elseif (strstr($tab_column[$t_n]["TYPE"][$j], 'date')
+ || strstr($tab_column[$t_n]["TYPE"][$j], 'time')
+ || strstr($tab_column[$t_n]["TYPE"][$j], 'year')) {
echo '_date';
}
?>.png" alt="*" />
diff --git a/pmd_pdf.php b/pmd_pdf.php
index f8102da..95a412b 100644
--- a/pmd_pdf.php
+++ b/pmd_pdf.php
@@ -39,7 +39,7 @@ if (isset($mode)) {
if ('export' == $mode) {
$sql = "REPLACE INTO " . $pma_table . " (db_name, table_name, pdf_page_number, x, y) SELECT db_name, table_name, " . $pdf_page_number_q . ", ROUND(x/" . $scale_q . ") , ROUND(y/" . $scale_q . ") y FROM " . $pmd_table . " WHERE db_name = '" . PMA_sqlAddSlashes($db) . "'";
- PMA_query_as_controluser($sql,true,PMA_DBI_QUERY_STORE);
+ PMA_query_as_controluser($sql, true, PMA_DBI_QUERY_STORE);
}
if ('import' == $mode) {
@@ -101,7 +101,7 @@ if (1 == count($choices)) {
echo $choices['create_export'];
echo '<input type="hidden" name="mode" value="create_export" />';
} else {
- PMA_display_html_radio('mode', $choices, $checked_choice = '', $line_break = true, $escape_label = false, $class='');
+ PMA_display_html_radio('mode', $choices, $checked_choice = '', $line_break = true, $escape_label = false, $class = '');
}
echo '<br />';
echo '<label for="newpage">' . __('New page name: ') . '</label>';
diff --git a/pmd_relation_new.php b/pmd_relation_new.php
index a171658..c0a6ad8 100644
--- a/pmd_relation_new.php
+++ b/pmd_relation_new.php
@@ -24,7 +24,7 @@ if (PMA_foreignkey_supported($type_T1) && PMA_foreignkey_supported($type_T2) &&
$existrel_foreign = PMA_getForeigners($db, $T2, '', 'foreign');
if (isset($existrel_foreign[$F2])
&& isset($existrel_foreign[$F2]['constraint'])) {
- PMD_return_new(0,__('Error: relation already exists.'));
+ PMD_return_new(0, __('Error: relation already exists.'));
}
// note: in InnoDB, the index does not requires to be on a PRIMARY
// or UNIQUE key
@@ -56,8 +56,8 @@ if (PMA_foreignkey_supported($type_T1) && PMA_foreignkey_supported($type_T2) &&
if ($on_update != 'nix') {
$upd_query .= ' ON UPDATE ' . $on_update;
}
- PMA_DBI_try_query($upd_query) or PMD_return_new(0,__('Error: Relation not added.'));
- PMD_return_new(1,__('FOREIGN KEY relation added'));
+ PMA_DBI_try_query($upd_query) or PMD_return_new(0, __('Error: Relation not added.'));
+ PMD_return_new(1, __('FOREIGN KEY relation added'));
}
// internal (pmadb) relation
@@ -78,7 +78,7 @@ if (PMA_foreignkey_supported($type_T1) && PMA_foreignkey_supported($type_T2) &&
. '\'' . PMA_sqlAddSlashes($T1) . '\','
. '\'' . PMA_sqlAddSlashes($F1) . '\')';
- if (PMA_query_as_controluser($q , false, PMA_DBI_QUERY_STORE)) {
+ if (PMA_query_as_controluser($q, false, PMA_DBI_QUERY_STORE)) {
PMD_return_new(1, __('Internal relation added'));
} else {
PMD_return_new(0, __('Error: Relation not added.'));
diff --git a/pmd_relation_upd.php b/pmd_relation_upd.php
index 29bc688..7fd78e4 100644
--- a/pmd_relation_upd.php
+++ b/pmd_relation_upd.php
@@ -13,8 +13,8 @@ extract($_POST, EXTR_SKIP);
extract($_GET, EXTR_SKIP);
$die_save_pos = 0;
require_once 'pmd_save_pos.php';
-list($DB1,$T1) = explode(".",$T1);
-list($DB2,$T2) = explode(".",$T2);
+list($DB1, $T1) = explode(".", $T1);
+list($DB2, $T2) = explode(".", $T2);
$tables = PMA_DBI_get_tables_full($db, $T1);
$type_T1 = strtoupper($tables[$T1]['ENGINE']);
@@ -54,7 +54,7 @@ if ($try_to_delete_internal_relation) {
}
PMD_return_upd(1, __('Relation deleted'));
-function PMD_return_upd($b,$ret)
+function PMD_return_upd($b, $ret)
{
global $K;
header("Content-Type: text/xml; charset=utf-8");
diff --git a/schema_export.php b/schema_export.php
index e566c7c..d67bc85 100644
--- a/schema_export.php
+++ b/schema_export.php
@@ -28,7 +28,7 @@ require_once "./libraries/schema/Export_Relation_Schema.class.php";
* call and include the appropriate Schema Class depending on $export_type
* default is PDF
*/
-global $db,$export_type;
+global $db, $export_type;
if (!isset($export_type) || !preg_match('/^[a-zA-Z]+$/', $export_type)) {
$export_type = 'pdf';
}
@@ -36,7 +36,7 @@ PMA_DBI_select_db($db);
$path = PMA_securePath(ucfirst($export_type));
if (!file_exists('./libraries/schema/' . $path . '_Relation_Schema.class.php')) {
- PMA_Export_Relation_Schema::dieSchema($_POST['chpage'],$export_type,__('File doesn\'t exist'));
+ PMA_Export_Relation_Schema::dieSchema($_POST['chpage'], $export_type, __('File doesn\'t exist'));
}
require "./libraries/schema/".$path."_Relation_Schema.class.php";
$obj_schema = eval("new PMA_".$path."_Relation_Schema();");
diff --git a/server_synchronize.php b/server_synchronize.php
index 8057f89..d4627cf 100644
--- a/server_synchronize.php
+++ b/server_synchronize.php
@@ -587,10 +587,10 @@ if (isset($_REQUEST['Table_ids'])) {
unset($delete_array[$matching_table_structure_diff[$q]]);
}
- PMA_addColumnsInTargetTable($src_db, $trg_db,$src_link, $trg_link,
+ PMA_addColumnsInTargetTable($src_db, $trg_db, $src_link, $trg_link,
$matching_tables, $source_columns, $add_column_array,
$matching_tables_fields, $criteria, $matching_tables_keys,
- $target_tables_keys, $uncommon_tables,$uncommon_tables_fields,
+ $target_tables_keys, $uncommon_tables, $uncommon_tables_fields,
$matching_table_structure_diff[$q], $uncommon_cols, false);
unset($add_column_array[$matching_table_structure_diff[$q]]);
@@ -653,7 +653,7 @@ if (isset($_REQUEST['Table_ids'])) {
unset($delete_array[$matching_table_data_diff[$p]]);
}
- PMA_addColumnsInTargetTable($src_db, $trg_db,$src_link, $trg_link,
+ PMA_addColumnsInTargetTable($src_db, $trg_db, $src_link, $trg_link,
$matching_tables, $source_columns, $add_column_array,
$matching_tables_fields, $criteria, $matching_tables_keys,
$target_tables_keys, $uncommon_tables, $uncommon_tables_fields,
@@ -1113,7 +1113,7 @@ if (isset($_REQUEST['synchronize_db'])) {
$trg_link , $matching_tables_fields, $insert_array, $p,
$matching_tables_keys, $matching_tables_keys, $source_columns,
$add_column_array, $criteria, $target_tables_keys, $uncommon_tables,
- $uncommon_tables_fields,$uncommon_cols, $alter_str_array,$source_indexes,
+ $uncommon_tables_fields, $uncommon_cols, $alter_str_array, $source_indexes,
$target_indexes, $add_indexes_array,
$alter_indexes_array, $delete_array, $update_array, true);
}
diff --git a/server_variables.php b/server_variables.php
index af47f1f..f09706a 100644
--- a/server_variables.php
+++ b/server_variables.php
@@ -45,7 +45,7 @@ if (isset($_REQUEST['ajax_request']) && $_REQUEST['ajax_request'] == true) {
$varValue = PMA_DBI_fetch_single_row('SHOW GLOBAL VARIABLES WHERE Variable_name="' . PMA_sqlAddslashes($_REQUEST['varName']) . '";', 'NUM');
if (isset($VARIABLE_DOC_LINKS[$_REQUEST['varName']][3])
&& $VARIABLE_DOC_LINKS[$_REQUEST['varName']][3] == 'byte') {
- exit(implode(' ', PMA_formatByteDown($varValue[1],3,3)));
+ exit(implode(' ', PMA_formatByteDown($varValue[1], 3, 3)));
}
exit($varValue[1]);
break;
@@ -55,7 +55,7 @@ if (isset($_REQUEST['ajax_request']) && $_REQUEST['ajax_request'] == true) {
if (isset($VARIABLE_DOC_LINKS[$_REQUEST['varName']][3])
&& $VARIABLE_DOC_LINKS[$_REQUEST['varName']][3] == 'byte'
- && preg_match('/^\s*(\d+(\.\d+)?)\s*(mb|kb|mib|kib|gb|gib)\s*$/i',$value,$matches)) {
+ && preg_match('/^\s*(\d+(\.\d+)?)\s*(mb|kb|mib|kib|gb|gib)\s*$/i', $value, $matches)) {
$exp = array('kb' => 1, 'kib' => 1, 'mb' => 2, 'mib' => 2, 'gb' => 3, 'gib' => 3);
$value = floatval($matches[1]) * pow(1024, $exp[strtolower($matches[3])]);
} else {
@@ -97,7 +97,7 @@ require './libraries/server_links.inc.php';
echo '<h2>' . "\n"
. ($cfg['MainPageIconic'] ? '<img class="icon ic_s_vars" src="themes/dot.gif" alt="" />' : '')
. '' . __('Server variables and settings') . "\n"
- . PMA_showMySQLDocu('server_system_variables','server_system_variables')
+ . PMA_showMySQLDocu('server_system_variables', 'server_system_variables')
. '</h2>' . "\n";
/**
@@ -138,7 +138,7 @@ foreach ($serverVars as $name => $value) {
?>
<tr class="<?php echo $row_class; ?>">
<th nowrap="nowrap"><?php echo htmlspecialchars(str_replace('_', ' ', $name)); ?></th>
- <td class="value"><?php echo formatVariable($name,$value); ?></td>
+ <td class="value"><?php echo formatVariable($name, $value); ?></td>
<td class="value"><?php
// To display variable documentation link
if (isset($VARIABLE_DOC_LINKS[$name]))
@@ -150,7 +150,7 @@ foreach ($serverVars as $name => $value) {
</tr>
<tr class="<?php echo $odd_row ? 'odd' : 'even'; ?> ">
<td>(<?php echo __('Session value'); ?>)</td>
- <td class="value"><?php echo formatVariable($name,$serverVarsSession[$name]); ?></td>
+ <td class="value"><?php echo formatVariable($name, $serverVarsSession[$name]); ?></td>
<td class="value"></td>
<?php } ?>
</tr>
@@ -162,13 +162,13 @@ foreach ($serverVars as $name => $value) {
</table>
<?php
-function formatVariable($name,$value)
+function formatVariable($name, $value)
{
global $VARIABLE_DOC_LINKS;
if (is_numeric($value)) {
if (isset($VARIABLE_DOC_LINKS[$name][3]) && $VARIABLE_DOC_LINKS[$name][3]=='byte')
- return '<abbr title="'.PMA_formatNumber($value, 0).'">'.implode(' ',PMA_formatByteDown($value,3,3)).'</abbr>';
+ return '<abbr title="'.PMA_formatNumber($value, 0).'">'.implode(' ', PMA_formatByteDown($value, 3, 3)).'</abbr>';
else return PMA_formatNumber($value, 0);
}
return htmlspecialchars($value);
di return htmlspecialchars($value); value, 0); r($value, 0).'">'.implode(' ', PMA_formatByteDown($value, 3, 3)).'</abbr>'; T['varName']) . '";', 'NUM'); . $scale_q . ") , ROUND(y/" . $scale_q . ") y FROM " . $pmd_table . " WHERE db_name = '" . PMA_sqlAddSlashes($db) . "'"; � �! �! pz�� �z�� x���* �p�� ���* �0��* pz�� `��* �z�� ��e��* u��* �e��* ��e��* ��e��* �:��* x���* �p�� �o�� k0��* �! �! pz�� �z�� H���* �q�� ���* �0��* pz�� `��* �z�� �z�� �z�� 8;��* �p� �z�� u��* �:��* �q�� �p�� k0��* G H I J K M N O P pz�� �z�� He���* Ps�� ���* �0��* pz�� 0�e��* u��* ���* �����* �e��* ��e��* ��e��* �:��* He���* Ps�� �q�� k0��* 8e���* Ps�� �q�� k0��* (e���* Ps�� �q�� k0��* e���* Ps�� r�� k0��* ��e��* u��* ��e��* �l�� �蕷�* e��* ��e��* �r�� y蕷�* e��* �e��* �r�� Z蕷�* e��* ؔ���* ���* �����* �e��* ����* ��e��* ��e��* �:��* 8;��* ]a��* �z�� p+���* �t�� ps�� k0��* 5 6 7 8 : <