Fresh Drupal installation with Calendar 6.x-2.x-dev Aug 3, Date 6.x-2.x-dev Aug 2, Views 6.x-2.0-rc1,PHP5, UK time zone. Date popup enabled.
Set up Content type with date field. When I create content of that type and use the date picker on the dates, the popup calendar has errors. There are two October 26 in 2008 (on Sunday and Monday). The calendar stays wrong until Dec 1 as Nov 30 and Dec 1 are both set as a Saturday. A similar thing happens in 2007 and 2009.

Comments

Tony Sharpe’s picture

Version: 6.x-2.x-dev » 6.x-2.0-beta4

It looks as though this comes from installed jquery. Presumably this is part of core (6.3). jquery is loaded before the date picker load
<script type="text/javascript" src="/misc/jquery.js?9">
I tried adding the jquery update module but it still happens.

KarenS’s picture

Status: Active » Postponed (maintainer needs more info)

I can't reproduce this -- the calendar is fine for me. You should definitely not need jquery update and if you alter the jquery version that comes with core I have no idea what would happen. I use it with Drupal core and it works fine out of the box.

Are you using any other jquery or javascript modules or code? It sounds like there is a conflict somewhere.

Tony Sharpe’s picture

I can't see any conflicts but it does sound like one. Modules in use are views, CCK, Calendar, Date,advanced help. Just updated cck and views to dev then update.php, still have problem. Code below is view source from header of one of the pages that has problem. It's a local installation under XAMPP on Win XP, FF2 Browser.

       <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="shortcut icon" href="/sites/default/files/favicon.ico" type="image/x-icon" />
    <link type="text/css" rel="stylesheet" media="all" href="/modules/node/node.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/modules/system/admin.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/modules/system/defaults.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/modules/system/system.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/modules/system/system-menus.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/modules/user/user.css?d" />

<link type="text/css" rel="stylesheet" media="all" href="/sites/all/modules/cck/theme/content.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/modules/date/date.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/modules/date/date_popup/themes/datepicker.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/modules/date/date_popup/themes/timeentry.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/sites/all/modules/calendar/calendar.css?d" />
<link type="text/css" rel="stylesheet" media="all" href="/themes/garland/style.css?d" />
<link type="text/css" rel="stylesheet" media="print" href="/themes/garland/print.css?d" />
    <script type="text/javascript" src="/misc/jquery.js?d"></script>
<script type="text/javascript" src="/misc/drupal.js?d"></script>
<script type="text/javascript" src="/misc/tabledrag.js?d"></script>
<script type="text/javascript" src="/sites/all/modules/date/date_timezone/date_timezone.js?d"></script>
<script type="text/javascript" src="/sites/all/modules/date/date_popup/lib/ui.datepicker.js?d"></script>

<script type="text/javascript" src="/sites/all/modules/date/date_popup/lib/jquery.timeentry.pack.js?d"></script>
<script type="text/javascript" src="/sites/all/modules/date/date_popup/date_popup.js?d"></script>
<script type="text/javascript" src="/misc/jquery.form.js?d"></script>
<script type="text/javascript" src="/misc/ahah.js?d"></script>
<script type="text/javascript" src="/misc/autocomplete.js?d"></script>
<script type="text/javascript" src="/misc/collapse.js?d"></script>
<script type="text/javascript" src="/misc/teaser.js?d"></script>
<script type="text/javascript" src="/misc/textarea.js?d"></script>
<script type="text/javascript" src="/misc/tableheader.js?d"></script>

