addMethod goes /outside/ of your document.ready() functionality. Just
figured that one out myself. :-)
$.validator.methods.equal = function(value, element, param) {
return value == param;
};
$(function() {
$validator = $("#myform").valida
> It could be related to a different issue that I solved
> recently. Could
> you give the latest revision a try?
> http://dev.jquery.com/view/trunk/plugins/validate/
I grabbed the latest version and still no luck... A few dumb questions:
Where do I place the addMethod:
$().ready(function(
Priest, James (NIH/NIEHS) [C] schrieb:
-Original Message-
From: Jörn Zaefferer [mailto:[EMAIL PROTECTED]
Sent: Wednesday, March 26, 2008 2:33 PM
To: jquery-en@googlegroups.com
Subject: [jQuery] Re: [validate] need help with addMethod
Priest, James (NIH/NIEHS) [C] schrieb:
Jörn
> -Original Message-
> From: Jörn Zaefferer [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, March 26, 2008 2:33 PM
> To: jquery-en@googlegroups.com
> Subject: [jQuery] Re: [validate] need help with addMethod
>
>
> Priest, James (NIH/NIEHS) [C] schrieb:
> >
Priest, James (NIH/NIEHS) [C] schrieb:
Jörn, the issue is it's not a checkbox :) It's a set of radio buttons: o yes
o no
The user must select 'yes' or they can't continue to submit the form.
Okay, if you want to stick with radio buttons for a boolean value,
please post a testpage with
> -Original Message-
> From: Jörn Zaefferer [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, March 25, 2008 2:05 PM
> > My method:
> >
> > $.validator.addMethod("checkyesno", function(value) {
> > if (value == 'Yes') {
> > return true;
> > } else {
> >
Priest, James (NIH/NIEHS) [C] schrieb:
Trying to add a new validation method to check a yes/no set of radio
buttons:
My method:
$.validator.addMethod("checkyesno", function(value) {
if (value == 'Yes') {
return true;
} else {
retur
7 matches
Mail list logo