Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wrong value restored value from <input> #3

Closed
davibe opened this issue Mar 16, 2011 · 5 comments
Closed

wrong value restored value from <input> #3

davibe opened this issue Mar 16, 2011 · 5 comments

Comments

@davibe
Copy link

davibe commented Mar 16, 2011

I'm using the date format
"dateFormat": "DD/MM/YYYY" (italian)

i.e. 11/1/2011

I can pick the date correctly, but when I open the picker again it starts viewing month 11, and selects day 1 (restoring previous value).

What it should do is start viewing month 1 with day 11 selected.

@jtsage
Copy link
Owner

jtsage commented Mar 18, 2011

Hmm, you are correct of course - I am currently relying on the end user's browser implementation of the date function, but this points out exactly why that isn't wise. I will look at implementing a method that does not rely on the user's locale. Probably be a few days, real life is calling right now.

@davibe
Copy link
Author

davibe commented Mar 18, 2011

That means it should work correctly if I set the browser / android "locale" right, isn't it ?

@jtsage
Copy link
Owner

jtsage commented Mar 19, 2011

In theory, sure. In practice, probably most of the time. But that still wouldn't address users from other locales. I actually started writing a function to fix this tonight, just ran out of time. Hopefully I will get back to this tommorow or sunday

@jtsage
Copy link
Owner

jtsage commented Mar 20, 2011

Should be fixed in SHA: acea947 I also updated the demo (the very last field on the page) to use your indicated style, seems to function correctly.

@jtsage jtsage closed this as completed Mar 20, 2011
@davibe
Copy link
Author

davibe commented Mar 20, 2011

I can confirm it's fixed,
Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants