Jorn?
On 5/23/07, Mandy Singh [EMAIL PROTECTED] wrote:
Okay I tried the following and that seems to work -
If I assign the validate class to suppose temp
then i can do -
if (mobile) {
temp.settings.messages['phone'] = mobile;
}
if (home) {
temp.settings.messages['phone'] = home;
}
Mandy Singh wrote:
Okay I tried the following and that seems to work -
If I assign the validate class to suppose temp
then i can do -
if (mobile) {
temp.settings.messages['phone'] = mobile;
}
if (home) {
temp.settings.messages['phone'] = home;
}
Just let me know if this is fine? Seems to work.
Jörn,
Thats is almost what I proposed in the blog comments:
|var messages = {
phone: Please select a phonenumber.
}
$(#myform).validate({
messages: messages;
});
$(#phoneType).change(function() {
messages.phone = Please fill in an appropriate + this.value +
number;
});
|
We could
Dan G. Switzer, II wrote:
We could potentially look at using a function callback to return a string
for the message as well. That certainly would be easier for development...
Great Dan! We have that pattern all over the place already anyway.
Thanks for the pointer!
--
Jörn Zaefferer
4 matches
Mail list logo