Fix undefined max_input_vars.
Signed-off-by: Hugues Peccatte <hugues.peccatte@gmail.com>
This commit is contained in:
parent
eac47b0775
commit
9632ea441b
@ -4117,6 +4117,9 @@ function checkNumberOfFields() {
|
||||
if (typeof maxInputVars === 'undefined') {
|
||||
return false;
|
||||
}
|
||||
if (false === maxInputVars) {
|
||||
return false;
|
||||
}
|
||||
$('form').each(function() {
|
||||
var nbInputs = $(this).find(':input').length;
|
||||
if (nbInputs > maxInputVars) {
|
||||
@ -4128,4 +4131,4 @@ function checkNumberOfFields() {
|
||||
});
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
@ -424,7 +424,9 @@ echo "var pmaversion = '" . PMA_VERSION . "';\n";
|
||||
echo "var mysql_doc_template = '" . PMA_Util::getMySQLDocuURL('%s') . "';\n";
|
||||
|
||||
//Max input vars allowed by PHP.
|
||||
echo 'var maxInputVars = ' . ini_get('max_input_vars') . ';';
|
||||
$maxInputVars = ini_get('max_input_vars');
|
||||
echo 'var maxInputVars = ' . (false === $maxInputVars ? 'false' : $maxInputVars)
|
||||
. ';';
|
||||
|
||||
echo "if ($.datepicker) {\n";
|
||||
/* l10n: Display text for calendar close link */
|
||||
|
||||
Loading…
Reference in New Issue
Block a user