saheb11 / datejs

Automatically exported from code.google.com/p/datejs
Other
0 stars 0 forks source link

new Date(date) will choke in Safari for various date formats #117

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
try newDate(date) with date in a format using - (hyphens) and month in a number 
format, not word format.
examples that will choke:
'2011-01-23'
'01-23-2011'
examples that do work in Safari:
'jan 23 2011'
'january 23 2011'

What is the expected output? What do you see instead?
Expected output is a correct date object returned, not NaN

What version of the product are you using? On what operating system?
Safari 5.0.3 Mac OS X 10.5

You can take a look here, in FF and Safari:
http://jsbin.com/uliqu5/12/edit

Original issue reported on code.google.com by raju...@gmail.com on 20 Jan 2011 at 3:50

GoogleCodeExporter commented 8 years ago
works fine in the current build on my fork: 
https://github.com/abritinthebay/datejs/

Original comment by darkcr...@gmail.com on 16 Sep 2013 at 9:12