- independent of any 3rd party libraries
- working with keyboard navigation
- working with screen readers
- fast and as much as possible small file size
- simple to implement
The first, basic version of datepicker you can see and download at my lab section. There is still some limitations, but I will be updating as much as possible and improving this date picker.
Download and source code
The source code of date picker is available on Github now.
How to use it
All you need to do is to add class name
datepicker to your HTML
input element. Example:
<input class="datepicker" type="text" id="mydata" name="mydata" value=""/>
datepicker.js there is section named
/* Config */. There you can translate months, days, set arrows for next/previous month and many more. I’ll try to describe all settings on lab example page.
Don’t like UX design of date picker? No problem. Change CSS rules as you want 🙂
Yes, I like example. So, in that case you can see how it works. Just go to my lab and watch how date picker works.
The license I use MIT.
The date picker was tested on IE6 / Win XP, IE10 / Win7, Firefox 24 / Win7, Chrome 29.0.1547.76 m. / Win7, Firefox 22 / Ubuntu 13.04.
Feel free to contact with me and send me some suggestions / bugs.
marcel, 17 November 2014
beautiful little date picker… only one little problem the past year are not visible, what if I want to pick say… 2003, only 2014 forward are showing? if I go to previous months eventually the year does go reverse but it’s a slow process one month at a time, is there any way to fix? I went into the jscript file but looks like the only thing I can change is up to a certain year, default 2020,, can you point me in the right direction?
Cezary Tomczyk, 21 November 2014
Let me try to fix it.