Ajax中使用Post提交 中文及参数传递问题

1xmlhttp.open("post",url,true);
2//以下两行解决中文参数问题
3xmlhttp.setrequestheader("cache-control","no-cache"); 
4xmlhttp.setRequestHeader("Content-Type","application/x-www-form-urlencoded");
5//传递参数
6xmlhttp.send("name="+name);
posted @ 2007-03-21 10:27  樊凯  阅读(2717)  评论(0编辑  收藏  举报