calendarLite plugin
In one of my projects, I needed a simple javascript calendar. But of the existing jQuery plugins, only one “almost” met my requirements. I decided to write my own plugin - a sample of the calendarLite plugin .

Features calendarLite:
You can specify the format of the link (for anchor), for example for this kind of link: http://snowcore.net/events/29–05–2009 This can be done using the linkFormat option
To click on a cell, you can set your own handlers. The callback function takes one value - the torn date. the onSelect option allows you to do this.
The optional dateFormat option allows you to set the date format to be passed to the callback function. The default value for dateFormat is '{% dd}. {% Mm}. {% Yyyy}'
Using other options (and styles), you can customize the appearance of the calendar:
Plugin homepage : calendarLite homepage
Project page on plugins.jquery.com: calendarLite plugin
You can download the plugin on Google Code: calendarLite

Features calendarLite:
- the calendar is designed to be constantly displayed on the page (not like different date pickers)
- Monthly navigation using the “Forward” and “Back” buttons
- flexible configuration (see options below)
Setting Link Format
You can specify the format of the link (for anchor), for example for this kind of link: http://snowcore.net/events/29–05–2009 This can be done using the linkFormat option
Possible 'linkFormat' options
- {% dd} - date with a leading zero
- {% d} - date without zero
- {% mm} - month with previous zero
- {% m} - month without zero
- {% yy} - year (two digits)
- {% yyyy} - full year (four digits)
- $('#cLinkFormat').calendarLite({
- linkFormat: 'http://snowcore.net/events/{%dd}-{%mm}-{%yyyy}'
- });
Defining your own callback function
To click on a cell, you can set your own handlers. The callback function takes one value - the torn date. the onSelect option allows you to do this.
The optional dateFormat option allows you to set the date format to be passed to the callback function. The default value for dateFormat is '{% dd}. {% Mm}. {% Yyyy}'
- $('#cCallback').calendarLite({
- dateFormat: '{%yyyy}-{%m}-{%d}',
- onSelect: function(date) {
- alert(date);
- returnfalse;
- }
- });
Customize Appearance
Using other options (and styles), you can customize the appearance of the calendar:
- showYear - if set to true, then the year is displayed at the top
- prevArrow and nextArrow - symbols for the buttons 'Previous' and 'Next'
- months and days - names of months and days (for multilingualism)
- $('#cStyle').calendarLite({
- showYear: true,
- prevArrow: '←',
- nextArrow: '→',
- months: ['January', 'February', 'March', 'April', 'May', 'June',
- 'July', 'August', 'September', 'October', 'November', 'December'],
- days: ['Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa', 'Su']
- });
Plugin homepage : calendarLite homepage
Project page on plugins.jquery.com: calendarLite plugin
You can download the plugin on Google Code: calendarLite