Link to home
Start Free TrialLog in
Avatar of erikTsomik
erikTsomikFlag for United States of America

asked on

jquery remote validation

I am trying to validate the form using jquery remote validation. So the idea is I need to validate the field and check if the field is not already in the database. I got the remote call and it returns false but the form is still not submitting

<cfsavecontent variable="customRules">
      {
       onkeyup: false,
   
   onfocusout: false,
 rules: {
   
    Text:{
      required: true,
      remote: {
        url: "index.cfm&returnformat=json",
        type: "post",
        async:false,
        data:{'Text':function(){return $('#Text').val()},'ID':function(){return $('#ID').val()}}
       
        }
      }
      },
      messages:{
         Text:{remote: "Item Text is already in use." }
    }
}

</cfsavecontent>
ASKER CERTIFIED SOLUTION
Avatar of Rob
Rob
Flag of Australia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial