XMLHttpRequest对象使用“POST”方法,需要设置“setRequestHeader” var getjson = function(){ var xhr = new XMLHttpRequest(); xhr.open("POST","ajax.php",true); //post方法需要设置header头"setRequestHea... php 2023-10-19 56 点赞 0 评论 84 浏览