Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Print first function if only one

git-svn-id: https://adminer.svn.sourceforge.net/svnroot/adminer/trunk@1073 7c3ca157-0c34-0410-bff1-cbf682f78f5c
  • Loading branch information...
commit b74dfdc5127f492391682ff7344d4e767226eb14 1 parent 45e0de7
jakubvrana authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  adminer/include/functions.inc.php
View
2  adminer/include/functions.inc.php
@@ -445,7 +445,7 @@ function input($field, $value, $function) {
$first++;
}
$onchange = ($first ? " onchange=\"var f = this.form['function[" . addcslashes($name, "\r\n'\\") . "]']; if ($first > f.selectedIndex) f.selectedIndex = $first;\"" : "");
- echo (count($functions) > 1 ? "<select name='function[$name]'>" . optionlist($functions, !isset($function) || in_array($function, $functions) ? $function : "") . "</select>" : nbsp($functions[0])) . '<td>';
+ echo (count($functions) > 1 ? "<select name='function[$name]'>" . optionlist($functions, !isset($function) || in_array($function, $functions) ? $function : "") . "</select>" : nbsp(reset($functions))) . '<td>';
$input = $adminer->editInput($_GET["edit"], $field, " name='fields[$name]'$onchange", $value); // usage in call is without a table
if (strlen($input)) {
echo $input;
Please sign in to comment.
Something went wrong with that request. Please try again.