Monday, April 4, 2016

jQuery datepicker calender issues in Firefox

Leave a Comment

I have wrong dates showing up in my jQuery UI datepicker in some 2016 months in Firefox (Mobile & Web). For example:

March 31, 2016 is Thursday and April 1, 2016 of course is a Friday - but not on my calendar, where it shows up as a Thursday, as well. There is the same issue for May 2016.

Please see screenshots:

March 2016 and April 2016

Note that I tried to use many versions of jQuery scripts but have the same issue with all of them.

2 Answers

Answers 1

Its not code issue..

This issue has been caused by Firefox with jquery datepicker because some countries had daylight saving changes on 2016-04-01, and the changes is right at 00:00:00! So these countries does not have 00:00:00 on 2016-04-01, Firefox is confused and thinks that 00:00:00 is still Thursday.

And the issue has been fixed while we are in 1-4-2016 ...

Answers 2

   <!doctype html>     <html lang="en">     <head>       <meta charset="utf-8">       <title>jQuery UI Datepicker - Default functionality</title>       <link rel="stylesheet" href="//code.jquery.com/ui/1.11.4/themes/smoothness/jquery-ui.css">       <script src="//code.jquery.com/jquery-1.10.2.js"></script>       <script src="//code.jquery.com/ui/1.11.4/jquery-ui.js"></script>       <link rel="stylesheet" href="/resources/demos/style.css">       <script>       $(function() {         $( "#datepicker" ).datepicker();       });       </script>     </head>     <body>      <p>Date: <input type="text" id="datepicker"></p>       </body>     </html> This code works with any browser, There might any error in your code, kindly copy display your code here. 
If You Enjoyed This, Take 5 Seconds To Share It

0 comments:

Post a Comment