Open GoogleCodeExporter opened 8 years ago
Victor, thanks, I understand what you are doing.
There is a simple solution to this. Just add the class name to the watermark
className option.
So let's say the class name you're applying to the password input is "myClass",
and you're using a standard class name for the watermark of "watermark".
Change the className option to "watermark myClass". That will apply both class
names to the text input element when it replaces the password type element.
That will get you going with the current version of the watermark plugin.
However, I'll keep this issue open and investigate the possibility of adding
the class names automatically.
Original comment by t...@speednet.biz
on 21 Jul 2011 at 10:41
I also ran into this problem when using the jQuery.validate.unobtrusive.js
plugin. I think this is an edge case though.
I have a wizard type of form, where each "page" of the wizard I validate the
input fields individually. I first remove the watermarks with hideAll() so the
required validate will function. Then validate, and finally show the
watermarks with showAll().
If the field is in error, a class of 'input-validation-error' is added. So,
the problem I am having is that the 'input-validation-error' class is erased
when the watermark is added.
I fixed the library in the _show function by copying the
'input-validation-error' class, if it exists on $input, to $pwd.
Thanks, Blair.
Original comment by BLe...@gmail.com
on 15 May 2012 at 5:16
Original issue reported on code.google.com by
victorbe...@gmail.com
on 21 Jul 2011 at 7:37