Skip to content Skip to sidebar Skip to footer

Eventsources To Events Json, Full Calendar

I'm trying to get my json call from eventSources to my events. The json I get back in my eventSources is : [{'title':'Title Test','start':'1305841052'}] When I past this string i

Solution 1:

when you initialize the calendar, be sure to have the following:

$('#calendar').fullCalendar({
    event: "json-feed.php",
    //more inits...
})

your json-feed.php file should look similar to the following:

<?phpecho json_encode( array(
        array(
            'id' => 123,
            'title' => "myevent",
            'start' => "2011-05-24 10:05:00",
            'end' => "2011-05-24 11:55:00",
            'allDay' => false
         ),
         //more events...
     ));
?>

Post a Comment for "Eventsources To Events Json, Full Calendar"