From f412e93aecbbd30df43d9a52a6cf748c8081229a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Chapeaux?= Date: Tue, 4 Sep 2001 21:32:50 +0000 Subject: [PATCH] field size should always be at least 4 to allow the use of the 'null' value --- tbl_change.php3 | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/tbl_change.php3 b/tbl_change.php3 index 432a2edfc..2a0cff7b5 100755 --- a/tbl_change.php3 +++ b/tbl_change.php3 @@ -321,8 +321,12 @@ for ($i = 0; $i < $fields_cnt; $i++) { } // end if...else } // end else if else { - $fieldsize = (($len > 40) ? 40 : $len); - $maxlength = (($len < 4) ? 4 : $len); + if ($len < 4) { + $fieldsize = $maxlength = 4; + } else { + $fieldsize = $len; + $maxlength = (($len > 40) ? 40 : $len); + } echo "\n"; ?>