包括POST,GET,AJAX
前台调用
jQuery.post("NewDoAjax.aspx", { max: ' N !', name: 'wsenmin' }, function(data) { alert(data) });
jQuery.get("NewDoAjax.aspx", { max: ' B !', name: 'wsenmin' }, function(data) { alert(data) });
var superMan = "max=I am jq &name= it is ajax ";
jQuery.ajax({
type: "POST",
url: "NewDoAjax.aspx",
data: superMan,
success: function(msg) {alert(msg);}
});
C#代码:(将以下代码保存为NewDoAjax.aspx文件)