I have FullCalendar setup up correctly on my page and I am trying to get it to read a json source.
My json source works fine when I access it directly via the url, and if I copy the data outputted on screen and put this directly into the FullCalendar events, the event shows up.
Setting the events to the url of my json source just doesnt work. I have used Firebugs NET panel to inspect the call, and it is correctly locating the JSON source, and is fetching the correct data, but simply not showing it on the calendar.
I have set id, title, allday (to true) start (both unix and yyyy-mm-dd format) and end (despite this being optional)
Any ideas?
<script>
$(document).ready(function() {
$('#calendar').fullCalendar({
events: "eventsjson" // links to a controller in my symfony2 project. accessing cirectly gives correct json output
});
});
</script>
Data given by json source:
{"id":1,"title":"Test Event","start":1331309234,"allDay":true}
Inserting that ^^^ straight into the events setting work no problem. (the timestamp was generated by php's time() function)
"eventsjson"
is pseudo code, which is actually a valid URL on to a page on the same domain (http://sameDomain.com/feed.html
) in your real system? – JAAulde