我有一个AJAX的实例:
var postContent ="name=" + encodeURIComponent("xiaocheng") + "&email=" + encodeURIComponent("[email protected]");
xmlhttp.open("POST", "a.aspx", true);
xmlhttp.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
xmlhttp.send(postContent);
这里如果用get的话,只要Request["name"]即可获取,但是现在用的是POST,那么在a.aspx中如何获取传过来的参数值???
var postContent ="name=" + encodeURIComponent("xiaocheng") + "&email=" + encodeURIComponent("[email protected]");
xmlhttp.open("POST", "a.aspx", true);
xmlhttp.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
xmlhttp.send(postContent);
这里如果用get的话,只要Request["name"]即可获取,但是现在用的是POST,那么在a.aspx中如何获取传过来的参数值???
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货