diff options
author | Keith Wood <kbwood.au@gmail.com> | 2009-11-27 06:08:13 +0000 |
---|---|---|
committer | Keith Wood <kbwood.au@gmail.com> | 2009-11-27 06:08:13 +0000 |
commit | bfdf9df0ca8e8c53d3201e426d6fb9f280c932e2 (patch) | |
tree | 244d9ae46ab06732e2cb43c395d0f6f28c601f62 | |
parent | 9f648c49dba0d372e41b79c0805ea07033b5fa51 (diff) | |
download | jquery-ui-bfdf9df0ca8e8c53d3201e426d6fb9f280c932e2.tar.gz jquery-ui-bfdf9df0ca8e8c53d3201e426d6fb9f280c932e2.zip |
Datepicker - Fixed #4969 - Datepicker cannot change values of fields named with special characters
-rw-r--r-- | ui/jquery.ui.datepicker.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ui/jquery.ui.datepicker.js b/ui/jquery.ui.datepicker.js index fa2c701a0..9de0e8ce5 100644 --- a/ui/jquery.ui.datepicker.js +++ b/ui/jquery.ui.datepicker.js @@ -159,7 +159,7 @@ $.extend(Datepicker.prototype, { /* Create a new instance object. */ _newInst: function(target, inline) { - var id = target[0].id.replace(/([:\[\]\.\$])/g, '\\\\$1'); // escape jQuery meta chars + var id = target[0].id.replace(/([^A-Za-z0-9_])/g, '\\\\$1'); // escape jQuery meta chars return {id: id, input: target, // associated target selectedDay: 0, selectedMonth: 0, selectedYear: 0, // current selection drawMonth: 0, drawYear: 0, // month being drawn |