0

我开始学习 html、css 和 nodejs,在编写了几个非常基本的网页之后,我尝试在我的计算机上运行它们,并在我的带有边缘的 xbox-one 上查看页面,但是对于每个页面(不管多么简单)它总是说“不支持应用程序,该网页试图启动一个应用程序,例如电子邮件程序,这在 xbox 上不受支持”。我尝试过使用 node html 库和 express 库,有无 html/css。

一个不能在 xbox 上运行的代码:server.js

var http = require('http');
var server = http.createServer(function (req, res) {
    res.writeHead(200, {"Content-Type": "text/plain"});
    res.end("hello world!");
})

var PORT = 1021;

server.listen(PORT);
console.log("Server is running on 192.168.0.15:", PORT, '\n');

我在网上找不到任何东西,所以任何帮助将不胜感激

4

1 回答 1

0

经过大量试验和错误后,我发现这是一个非常简单的问题,我将 192.168.0.15:12345 放入地址栏中,但它想要http://192.168.0.15:1021

于 2017-08-22T05:02:57.657 回答