把两种方法分别放入两个function中:

 

代码
funcrion Insert(){
Ext.Ajax.request({
url:
'handler1.ashx?parm=List',
method:
'post', //传递到后台的方式,这种要带参数
success:function(){},
failure:
function(){},
params:
{
stu_id:add_panel.getForm.findFiedl(
"add_stu_id").getValue()
}
});
};

 

 

 

代码
funcrion Update(){
update_panel.form.submit({
url:
'handler1.ashx?parm=List',
method:
'get, //传递到后台的方式,这种不用带参数
success:function(){},
failure:function(){}
});
};

 

 

 

posted on 2010-08-11 23:20  guolebin7  阅读(644)  评论(0编辑  收藏  举报