diff --git a/libraries/display_tbl.lib.php3 b/libraries/display_tbl.lib.php3 index 397b235c3..d53cfba50 100644 --- a/libraries/display_tbl.lib.php3 +++ b/libraries/display_tbl.lib.php3 @@ -779,8 +779,8 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')){ ?> > builds + // 1.1 Results from a "SELECT" statement -> builds the // the "primary" key to use in links if ($is_display['edit_lnk'] == 'ur' /* || $is_display['edit_lnk'] == 'dr' */) { for ($i = 0; $i < $fields_cnt; ++$i) { - $meta = $fields_meta[$i]; + $meta = $fields_meta[$i]; $condition = ' ' . PMA_backquote($meta->name) . ' '; // loic1: To fix bug #474943 under php4, the row @@ -909,12 +909,13 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')){ // 2. Displays the rows' values for ($i = 0; $i < $fields_cnt; ++$i) { - $meta = $fields_meta[$i]; + $meta = $fields_meta[$i]; // loic1: To fix bug #474943 under php4, the row pointer will // depend on whether the "is_null" php4 function is // available or not $pointer = (function_exists('is_null') ? $i : $meta->name); + if ($meta->numeric == 1) { if (!isset($row[$meta->name]) || (function_exists('is_null') && is_null($row[$pointer]))) { @@ -994,14 +995,12 @@ if (!defined('PMA_DISPLAY_TBL_LIB_INCLUDED')){ . 'lang=' . $lang . '&server=' . $server . '&db=' . urlencode($db) . '&table=' . urlencode($map[$meta->name][0]) . '&pos=0&session_max_rows=' . $session_max_rows . '&dontlimitchars=' . $dontlimitchars - . '&sql_query=' . urlencode('SELECT * FROM ' . PMA_backquote($map[$meta->name][0]) . ' WHERE ' . $map[$meta->name][1] . " = '" . $row[$pointer] . "'") . '">' + . '&sql_query=' . urlencode('SELECT * FROM ' . PMA_backquote($map[$meta->name][0]) . ' WHERE ' . $map[$meta->name][1] . ' = \'' . $row[$pointer] . '\'') . '">' . $row[$pointer] . ''; } else { $vertical_display['data'][$foo][$i] .= $row[$pointer]; } - $vertical_display['data'][$foo][$i] .= ' ' . "\n"; - } else { $vertical_display['data'][$foo][$i] = '  ' . "\n"; }