| Issue 1054: | Make addMonths a public function | |
| 1 person starred this issue and may be notified of changes. | Back to list |
You have the addDays function publically accessible and I was wondering if the addMonths function could be made publically accessible as well. This is a really handy function to use when displaying more than one month at a time.
For example if I have 6 divs with the class of ".calendar_month" then I can write the function to create the current month and the following 5 months. Example Code:
{{{
$('.calendar_month').each(function(index) {
// expensive, but fullCalendar screws with the date
var new_date = $.fullCalendar.addMonths(new Date(), index);
fullcalendar_options.month = new_date.getMonth();
fullcalendar_options.year = new_date.getFullYear();
// Because fullcalendar removes the event attribute each time
fullcalendar_options.events = get_student_data
$(this).fullCalendar(fullcalendar_options);
});
}}}
Aug 21, 2011
Project Member
#1
adamrs...@gmail.com
Status:
Done
|
|
| ► Sign in to add a comment |