From 166d011cf3534e4ceb3013bcab253d67efca9e8d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Chapeaux?= Date: Wed, 29 Aug 2001 11:53:12 +0000 Subject: [PATCH] ensure the "null" string can be used in the "value" box --- tbl_select.php3 | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/tbl_select.php3 b/tbl_select.php3 index 2990e1f9e..a96357cea 100755 --- a/tbl_select.php3 +++ b/tbl_select.php3 @@ -70,12 +70,13 @@ if (!isset($param) || $param[0] == '') { echo "\n"; $bgcolor = ($i % 2) ? $cfgBgcolorOne : $cfgBgcolorTwo; $fieldsize = (($fields_len[$i] > 40) ? 40 : $fields_len[$i]); + $maxlength = (($fields_len[$i] < 4) ? 4 : $fields_len[$i]); ?> - + @@ -139,7 +140,11 @@ else { $sql_query .= ' WHERE 1'; for ($i = 0; $i < count($fields); $i++) { if (!empty($fields) && $fields[$i] != '') { - if ($types[$i] == 'string' || $types[$i] == 'blob') { + if (strtoupper($fields[$i]) == 'NULL') { + $quot = ''; + $cmp = 'IS'; + } + else if ($types[$i] == 'string' || $types[$i] == 'blob') { $quot = '\''; $cmp = 'LIKE'; if (get_magic_quotes_gpc()) {