- $(function(){
- $.formValidator.initConfig({formid:"myform",autotip:true});
-
- $("#name").formValidator({onshow:"請(qǐng)輸入客戶分類名稱",onfocus:"2到20個(gè)字符"}).inputValidator({min:2,max:20,onerror:"2到20個(gè)字符"}).ajaxValidator({
- dataType : "html",
- async : true,
- url : "${pageContext.request.contextPath}/clientSortSTManage/clientSortST!isEqualClientSortName.action",
- success : function(data){
- if(data=='true'){
- return true;
- }
- else{
- return false;
- }
-
- },
- buttons: $("#submit"),
- error: function(jqXHR, textStatus, errorThrown){alert("
- });
-
-
- })
}
標(biāo)題名稱:jqueryFormvalidatorAjax添加數(shù)據(jù)驗(yàn)證是否存在
文章轉(zhuǎn)載:
http://weahome.cn/article/jhdihs.html