Fullcalendar jquery plugin Show years on nextYear buttons

Posted by Nathan Neff on Stack Overflow See other posts from Stack Overflow or by Nathan Neff
Published on 2010-05-14T16:46:07Z Indexed on 2010/05/17 0:40 UTC
Read the original article Hit count: 403

Filed under:

I'm using the fullcalendar jquery plugin, and would like to display 2009 and 2011 in the nextYear and prevYear buttons.

For exmaple:

2009 May 2010 2011

I know I can put static text on the buttons like this:

buttonText: { prevYear: '2009', nextYear: '2011' },

But I would like those years to change, depending on the year that the calendar is currently viewing. There's documentation about 'year' here: http://arshaw.com/fullcalendar/docs/current_date/ but I don't know how to get that 'year' property.

Any examples would be appreciated,

Thanks,

--Nate

© Stack Overflow or respective owner

Related posts about fullcalendar