jquery.validate Remote Validation notes
1.message must be written to the front, so that the message to display the custom prompt;
2.validate.aspx the page return value is True or False
1 <!DOCTYPE HTML ">2 <HTMLxmlns= "http://www.w3.org/1999/xhtml">3 <Head>4 <title>Validate Demo</title>5 <Scriptsrc= "Scripts/jquery-1.10.1.min.js"type= "Text/javascript"></Script>6 <Scriptsrc= "Scripts/jquery.validate.js"type= "Text/javascript"></Script>7 </Head>8 <Body>9 <formID= "MyForm">Ten <Div> One <inputtype= "text"name= "username"ID= "username"value= "Test Name" /> A </Div> - <Div> - <inputtype= "Password"name= "Password"value= "Test Password" /> the </Div> - <Div> - <inputtype= "text"name= "Email"value= "[email protected]" /> - </Div> + <Div> - <inputtype= "Submit"name= "Submitsss"value= "Submit" /> + </Div> A </form> at <Scripttype= "Text/javascript"> - $("#myForm"). Validate ({ - messages: {email: {Remote:"The mailbox has been registered! "} }, - rules: { - Email: { - Required:true, in Email:true, - Remote: { to URL:"validate.aspx", + Type:"Post" - } the } * } $ });Panax Notoginseng </Script> - </Body> the </HTML>
Jquery.validate Small Bet