diff --git a/adminer/include/adminer.inc.php b/adminer/include/adminer.inc.php index a9ce35d98..4d6658712 100644 --- a/adminer/include/adminer.inc.php +++ b/adminer/include/adminer.inc.php @@ -287,7 +287,7 @@ function selectOrderPrint($order, $columns, $indexes) { } } echo "
"; - echo "
\n"; // not checkbox() to allow selectAddRow() + echo checkbox("desc[$i]", 1, false, lang('descending')) . "\n"; echo "\n"; } diff --git a/adminer/include/functions.inc.php b/adminer/include/functions.inc.php index 631280271..8dbf25b4b 100644 --- a/adminer/include/functions.inc.php +++ b/adminer/include/functions.inc.php @@ -99,14 +99,12 @@ function nl_br($string) { * @return string */ function checkbox($name, $value, $checked, $label = "", $onclick = "", $class = "") { - static $id = 0; - $id++; $return = "" + . ">" ; - return ($label != "" || $class ? "" : $return); + return ($label != "" || $class ? "$return" . h($label) . "" : $return); } /** Generate list of HTML options diff --git a/adminer/static/editing.js b/adminer/static/editing.js index 61a97a040..e639274e3 100644 --- a/adminer/static/editing.js +++ b/adminer/static/editing.js @@ -295,7 +295,7 @@ function editingAddRow(button, focus) { var tags = row.getElementsByTagName('select'); var tags2 = row2.getElementsByTagName('select'); for (var i=0; i < tags.length; i++) { - tags2[i].name = tags[i].name.replace(/([0-9.]+)/, x); + tags2[i].name = tags[i].name.replace(/[0-9.]+/, x); tags2[i].selectedIndex = tags[i].selectedIndex; } tags = row.getElementsByTagName('input'); diff --git a/changes.txt b/changes.txt index 3912df7df..981422ad3 100644 --- a/changes.txt +++ b/changes.txt @@ -2,6 +2,7 @@ Adminer 3.7.1-dev: Increase click target for checkboxes Use shadow for highlighting default button Don't use LIMIT 1 if inline updating unique row +Don't check previous checkbox on added column in create table (bug #3614245) Order table list by name PostgreSQL: Fix detecting oid column in PDO PostgreSQL: Handle timestamp types (bug #3614086)