jquery dialog 如何使用 validate
通过对话框方式 调用 iframe #_hotel ,保存save 方法 。同时 执行完回调handleOK.
请问jquery validate 如何执行。
$("#_hotel").dialog({
title: "编辑酒店",
autoOpen: false,
resizable: false, // 不可拖动改动大小
width: 450,
height: 600,
modal: true,
buttons: {
"保存":function(){
$("#hotelDialog")[0].contentWindow.save(handleOk);
//新增
function save(callback){
closeDialogCallback=callback;
$.ajax({
async:false,
cache:false,
contentType:'application/json',
type:"POST",
dataType:'json',
data:postData,
url:'../hotel/updatehotel',
error:function(data){
alert("操作失败");
return;
},
success:function(data){