Skip to main content

Calendar API Overview

Methods#

NameDescription
clear()clears the value set in the calendar
destructor()removes a calendar instance and releases occupied resources
getCurrentMode()returns the current mode of displaying Calendar
getValue()returns the selected date
link()links a calendar to another calendar for selecting a date range
paint()repaints a calendar on a page
setValue()selects a date in the calendar
showDate()shows a specified date and/or opens the calendar in one of the available modes

Events#

NameDescription
beforeChangefires before the change of date selection
cancelClickfires when the user clicks on the "Cancel" control
changefires on change of date selection
dateMouseOverfires when the mouse pointer is over a date
modeChangefires on change of the calendar mode
monthSelectedfires after a month was selected in the calendar
yearSelectedfires after a year was selected in the calendar

Properties#

NameDescription
cssadds style classes to Calendar
datedefines the date that will be opened when the calendar is created
dateFormatdefines the format of dates in Calendar
disabledDatesallows disabling some date intervals, day labels are dimmed
markadds a CSS class to specific days
modethe mode of Calendar initialization
rangeenables/disables the possibility to select a range of dates on the calendar
thisMonthOnlyhides dates of the previous/next months relative to the currently displayed one
timeFormatdefines the time format for a timepicker in the calendar
timePickeradds a timepicker into the calendar
valueselects the day (adds a round blue marker)
weekNumbersdefines whether to show the numbers of weeks
weekStartsets the starting day of the week
widthsets the width of the calendar