coding standards
This commit is contained in:
@@ -518,15 +518,15 @@ h1 {font-family: sans-serif; font-size: large; font-weight: bold}
|
|||||||
unset($cfg['Servers'][$key]);
|
unset($cfg['Servers'][$key]);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Final solution to bug #582890
|
// Final solution to bug #582890
|
||||||
// If we are using a socket connection
|
// If we are using a socket connection
|
||||||
// and there is nothing in the verbose server name
|
// and there is nothing in the verbose server name
|
||||||
// or the host field, then generate a name for the server
|
// or the host field, then generate a name for the server
|
||||||
// in the form of "Server 2", localized of course!
|
// in the form of "Server 2", localized of course!
|
||||||
if ( ($val['connect_type'] == 'socket') && empty($val['host']) && empty($val['verbose']) ) {
|
if ( ($val['connect_type'] == 'socket') && empty($val['host']) && empty($val['verbose']) ) {
|
||||||
$cfg['Servers'][$key]['verbose'] = sprintf($GLOBALS['strServer'],$key);
|
$cfg['Servers'][$key]['verbose'] = sprintf($GLOBALS['strServer'], $key);
|
||||||
$val['verbose'] = sprintf($GLOBALS['strServer'],$key);
|
$val['verbose'] = sprintf($GLOBALS['strServer'],$key);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (empty($server) || !isset($cfg['Servers'][$server]) || !is_array($cfg['Servers'][$server])) {
|
if (empty($server) || !isset($cfg['Servers'][$server]) || !is_array($cfg['Servers'][$server])) {
|
||||||
|
@@ -197,7 +197,7 @@ $fields_cnt = mysql_num_rows($table_def);
|
|||||||
|
|
||||||
// Set a flag here because the 'if' would not be valid in the loop
|
// Set a flag here because the 'if' would not be valid in the loop
|
||||||
// if we set a value in some field
|
// if we set a value in some field
|
||||||
$insert_mode = (!isset($row) ? TRUE:FALSE);
|
$insert_mode = (!isset($row) ? TRUE : FALSE);
|
||||||
|
|
||||||
for ($i = 0; $i < $fields_cnt; $i++) {
|
for ($i = 0; $i < $fields_cnt; $i++) {
|
||||||
// Display the submit button after every 15 lines --swix
|
// Display the submit button after every 15 lines --swix
|
||||||
@@ -400,12 +400,12 @@ for ($i = 0; $i < $fields_cnt; $i++) {
|
|||||||
// not use a drop-down if more than 200 rows in the foreign table,
|
// not use a drop-down if more than 200 rows in the foreign table,
|
||||||
// for speed reasons and because we need a better interface for this.
|
// for speed reasons and because we need a better interface for this.
|
||||||
//
|
//
|
||||||
// We could also do the SELECT anyway, with a LIMIT, and ensure that
|
// We could also do the SELECT anyway, with a LIMIT, and ensure that
|
||||||
// the current value of the field is one of the choices.
|
// the current value of the field is one of the choices.
|
||||||
|
|
||||||
$count_query = 'SELECT COUNT(*) AS total FROM ' . PMA_backquote($foreign_db) . '.' . PMA_backquote($foreign_table);
|
$count_query = 'SELECT COUNT(*) AS total FROM ' . PMA_backquote($foreign_db) . '.' . PMA_backquote($foreign_table);
|
||||||
$count_result = PMA_mysql_query($count_query) or PMA_mysqlDie('', $count_query, '', $err_url);
|
$count_result = PMA_mysql_query($count_query) or PMA_mysqlDie('', $count_query, '', $err_url);
|
||||||
$the_total = PMA_mysql_result($count_result, 0, 'total');
|
$the_total = PMA_mysql_result($count_result, 0, 'total');
|
||||||
mysql_free_result($count_result);
|
mysql_free_result($count_result);
|
||||||
|
|
||||||
if ($the_total < 200) {
|
if ($the_total < 200) {
|
||||||
@@ -416,7 +416,7 @@ for ($i = 0; $i < $fields_cnt; $i++) {
|
|||||||
. ' FROM ' . PMA_backquote($foreign_db) . '.' . PMA_backquote($foreign_table);
|
. ' FROM ' . PMA_backquote($foreign_db) . '.' . PMA_backquote($foreign_table);
|
||||||
$disp = PMA_mysql_query($dispsql);
|
$disp = PMA_mysql_query($dispsql);
|
||||||
}
|
}
|
||||||
}
|
} // end if $foreigners
|
||||||
|
|
||||||
if (isset($disp) && $disp) {
|
if (isset($disp) && $disp) {
|
||||||
echo ' <td bgcolor="' . $bgcolor . '">' . "\n";
|
echo ' <td bgcolor="' . $bgcolor . '">' . "\n";
|
||||||
|
Reference in New Issue
Block a user