欧美bbbwbbbw肥妇,免费乱码人妻系列日韩,一级黄片

基于jQuery.Validate驗(yàn)證庫知識點(diǎn)的詳解

 更新時(shí)間:2013年04月26日 10:49:26   作者:  
本篇文章介紹了,基于jQuery.Validate驗(yàn)證庫知識點(diǎn)的詳解。需要的朋友參考下
1、如果設(shè)置了errorContainer、errorLabelContainer、wrapper,則errorPlacement不起作用
復(fù)制代碼 代碼如下:

...
  $(document).ready(function(){
    $("#myform").validate({
       errorContainer: "#messageBox1, #messageBox2",
       errorLabelContainer: "#messageBox1 ul",
       wrapper: "li",
       debug:true,
...

errorContainer: 可以配置多個(gè)容器,這里的messageBox2元素沒有被包裝處理,只是錯(cuò)誤發(fā)生的時(shí)候顯示和隱藏此元素

errorLabelContainer:顯示錯(cuò)誤信息的容器,根據(jù)校驗(yàn)結(jié)果隱藏或者顯示錯(cuò)誤容器。

wrapper: 顯示錯(cuò)誤信息的外層標(biāo)簽名稱.

errorElement: 指定顯示校驗(yàn)錯(cuò)誤信息的html標(biāo)簽名稱(默認(rèn)為label)

比如errorElement設(shè)置為span的情況

<SPAN class=checked htmlFor="cusername" generated="true"></SPAN>

相關(guān)文章

最新評論