Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7609227
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T01:07:19+00:00 2026-05-31T01:07:19+00:00

I have a an application built with the jQuery based fullCalendar http://arshaw.com/fullcalendar/ My calendars

  • 0

I have a an application built with the jQuery based fullCalendar
http://arshaw.com/fullcalendar/

My calendars events are loaded by an Ajax call that outputs JSON, it is configured to have Monday as the first day of the week and the default view is week.

It has been working fine, but I noticed that if I go forward to week 13 (beginning March 26th) the events are not loading properly. I figured straight away this must have something to do with daylight savings time changing which happens March 25th.

When I use the click on the next/prev buttons the calendar makes an ajax call using automatically generated start and end times, my php script on the background takes the start date calculates the week no and calls all the events in my database for that week.

For example on week 12 teh following variables are passed:

?start=1332115200&end=1332716400&_=1331237729591

PHP script:

$week_no = date('W', $_GET['start']);

Which works out as week no 12.

However the following week the variables passed are:

?start=1332716400&end=1333321200&_=1331238038820

$week_no = date('W',$_GET['start']); == 12 // same as last week

Nn further examination

echo date("C",1332115200);    // == 2012-03-19T00:00:00+00:00
echo date("C",1332716400);    //2012-03-25T23:00:00+00:00 (1 hour short of being in week 13)

So obviously teh daylight change is causing the problem.

My question is, is this a problem with fullcalander or my PHP logic?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T01:07:21+00:00Added an answer on May 31, 2026 at 1:07 am

    First of all: I don’t know your code and your settings, so all I’m saying is pretty much a guess.

    If you’re systems are both set to UTC, there wouldn’t (shouldn’t) be a problem. The same goes for the correct usage of the JavaScript functions date.getUTC* (the fullCalendar does not use those) with a server set to UTC. But I think that only your server is actually set to UTC, while your computer is set to “Europe/London” or anything like that (that looks right now like UTC, because it is UTC+0 in the winter).

    That all results in the following situation: fullCalendar tries to calculate the timestamp for e.g. 1st July 2012 00:00:00 – because the computer is set to a timezone where at that date a DST applies (UTC+0 in the winter, UTC+1 in the summer -> 1st of July = UTC+1) you will get a timestamp for that moment in time where it is 00:00:00 on the 1st of July IN LONDON. Because their time is one hour in front of the UTC, you will get 23:00:00 if you interpret that timestamp relative to UTC – and that is, what the server does.

    A solution can be as simple as this:

    <?php
    date_default_timezone_set('Europe/London');
    

    That way, the server should interpret the timestamp relative to UTC+0 if the corresponding date is in the winter and relative to UTC+1 if it is in the summer.

    However, if the visitors timezone is set to something different e.g. “America/Los_Angeles”, your application is still messed up and won’t work as expected. The best way is usually to use UTC timestamps everywhere, but fullCalendar does not support that currently.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an ajax heavy web-application built using PHP, jQuery. I am looking for
I have a cakePhp application built, and now I'm creating a simple blog based
I have an application that is built against OpenSceneGraph (2.6.1) and therefore indirectly OpenGL.
I have a small ajax application built with php. Using phpMyAdmin I have set
I have an MVC 4 application that I'm localizing. All the built-in resourcing and
I am performing a jQuery .ajax() call that returns a List<string> of IP addresses
I have a web application built with jQuery Mobile and PHP (CodeIgniter framework). Now
I have an ASP.NET application that makes use of the built in validation controls.
I have a dynamic page built with jQuery. Html pieces are loaded from mustache
I have an application built with Phonegap and JQuery Mobile. Whenever the soft keyboard

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.