浏览器如何发送Post请求

Google浏览器,F12,进入Console
输入如下代码
// 按住shfit+Enter,可以下一行继续,不要直接Enter
var xhr = new XMLHttpRequest(); // 向logout接口发起post请求,是异步的 xhr.open("POST", "/logout", true); xhr.send();

Google浏览器,F12,进入Console
输入如下代码
// 按住shfit+Enter,可以下一行继续,不要直接Enter
var xhr = new XMLHttpRequest(); // 向logout接口发起post请求,是异步的 xhr.open("POST", "/logout", true); xhr.send();