diff --git a/editing.inc.php b/editing.inc.php index a8cdb824..12d7e199 100644 --- a/editing.inc.php +++ b/editing.inc.php @@ -225,8 +225,15 @@ function remove_row(button) { } function type_change(type) { var name = type.name.substr(0, type.name.length - 6); - type.form[name + '[collation]'].style.display = (/char|text|enum|set/.test(type.options[type.selectedIndex].text) ? '' : 'none'); - type.form[name + '[unsigned]'].style.display = (/int|float|double|decimal/.test(type.options[type.selectedIndex].text) ? '' : 'none'); + for (var i=0; i < type.form.elements.length; i++) { + var el = type.form.elements[i]; + if (el.name == name + '[collation]') { + el.style.display = (/char|text|enum|set/.test(type.options[type.selectedIndex].text) ? '' : 'none'); + } + if (el.name == name + '[unsigned]') { + el.style.display = (/int|float|double|decimal/.test(type.options[type.selectedIndex].text) ? '' : 'none'); + } + } } for (var i=1; >= i; i++) { document.getElementById('form')['fields[' + i + '][type]'].onchange(); diff --git a/select.inc.php b/select.inc.php index 4cb70000..046ac5ca 100644 --- a/select.inc.php +++ b/select.inc.php @@ -191,7 +191,7 @@ function add_row(field) { foreach ((array) $_GET["where"] as $val) { if (strlen("$val[col]$val[val]") && in_array($val["op"], $operators)) { echo "
"; - echo ""; + echo ""; echo "
\n"; $i++; } @@ -199,7 +199,12 @@ function add_row(field) { ?> "; - echo ""; + echo ""; echo "\n"; echo "\n";