Search and Top Navigation
#4171 closed bug (wontfix)
Opened February 17, 2009 05:26PM UTC
Closed February 19, 2009 10:34AM UTC
Last modified October 11, 2012 09:15PM UTC
Datepicker cannot set text input elements value if the input id attribute contains a period ('.')
Reported by: | kamfotl | Owned by: | |
---|---|---|---|
Priority: | critical | Milestone: | |
Component: | ui.datepicker | Version: | 1.5.3 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description
In ui version 1.5.3 using jQuery 1.2.6, I am getting the following error when picking a day for a datepicker on an input field which has an id attribute containing a period ('.'):
elem has no properties var id = elem[ expando ]; // jquery-1.2.6.js (line 662)
The following code demonstrates the error:
<html> <head> <link type="text/css" href="theme/ui.all.css" rel="Stylesheet" /> <script type="text/javascript" src="jquery-1.2.6.js"></script> <script type="text/javascript" src="jquery-ui-personalized-1.5.3.js"></script> <script type="text/javascript" language="javascript"> $('document').ready(function() { $('#a\\\\.b').datepicker(); $('#c').datepicker(); }); </script> </head> <body> id="c": <input id="c" name="c" type="text"/> id="a.b" (broken): <input id="a.b" name="a.b" type="text"/> </body> </html>
Replace jquery-ui with version 1.5.1, the above works correctly:
<html> <head> <link type="text/css" href="theme/ui.all.css" rel="Stylesheet" /> <script type="text/javascript" src="jquery-1.2.6.js"></script> <!-- <script type="text/javascript" src="jquery-ui-personalized-1.5.3.js"></script> --> <script type="text/javascript" src="jquery.ui.all-1.5.1.js"></script> <script type="text/javascript" language="javascript"> $('document').ready(function() { $('#a\\\\.b').datepicker(); $('#c').datepicker(); }); </script> </head> <body> id="c": <input id="c" name="c" type="text"/> id="a.b" (broken): <input id="a.b" name="a.b" type="text"/> </body> </html>
I am seeing this error on Firefox 2, Firefox 3, and IE 6.
Kelly
It works in 1.6.