diff options
author | Madhura Jayaratne <madhura.cj@gmail.com> | 2015-06-15 06:23:16 +0300 |
---|---|---|
committer | Madhura Jayaratne <madhura.cj@gmail.com> | 2015-06-15 06:23:16 +0300 |
commit | 72cc1f9f513cb7252e40e46ce74f5b8ce2449ffc (patch) | |
tree | a1a491a41745da0d929905ca885f6db5c5857e73 /js/config.js | |
parent | 734d0684e5b7d634783d71b3575ccefbd6256bb5 (diff) |
bug #4958 Designer Javascript error with specially crafted table name
Signed-off-by: Madhura Jayaratne <madhura.cj@gmail.com>
Diffstat (limited to 'js/config.js')
-rw-r--r-- | js/config.js | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/js/config.js b/js/config.js index 693b8fb61b..a266a33068 100644 --- a/js/config.js +++ b/js/config.js @@ -7,7 +7,7 @@ * Unbind all event handlers before tearing down a page */ AJAX.registerTeardown('config.js', function () { - $('input[id], select[id], textarea[id]').unbind('change').unbind('keyup'); + $('.optbox input[id], .optbox select[id], .optbox textarea[id]').unbind('change').unbind('keyup'); $('input[type=button][name=submit_reset]').unbind('click'); $('div.tabs_contents').undelegate(); $('#import_local_storage, #export_local_storage').unbind('click'); @@ -473,7 +473,7 @@ function validate_field_and_fieldset(field, isKeyUp) var $field = $(field); var errors = {}; validate_field($field, isKeyUp, errors); - validate_fieldset($field.closest('fieldset'), isKeyUp, errors); + validate_fieldset($field.closest('fieldset.optbox'), isKeyUp, errors); displayErrors(errors); } @@ -495,8 +495,8 @@ function setupValidation() { loadInlineConfig(); } // register validators and mark custom values - var $elements = $('input[id], select[id], textarea[id]'); - $('input[id], select[id], textarea[id]').each(function () { + var $elements = $('.optbox input[id], .optbox select[id], .optbox textarea[id]'); + $('.optbox input[id], .optbox select[id], .optbox textarea[id]').each(function () { markField(this); var $el = $(this); $el.bind('change', function () { @@ -527,7 +527,7 @@ function setupValidation() { validate_field($elements[i], false, errors); } // run all fieldset validators - $('fieldset').each(function () { + $('fieldset.optbox').each(function () { validate_fieldset(this, false, errors); }); |