Surely many of you already know this great plugin (Masked Input Plugin from Josh Bush) to facilitate data entry forms by assigning a mask to facilitate the introduction of structured data.
![]()
The plugin works really well, but we think it was a major weak point for some types of data, in particular to enter dates. The eternal question of what value (month or day) should be first, depending on the language and the place where you are. To fix this we have slightly modified the plugin to accept a "placeholder" of more than one character and that will be displayed when editing the input until it is completed.
![]()
With this modification, the plugin accepts values of more than one character in the configuration parameter "placeholder"
$ ("#date").mask ("99/99/9999", {placeholder: 'dd/mm/yyyy'});
Here you can see an full example of use.
Original Plugin: http://digitalbush.com/projects/masked-input-plugin/
Modified plugin (source): jquery.maskedinput-1.2.2-co.js
Modified plugin (min): jquery.maskedinput-1.2.2-co.min.js



4 comments
No creo que para los mails sea tan sencillo, ya que los mails no tienen unas longitudes conocidas a priori, de forma que intentar aplicar la misma idea para un e-mail supondría modificar sustancialmente la forma en la que funciona el plugin.
¿Te animas a intentarlo tú Ricardo?
Me devuelves una pelota que primero te había tirado a ti!!
Esto si que es chasco para mi!! jajajajajajajaja