dev.base86 and blog software © 2009 R. Schoo. All other copyrights are property of their respective owners.
Proudly powered by the lightweight MooTools JavaScript framework. Icons by FamFamFam.

A new version of my Vista-like Ajax Calendar (vlaCalendar) has been released:
version 2.1 is made compatible with MooTools installment, version 1.2, and offers some new features:
Documentation, examples, and the download are available here.
If you made a new style (theme) for the calendar and you want to share it, send it to rcz<at>base86.com. If you used the calendar and/or datepicker some where, I'd appreciate it if you'd let me know by adding a comment!
Update September 5, 2008: VlaCalendar version 2.1.1 released. Minor changes in the PHP code.
<?=
<?php
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="fr" >
<head>
<title>Welcome</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<script type="text/javascript" src="jslib/mootools-1.2-core.js"></script>
<script type="text/javascript" src="jslib/vlaCal-v2.1.js"></script>
<link type="text/css" media="screen" href="styles/vlaCal-v2.1.css" rel="stylesheet" />
<script language="javascript">window.addEvent('domready', function() {
new vlaDatePicker('exampleIV-B', { style: 'apple_widget', offset: { x: 3, y: 1 } });
});
</script>
</head>
<body>
<input id="exampleIV-B" type="text" style="width: 80px;" maxlength="10" />
</body>
</html>
new vlaDatePicker('example', { prefillDate: { day: 12, month: 12, year: 2012 } });
new vlaDatePicker('example', { prefillDate: false });
var vlac = new vlaDatePicker( 'agenda_date_debut', {
prefillDate: { day: 06, month: 10, year: 2008 },
filePath: '/vlaCalendar/'} );
$('agenda_date_debut').addEvent('blur', function(){vlac.hide();});
'filePath':'http://www.yoursite.com/inc/'
'filePath': 'lib/inc/'
case 'year': clickables.each(function(_clickable) { _clickable.onclick = function() { if(_class.selectMonth == 'true'){ var date = new Date(); date.setTime( parseInt(_clickable.getProperty('ts')) *1000 ); var pickable = { day: date.getDate(), month: date.getMonth()+1, year: date.getFullYear() }; _class.pick(pickable); }else{ _class.u('month', 'ts=' + _clickable.getProperty('ts'), function() { _class.fade() }) } } }); break;
pick: function(_date) { old_value = this.element.value; //new part
if(this.leadingZero) { if(_date.day < 10) _date.day = '0' + _date.day; if(_date.month < 10) _date.month = '0' + _date.month; } if(this.twoDigitYear) _date.year = _date.year.toString().substring(2, 4); if(this.separateInput) { if(this.element.day) this.element.day.set('value', _date.day); if(this.element.month) this.element.month.set('value', _date.month); if(this.element.year) this.element.year.set('value', _date.year); this.hide(); } else { switch(this.format) { case "m/d/y": this.element.set('value', _date.month + this.separator + _date.day + this.separator + _date.year); break; case "y/m/d": this.element.set('value', _date.year + this.separator + _date.month + this.separator + _date.day); break; case "y/d/m": this.element.set('value', _date.year + this.separator + _date.day + this.separator + _date.month); break; case "d/m/y": default: this.element.set('value', _date.day + this.separator + _date.month + this.separator + _date.year); } this.hide(); }
//new partif (this.onChangeFunction != '') { if ((old_value != "") && (old_value != this.element.value)) { eval(this.onChangeFunction); } } }
var vlaDatePicker = new Class({ Extends: vlaCalendar,
'separateInput': false,
'prefillDate': true,
'linkWithInput': true,
'leadingZero': true,
'twoDigitYear': false,
'separator': '/',
'format': 'd/m/y',
'openWith': null,
'alignX': 'right',
'alignY': 'inputTop',
'offset': { 'x': 0, 'y': 0 },
'style': '',
'ieTransitionColor' : '#ffffff', 'toggleDuration': 350,
'onChangeFunction':'', 'selectMonth':'false',
.vlaCalendar .arrowLeft, .vlaCalendar .arrowRight {
background: transparent url('/layout/images/vlaCal/arrowleft.gif') no-repeat center;
height: 12px; width: 10px;cursor: pointer;
position:relative;
}