<script type="text/javascript">jQuery.extend(Drupal.settings, { "basePath": "/", "datePopup": { "edit-field-start-date-0-value-datepicker-popup-0": { "func": "datepicker", "settings": { "prevText": "\x26lt;Prev", "nextText": "Next\x26gt;", "currentText": "Today", "clearText": "Clear", "closeText": "Close", "firstDay": 0, "dayNames": [ "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday" ], "dayNamesShort": [ "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" ], "dayNamesMin": [ "Su", "Mo", "Tu", "We", "Th", "Fr", "Sa" ], "monthNames": [ "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December" ], "monthNamesShort": [ "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" ], "autoPopUp": "focus", "closeAtTop": false, "speed": "immediate", "dateFormat": "dd.mm.yy", "yearRange": "-3:+3", "fromTo": false } }, "edit-field-start-date-0-value2-datepicker-popup-0": { "func": "datepicker", "settings": { "prevText": "\x26lt;Prev", "nextText": "Next\x26gt;", "currentText": "Today", "clearText": "Clear", "closeText": "Close", "firstDay": 0, "dayNames": [ "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday" ], "dayNamesShort": [ "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" ], "dayNamesMin": [ "Su", "Mo", "Tu", "We", "Th", "Fr", "Sa" ], "monthNames": [ "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December" ], "monthNamesShort": [ "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" ], "autoPopUp": "focus", "closeAtTop": false, "speed": "immediate", "dateFormat": "dd.mm.yy", "yearRange": "-3:+3", "fromTo": false } } }, "ahah": { "edit-field-start-date-field-start-date-add-more": { "url": "/content/js_add_more/event/field_start_date", "event": "mousedown", "keypress": true, "wrapper": "field-start-date-items", "selector": "#edit-field-start-date-field-start-date-add-more", "effect": "fade", "method": "replace", "progress": { "type": "throbber" }, "button": { "field_start_date_add_more": "Add another item" } } }, "teaserCheckbox": { "edit-teaser-js": "edit-teaser-include" }, "teaser": { "edit-teaser-js": "edit-body" }, "tableDrag": { "field_start_date_values": { "field_start_date-delta-order": [ { "target": "field_start_date-delta-order", "source": "field_start_date-delta-order", "relationship": "sibling", "action": "order", "hidden": true, "limit": 0 } ] } } });</script>
    <!--[if lt IE 7]>
      <link type="text/css" rel="stylesheet" media="all" href="/themes/garland/fix-ie.css" />    <![endif]-->
  </head>
KarenS’s picture

Did you alter the jquery in core when you installed jquery update? If so, be sure you go back to the version that ships with core.

Other than that, your modules look pretty straightforward, but I'm not seeing this problem and no one else has reported it, so I still suspect a conflict with something else that is playing with javascript code.

Tony Sharpe’s picture

I have repeatedly tried a number of fresh downloads and installations of Drupal, all with just the bare minimum to get a date entry field up with date popup. In every case it has the problem as reported above.
I've tried latest released Drupal 6.3, Calendar beta 4, date beta 4 and CCK rc4 on local installation of php5.2.
I've tried latest dev release (as of Aug 8) of Drupal 6, Calendar, Date and CCK locally on php5.
I've tried complete fresh download and install of same latest dev release on shared server paid hosting under php4 with date php4 enabled, viewed from various different PCs on various different browsers.
The problem is always there. This last one is viewable at dma.technigrafix.co.uk, create content - event and click in the date field. Step on to October and I see Oct 26 twice. I've tried different time zone settings. Modules installed are just those mentioned. Modules enabled are content, menu, update status, date, date api, date php4, date popup, date timezone.
Deeper access can be provided if required. It's all a bit of a mystery!

KarenS’s picture

I still see no other reports like this, it is likely something in your setup. Try disabling everything but core, CCK and Date and see if your problem goes away. If so, re-enable one other module at a time and keep testing to try to figure out where the conflict is.

Tony Sharpe’s picture

That's virtually all I had anyway. Now all I have enabled is core, Content from CCK, Date, Date PHP4 (on my remote php4 installation but not local), Date popup and date timezone from the Date module. If I ever get some combination that doesn't give the problem then I'll happily track down what causes the problem to appear but I can't get to that elusive starting point and there's nothing left to disable!

KarenS’s picture

Have you tried different browsers? What effect does that have?

Tony Sharpe’s picture

Yes - tried various different browsers.
Oct 26 is the date that we return to GMT from BST (I am in the UK). My current time zone is GMT+1 (Europe/London). So this somehow relates to BST/GMT. I've also noticed that my calendar is showing events one day early up until Oct 26, then it is correct from then on, both before and after Dec 1 when the popup date entry corrects itself (Dec 1 has no relation to BST/GMT change ). This is based on assuming that when a previously entered date is displayed in a content type date field that it is correct and unrelated to how it was created eg date popup or drop down lists and this certainly seems correct assumption. I've only mentioned the calendar issue here as it perhaps relates. I will do more investigation around time zone settings and add more or raise issue under calendar if it still exists. I did do a lot of time zone adjustments when trying to get the date popup to work but I can be more focussed on that now.

