views:

197

answers:

2

Date.toLocaleString() returns this in Chrome:

  • Mon Jan 18 2010 16:47:42 GMT+1100 (AUS Eastern Daylight Time)

In firefox, it's this:

  • Monday, 18 January 2010 4:47:42 PM

Browser version doesn't seem to matter. Anyone have a suggestion on this one?

+1  A: 

Date.toLoacaleString is an issue on chrome:

http://code.google.com/p/chromium/issues/detail?id=29779&q=tolocalestring&colspec=ID%20Stars%20Pri%20Area%20Type%20Status%20Summary%20Modified%20Owner%20Mstone%20OS

jspcal
That's not the issue. That ticket implies that a localization was missing and the string was not provided in the expected language.
peller
A: 

As CMS answered above, these methods can return pretty much anything they want, hopefully in a representation that is readable to someone in that locale (language + cultural conventions) To obtain a particular formatting of a Date, you need to use a library like DateJS or Dojo.

peller