xmlHttp.open('post', './UserServer', true);
xmlHttp.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
xmlHttp.send("type=1&userId=" + userId);
//send()方法参数传错也会报405,比如少了 '=' 或者 '&' 或者 setRequestHeader("Content-type", "application/x-www-form-urlencoded")
Java web 使用 AJAX POST方法405报错
于 2021-12-20 00:54:07 首次发布