Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

jquery fullcalendar plugin view more then 1 month at a time

I am using the fullcalendar plugin and would like to change it a little bit - I want the default to be month view , but able to scroll down and continue into the next month, does anyone know if there is an add on , or anyway to start going about editing the fullcalendar?

like image 548
Scott Selby Avatar asked Jun 24 '12 05:06

Scott Selby


2 Answers

There is no direct way in fullcalendar to show two months. for your requirement you need to merge fullcalnder with darepicker ahow one small datepicker above the fullcaleder and one click of datepicker call goto methode of fullcalendar to jump at requried date.

$(document).ready(function()
{     
    $("#datepicker" ).datepicker({

        numberOfMonths: 2,
        showButtonPanel: false,
        minDate:0,

        onSelect: function(dateText, inst) 
        {  
            selected_date = dateText;
            $('#calendar').fullCalendar('gotoDate',new Date(Date.parse(selected_date)));
        }
    });

});  
like image 175
Ganesh Bora Avatar answered Nov 15 '22 07:11

Ganesh Bora


You could accomplish as follows:

  1. Download the data and save the JSON in local storage or an array
  2. Create 2-3 divs for 2-3 calendars
  3. Load full calendar onto the divs-- setting the start date for each
  4. Keep the same data source for all

Like this:

Multiple FullCalendars on a single page

with options

like image 36
NoelHunter Avatar answered Nov 15 '22 08:11

NoelHunter