| Issue 61: | Adding events to a different month (hard coded) | |
| 1 person starred this issue and may be notified of changes. | Back to list |
this may be a dumb question, but I cannot add events to a different month. It works for FF and
safari but not IE. This is an example of an Event I added:
$('#calendar').fullCalendar({
draggable: false,
events: [
{
id: 1,
title: "Test Event",
start: new Date(2009, 07, 15)
}
- As you see I have the Year,Month,Date. Am I doing something wrong? Sorry but im a noob w/
Javascript.
Jul 23, 2009
Here is the code for the Cal, it still dosent work...
<script src="js/jquery-1.3.2.min.js" type="text/javascript"></script>
<script type="text/javascript" src="js/ui.core.js"></script>
<script type="text/javascript" src="js/fullcalendar.js"></script>
<script type='text/javascript'>
$(document).ready(function() {
//var d = new Date();
$('#calendar').fullCalendar({
draggable: false,
events: [
{
id: 1,
title: "Test 1",
date: new Date(2009, 07, 04)
},
{
id: 2,
title: "Test 2",
date: new Date(2009, 07, 15)
},
{
id: 2,
title: "Test 3",
start: new Date(2009, 07, 16)
},
{
id: 3,
title: "Test 4",
start: new Date(2009, 08, 25),
end: new Date(2009, 08, 28)
},
{
id: 4,
title: "Test 5",
start: new Date(2009, 09, 3),
end: new Date(2009, 09, 5),
},
{
id: 5,
title: "Test 6",
start: new Date(2009, 09, 23),
end: new Date(2009, 09, 25)
},
{
id: 6,
title: "Test 7",
start: new Date(2009, 09, 30),
end: new Date(2009, 10, 1)
},
{
id: 7,
title: "Test 8",
start: new Date(2009, 10, 1)
},
{
id: 8,
title: "Test 9",
start: new Date(2009, 10, 6),
end: new Date(2009, 10, 9)
},
{
id: 9,
title: "Test 10",
start: new Date(2009, 11, 11),
end: new Date(2009, 11, 14)
},
{
id: 10,
title: "Test 11",
start: new Date(2009, 11, 14),
end: new Date(2009, 11, 16)
},
{
id: 11,
title: "Test 12",
start: new Date(2010, 0, 25),
end: new Date(2010, 0, 27)
},
{
id: 12,
title: " Test 13",
start: new Date(2010, 0, 22)
},
{
id: 13,
title: "Test 14",
start: new Date(2010, 0, 29),
end: new Date(2010, 1, 1)
},
{
id: 14,
title: "Test 15",
start: new Date(2010, 1, 5),
end: new Date(2010, 1, 8)
},
{
id: 15,
title: "Test 16",
start: new Date(2010, 1, 12),
end: new Date(2010, 1, 14)
},
{
id: 16,
title: "Test 17",
start: new Date(2010, 2, 5),
end: new Date(2010, 2, 7)
},
{
id: 17,
title: "Test 18",
start: new Date(2010, 2, 12),
end: new Date(2010, 2, 15)
},
{
id: 18,
title: "Test 19",
start: new Date(2010, 2, 19),
end: new Date(2010, 2, 22)
},
{
id: 19,
title: "Test 20",
start: new Date(2010, 2, 26),
end: new Date(2010, 2, 28)
}
]
});
});
</script>
Thanks for your help
Jul 23, 2009
Ok, it works now, I had 2 ids labeled "id:2" and for some reason it was not working. As soon as I changed the ids, it started working. Does anyone know how to run this on IE8? Its buggy until I select compatibility mode.
Jul 31, 2009
glad you got it to work. unique events need unique id's can you point me to an example of it not working in IE8? though i haven't done thorough testing for IE8, things seem to work pretty well after some cursory testing. can you be more specific about the buggy behavior? thanks a lot
Status:
Done
Aug 6, 2009
HI . I'm testing the fullcalenda on IE 7 and IE 8 and it's works well... |
|
| ► Sign in to add a comment |
Hi. can i have all your code.This is an example for calendar it's works on IE & FF... Maybe your problem it's the comma . for every event you must add a comma and the last event don't add a comma. This is an example events: [ { id: 1, title: "Test Event", start: new Date(2009, 07, 15) }, { id: 2, title: "Repeating Event", start: new Date(y, m, 2) }, { id: 2, title: "Repeating Event", start: new Date(y, m, 9) }, { id: 3, title: "Meeting", start: new Date(y, m, 20, 9, 0) }, { id: 4, title: "Click for Facebook", start: new Date(y, m, 27, 16), end: new Date(y, m, 29), url: "http://facebook.com/" } ] If you don't understand tell me... Good luck