Fullcalendar get start and end date by click event

Fullcalendar get start and end date by click event

In this post we will give you information about Fullcalendar get start and end date by click event. Hear we will give you detail about Fullcalendar get start and end date by click eventAnd how to use it also give you demo for it if it is necessary.

I will share with you stick of how to get start and end date in fullcalendar js plugin. i will get start date and end date interval by using “getView” in full calendar js. We can also get start and end date by event of fullcalendar.

Yesterday i was working on my php laravel project and i require to write custom click event for next and previous button and load data by ajax. at that time i require to get start date and end date in my jquery file. i found way to get start and end date by using fullcalendar event.

We can get start date by getView event with intervalStart.

We can get end date by getView event with intervalEnd.

You can see here very simple way to get date:

$('#calendar').fullCalendar('getView').intervalStart

$('#calendar').fullCalendar('getView').intervalEnd

Now you can see my event code with proper format:

Also see:Jquery Redirect to Another Page After 5 Seconds Example

$('.fc-next-button').click(function(){

var month = $('#calendar').fullCalendar('getView').intervalStart.format('MM');

var year = $('#calendar').fullCalendar('getView').intervalEnd.format('YYYY');

});

I hope it can help you…

Hope this code and post will helped you for implement Fullcalendar get start and end date by click event. if you need any help or any feedback give it in comment section or you have good idea about this post you can give it comment section. Your comment will help us for help you more and improve us. we will give you this type of more interesting post in featured also so, For more interesting post and code Keep reading our blogs

For More Info See :: laravel And github

Leave a Comment

Your email address will not be published. Required fields are marked *

9  +  1  =  

We're accepting well-written guest posts and this is a great opportunity to collaborate : Contact US