Skip to main content

Bug Tracker

Side navigation

#3574 closed bug (invalid)

Opened November 04, 2008 07:48PM UTC

Closed November 06, 2008 09:47PM UTC

Datepicker UI has two days with the same number for November.

Reported by: jeberly Owned by: flesler
Priority: major Milestone: 1.3
Component: unfiled Version: 1.2.6
Keywords: Cc:
Blocked by: Blocking:
Description

Go to datepicker for 2008 and notice two Nov 2nd's.

Attachments (0)
Change History (3)

Changed November 05, 2008 03:29AM UTC by hunterheitzm comment:1

also displays numbers incorrectly for November 2007 if you go a year back.

Changed November 06, 2008 08:44PM UTC by jehinkle comment:2

The problem is daylight savings time. The Date object on line 172 sets the year,month and day, but with no time specified defaults to midnight. So when the time increments by 1 day, and then daylight savings sets it back 1 hour, you get two November 2 on the calendar. Include a time greater than 1 when the date object is created and problem is solved.

Change line 1272 in ui.datepicker.js or line 5801 in jquery.ui.all.js from:

var printDate = new Date(drawYear, drawMonth, 1 - leadDays);

to:

var printDate = new Date(drawYear, drawMonth, 1 - leadDays,12);

Changed November 06, 2008 09:47PM UTC by flesler comment:3

resolution: → invalid
status: newclosed

This belongs to the UI Bug Tracker.