Calendar Options

Go to the blog post
firstDayOfWeek

Specifies which day of the week should be the first one on the calendar (i.e. the left-most column).

Default: 0 (Sunday).

days

Array of strings defining the labels which are used for day names.

Defaults: ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"].

months

Array of strings defining the labels which are used for month names.

Default: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"].

alwaysShowLastRow

Determines whether the last row of the calendar should be displayed even if none of the dates in it belong to the current month.

Default: true.

allowWeekends

Determines whether weekends can be selected.

Default: true.

minimumDate

Determines the earliest date that may be selected (inclusive). Days prior to this date will be disabled.

Default: none

maximumDate

Determines the latest date that may be selected (inclusive). Days after this date will be disabled.

Default: none

onDateChange

Callback function to use when the selected date changes. The function will be given the selected date as a parameter.

Default: none

onDisplayChange

Callback function to use when the month on display changes. The function will be given the date indicating the month as a parameter.

Default: none

eventSource

Specifies a URL from which event information may be derived. If defined, the calendar will make a request every time the display month changes, passing the parameters month, year, and calendar. The calendar parameter will contain the id of the placeholder used to create the calendar.

The response should be a json object with the following properties:

status
Should always be "OK".
calendar
Should echo the calendar parameter from the request
events
An array of event objects.

An event object should be formed as follows:

date
The day for the event.
month
The month for the event.
year
The year for the event.
content
The actual event data. The default display function expects a single string, but depending on how this is overridden, any content may be used.

Default: none

eventFetchMode

The type of HTTP request to make when loading events.

Default: "POST".

eventSelectionHandler

A callback function to use when a cell containing an event is clicked. The callback should use $(this).data("event.data") to retrieve the event information.

Default: The default callback displays the event in an alert box.