Tony Sharpe’s picture

Further details of calendar DST issue are at http://drupal.org/node/293476 but the popup date entry went wrong whatever the time zone.

kmadel’s picture

Version: 6.x-2.0-beta4 » 6.x-2.0-rc1
Priority: Normal » Critical

I actually have a case where for 2008 November has two November 2nd's and for 2009 it has 2 Nov. 1st's, 2010 has 2 Nov. 7th's. It appears that the first full week of dates for November repeats the first date and throws the rest of the calendar off by a day.

I did have the following modules enabled, but have since disabled them and still have the same issue with the Date Popup:

Collapsiblock 6.x-1.x-dev
Javascript tools 6.x-1.0

Other modules that may be causing the conflict are (and that I haven't yet disabled) are:

Nice Menus 6.x-1.x-dev
Web Links 6.x-1.0-beta4
Wysiwyg Editor 6.x-1.x-dev

I will checked the issue ques for those projects.

Tony Sharpe’s picture

I don't have any of those modules installed but have the problem still. What time zone are you in?

kmadel’s picture

Title: Date picker popup has two October 26 » Date picker popup duplicates date for first full week of November

America/New York

I just updated to Drupal 6.4 and the problems is still there.

KarenS’s picture

That popup calendar is all javascript, so it's getting its values from your browser and running on the client. It doesn't even use timezones, so that's not the issue. The only thing that is controlled are the day of week and month names we pass in and the indicator of what the first day of the week is. If those are wrong, there would be problems. You can see what we are passing in if you look at the source js code, like in #3 above. If those values are right, that's not the issue.

The only thing I can think of is some kind of problem between the version of jQuery in core and the datepicker jquery code, but I'm using the default core jquery code with no problem. Is there any chance the people reporting this have something other than the version of jquery that ships with core? Are you using the jQuery UI module or anything else other than the same jquery you get in core?

If you can, try creating a brand new test installation with nothing but Drupal core, CCK, and Date, and see if the popup works right there.

This is a javascript/jquery problem and I'm not sure what else to try.

There are other things in this issue than the popup calendar. The way dates look in the regular calendar or the way dates are saved in the node are unrelated, and have nothing to do with jquery.

KarenS’s picture

Also, if you have any way to do so, try the Date Popup that ships with the D5 version and see if it has the same problem. If nothing else, I can switch back to that version (but I'd rather not because it's outdated).

[Edit] I mean try it in a D5 installation, I don't mean try to put it into the D6 code.

Tony Sharpe’s picture

Still the same problem. I created brand new installation core 6.4, cck rc6, date dev latest. Left the selection of core modules enabled as default. Enabled Content, date, date api, date popup and date time zone. Set time zone to Europe/London, created content type with added date field as 'date' with date popup.
This is page source header from the create content page where the popup comes up.

"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">


Create test | tr3

jQuery.extend(Drupal.settings, { "basePath": "/", "datePopup": { "edit-field-strt-0-value-datepicker-popup-0": { "func": "datepicker", "settings": { "prevText": "\x26lt;Prev", "nextText": "Next\x26gt;", "currentText": "Today", "clearText": "Clear", "closeText": "Close", "firstDay": 0, "dayNames": [ "Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday" ], "dayNamesShort": [ "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat" ], "dayNamesMin": [ "Su", "Mo", "Tu", "We", "Th", "Fr", "Sa" ], "monthNames": [ "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December" ], "monthNamesShort": [ "Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec" ], "autoPopUp": "focus", "closeAtTop": false, "speed": "immediate", "dateFormat": "mm/dd/yy", "yearRange": "-3:+3", "fromTo": false } } }, "teaserCheckbox": { "edit-teaser-js": "edit-teaser-include" }, "teaser": { "edit-teaser-js": "edit-body" } });
KarenS’s picture

OK, now I'm seeing it too. The bug is not in the older version used in D5, it's in the newer version that comes from jQuery UI. I'll have to see if there's an updated one that works right.

KarenS’s picture

Status: Postponed (maintainer needs more info) » Fixed

Turns out this is a reported issue in the jQuery UI issue queue. The bug is fixed, but only in the development version, so I updated to use that version in the Date Popup.

I just committed this change.

Tony Sharpe’s picture

Great. Working for me now, thanks.

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.