[jQuery] maskedinput plugin not cooperating with validate plugin?
My project uses jquery.maskedinput.js 1.2.2 and jquery.validate.js r6096. I'm looking at a date field, with a mask of 99/99/, which happens to also be required. If I focus and then blur on the required date field, validate fires (as it should), and does its required check, which (if I'm reading this properly) consists of a length check on the date textfield. Problem is, the 'value' of the date textfield is the format mask text itself, '__/__/', with a length of 10, so validation passes. Is there a prescribed way (short of my hacking jquery.validate.js) for validate and maskedinput to play nicely together? Say, for validate to return false if the required field's value matches the mask applied to it? I'm trying to use maskedinput's completed:function() to test and zap the data, but it's not firing properly just yet. Thanks much for any help / clarification / workarounds! Mark
[jQuery] maskedinput and $;ajax
Hi all, (I dont know if the last mensage was correctly sent) I trying aply masks in one form, the mask stay in the same page of the form. This form is loaded by $.ajax function. If I understand correctly, the mask need be declared on document.ready state. So, my form does not work. how can I solve this? Thx a lot!!
[jQuery] MaskedInput
Hello, I am applying a masked input to an input as follows: jQuery(function($) { $(#UpdatedAt).mask(-99-99 99:99:99); }); How can I apply the same mask to various inputs without needing to rewrite the code? I tried the following but it did not work: // Form mask jQuery(function($) { $(#UpdatedAt, #CreatedAt).mask(-99-99 99:99:99); }); Thanks, Miguel
[jQuery] maskedinput multiple mask characters not working
When using the maskedinput plugin, using single masked character works fine: $(#date).mask(99/99/); //the / are mask characters and are ignored by the plugin. and double mask characters work fine at the end of the input: $(input.childAge).mask(99Y 99Mo); //also works fine. But when you have 2 consecutive mask characters internally, it causes the input to erase when it loses focus: $(input.childAge).mask(99Yr 99Mo); erases when loses focus (in ie6,anyway). It may not be worth changing the logic, because you can easily use 99Y 99Mo, but it was kind of a frustrating process figuring out why it wouldn't work as anticipated, so I thought I would post in case anyone else has the problem. Eric