var http = require("http");
http.createServer(function (request, response){
response.writeHead(200, {'Content-Type': 'text/plain'});
response.end('hello suneha\n');
}).listen(8081);
console.log('server running at http://127.0.0.1:8081/');
运行节点js program 1 时,ERROR在浏览器上被捕获
答案 0 :(得分:0)
以下是使用错误名称respponse
的问题,应该是response.
http.createServer(function (request, response){
答案 1 :(得分:0)