undefined offset and undefined variable

This commit is contained in:
Marc Delisle
2004-07-08 14:42:38 +00:00
parent ecb641ed13
commit c485b4b622
2 changed files with 8 additions and 11 deletions

View File

@@ -5,6 +5,9 @@ phpMyAdmin - Changelog
$Id$
$Source$
2004-07-08 Marc Delisle <lem9@users.sourceforge.net>
* db_details_qbe.php: undefined offset and undefined variable
2004-07-07 Marc Delisle <lem9@users.sourceforge.net>
* main.php: bug 984136, wrong alignment in RTL languages
* lang/arabic-utf-8, lang/sync_lang.sh: bug 984176, wrong encoding

View File

@@ -55,45 +55,39 @@ if (!isset($Rows)) {
$Rows = '';
}
if (!isset($InsCol)) {
$InsCol = '';
$InsCol = array();
}
if (!isset($DelCol)) {
$DelCol = '';
$DelCol = array();
}
if (!isset($prev_Criteria)) {
$prev_Criteria = '';
}
// workaround for a PHP3 problem
if (!isset($Criteria)) {
//$Criteria = '';
$Criteria = array();
for ($i = 0; $i < $Columns; $i++) {
$Criteria[$i] = '';
}
}
if (!isset($InsRow)) {
// $InsRow = '';
$InsRow = array();
for ($i = 0; $i < $Columns; $i++) {
$InsRow[$i] = '';
}
}
if (!isset($DelRow)) {
// $DelRow = '';
$DelRow = array();
for ($i = 0; $i < $Columns; $i++) {
$DelRow[$i] = '';
}
}
if (!isset($AndOrRow)) {
// $AndOrRow = '';
$AndOrRow = array();
for ($i = 0; $i < $Columns; $i++) {
$AndOrRow[$i] = '';
}
}
if (!isset($AndOrCol)) {
// $AndOrCol = '';
$AndOrCol = array();
for ($i = 0; $i < $Columns; $i++) {
$AndOrCol[$i] = '';
@@ -426,7 +420,7 @@ for ($y = 0; $y <= $row; $y++) {
<?php
$z = 0;
for ($x = 0; $x < $col; $x++) {
if ($InsCol[$x] == 'on') {
if (isset($InsCol[$x]) && $InsCol[$x] == 'on') {
echo "\n";
$or = 'Or' . $w . '[' . $z . ']';
?>
@@ -436,7 +430,7 @@ for ($y = 0; $y <= $row; $y++) {
<?php
$z++;
} // end if
if ($DelCol[$x] == 'on') {
if (isset($DelCol[$x]) && $DelCol[$x] == 'on') {
continue;
}
@@ -984,7 +978,7 @@ if (!empty($qry_from)) {
$qry_where = '';
$criteria_cnt = 0;
for ($x = 0; $x < $col; $x++) {
if (!empty($curField[$x]) && !empty($curCriteria[$x]) && $x && isset($last_where)) {
if (!empty($curField[$x]) && !empty($curCriteria[$x]) && $x && isset($last_where) && isset($curAndOrCol)) {
$qry_where .= ' ' . strtoupper($curAndOrCol[$last_where]) . ' ';
}
if (!empty($curField[$x]) && !empty($curCriteria[$x])) {