Needing jQuery Birth Date Picker

JavaScript and client side scripting.

Moderator: General Moderators

Post Reply
User avatar
volomike
Forum Regular
Posts: 633
Joined: Wed Jan 16, 2008 9:04 am
Location: Myrtle Beach, South Carolina, USA

Needing jQuery Birth Date Picker

Post by volomike »

Anyone know if there's a jQuery-based Birth Date Picker out there? I've seen the jQuery date pickers out there but they don't appear to fit our needs. I mean, I want someone to have 3 fields on their screen for month, day, and year. They type in numbers and it automatically knows to skip to the next field. If they type in letters in the month field, it shows a popdown list of months but when you choose it, it switches it to a numerical form and then pops you into the day field automatically. On blur of the month, day, or year fields, it validates them and shows an error above that field for a couple seconds and then the error fades away before clearing that field out and putting focus into that field. As you type in more than two digits in the date field, it automatically puts those digits in the year field. The day and year fields won't let you type anything but numbers in them. Once you have put in 4 digits on the year, the focus can be automatically assigned into a new field.

I could probably write this myself, but wanted to save time here and see if anyone had seen this already.
matthijs
DevNet Master
Posts: 3360
Joined: Thu Oct 06, 2005 3:57 pm

Re: Needing jQuery Birth Date Picker

Post by matthijs »

You describe such a specific situation, I can hardly imagine there's anything which does precisely that. Are you sure the situation you describe is the way you want it to behave? For a datepicker, I would :
- have a calendar icon, on click show the datepicker calendar from which a date can be chosen with one click (or keyboard access), or
- have a textfield, on focus show a datepicker calendar, or
- have a single textfield and let people type in the date in any format they want, have some creatrive validation and filtering to get out the correct format in your app, or
- have 3 separate text fields and just let them fill it in

I think with date inputs it's important to keep it simple. Maybe show an example date next to the input field to give a hint for the way people have to fill it in, and allow people to fill in multiple formats and do the work of correcting it to the correct format yourself (spaces to dashes for example).
Post Reply