CMS & WordPress
I'm not sure what change I need to make where but here's my problem:
I have a D6 site using CCK, Views, etc. But it's also using this cool module called "fullcalendar" (it's similar to "calendar" but in my opinion, better). Anyway, I have a content type that has nodes which use CCK to output an app version update field value on a page (the content type deals with updating software to keep tabs on when a given app is updated last, etc. Simply put, it's a page / node that helps our software guys keep track of when a given app is last updated.)
One of the pages we created had an original date / time being output with the following value:
Tuesday, July 10, 2012 - 9:00am
After going into the fullcalendar day view to drag this time entry an hour into the future (same day, same date, year, etc; just an hour adjustment), we then had the following value on the page:
Wednesday, December 31, 1969 - 7:32pm
WTF!? Ha. Obviously, something is wrong here...
I doubt I'll get help with this specific module on here, however, I'm hoping someone can guide me into where to start. For example, in the module file, I tried to do a var_dump() of a variable just to start some investigating, but that didn't work (not surprisingly). How can I begin to debug / test variables in its code to see where the issue is coming from? How is this normally done? What do I need to do to fix this? I really want to use this AWESOME module but this date / time problem is giving me a headache and I know I could fix it if I can just figure out where the issue is coming from...
The 'December 31, 1969' date indicates that the date module has can't figure out what the date it is trying to interpret is and is showing a date prior to the beginning of time which for Unix was sometime just before Jan 1, 1970.
I've found that any module that depends on Date, particularly in D6, will be sensitive the the version of PHP that you are running. I don't recall where the version cutoff is but I've found that if PHP5 is too old it can cause trouble but also I had trouble when I shifted up to a newer version. This was with the regular calendar module though. You can try a trick to get things synched by adding the following line to the top of settings.php:
Have you used the Dev module to identify the fullcalendar objects? I've also found that the Drupal Firebug plugin and module can be handy for times like this.
Edit: Also make sure that in site settings that you have a timezone set.
Thanks for the feedback, Andrew.
It appears that I do have a timezone set over in <site>/?q=admin/settings/date-time but I tried adding that php_ini suggestion despite this and it had no impact. I would like to do what you suggest regarding the devel module but I'm not sure how exactly to do it. From what little I understand about devel, you can use certain functions within your theme files to figure out certain things about variables but what exactly do you suggest with it? For example, how would I figure out everything I need to know about the fullcalendar objects by using devel? What functions would I use, concepts, etc.?
Hey no worries Wolf_22,
Have you looked at this thread: http://drupal.org/node/932854
I'm assuming your on D6 with this one... I wonder if the patch suggested in that thread (dated Nov 11, 2011) ever made it into production. The current version is from Nov 22, 2011 and it could be that it never got that patch. I would update to the Dev version and see if it cures the issue.
Regarding the Dev module, once installed you can move the dev tool to the footer block of your site and it will only load for you or anyone who has permissions to see it. You can load a page, click the Dev tool and expand/review everything that is loaded, including dates and other objects.
The Firebug for Drupal module is similar and maybe even better. You have to have it active within Firefox and active on the site. Then Firebug will have a new tab along the top of the firebug screen which will allow you to load and review every piece of data that is accessible in the node.
This topic is now closed. New replies are no longer allowed.