JS 验证框架 formcheck
时间:2010-11-16 来源:天纯蓝
$(document).ready(function(){
new FormCheck('formular');
});
代码 $(document).ready(function(){
new FormCheck('formular',
{
submitByAjax:true,
onAjaxSuccess:onajaxsuccess
});
function onajaxsuccess(arg){
if(arg==1){
ymPrompt.succeedInfo({title:'消息',message:'添加成功!'});
$("form")[0].reset();
}else{
ymPrompt.errorInfo({title:'消息',message:'添加失败!'});
}
setTimeout(function(){ymPrompt.doHandler('ok')},2000);
}
});
下载
相关阅读 更多 +