我有在我的计算机上本地运行的学习储物柜,我想在外部网站中显示语句,这很容易使用仪表板,因为可以选择将链接放入 iframe,但是当我这样做时与声明的部分相同,它说 ip(学习储物柜)已阻止访问,因此我尝试将语句转发到创建为的 node.js 服务器:
const http = require('http');
const { parse } = require('querystring');
const server = http.createServer((req, res) => {
if (req.method === 'POST')
{
console.log(req);
}
});
server.listen(8090);
但是当我查看 req(传入消息)并且它显示为空时,我有一些字段作为标题:
headers:
{ accept: 'application/json, text/plain, */*',
'content-type': 'application/json',
'x-experience-api-version': '1.0.0',
'user-agent': 'axios/0.18.1',
'content-length': '532',
host: 'IP_ADDRESS:8090',
connection: 'close' },
rawHeaders:
[ 'Accept',
'application/json, text/plain, */*',
'Content-Type',
'application/json',
'X-Experience-API-Version',
'1.0.0',
'User-Agent',
'axios/0.18.1',
'Content-Length',
'532',
'Host',
'IP_ADDRESS:8090',
'Connection',
'close' ],
但是没有正文,也没有与该声明相关的内容。