Patch for the bug #449858 (PHP3 compatible)

This commit is contained in:
Loïc Chapeaux
2001-08-15 09:52:27 +00:00
parent 4ccadfe6b2
commit 1a7c1cb690
2 changed files with 10 additions and 25 deletions

View File

@@ -18,7 +18,8 @@ if (isset($submit)) {
// Builds the field creation statement and alters the table
for ($i = 0; $i < count($field_name); ++$i) {
$query .= backquote($field_name[$i]) . ' ' . $field_type[$i];
if ($field_length[$i] != '') {
if ($field_length[$i] != ''
&& !eregi('^(DATE|DATETIME|TIME|TINYBLOB|TINYTEXT|BLOB|TEXT|MEDIUMBLOB|MEDIUMTEXT|LONGBLOB|LONGTEXT)$', $field_type[$i])) {
if (get_magic_quotes_gpc()) {
$query .= '(' . stripslashes($field_length[$i]) . ')';
} else {