web-server:用JavaScript编写的Web服务器

时间:2021-04-08 02:42:34
【文件属性】:
文件名称:web-server:用JavaScript编写的Web服务器
文件大小:2KB
文件格式:ZIP
更新时间:2021-04-08 02:42:34
JavaScript 网络服务器 用JavaScript编写的Web服务器。 运行服务器:“ node webserver.js” 要在服务器运行后连接到服务器:“ telnet localhost 9999” You should see the server log "Listening" 返回运行telnet的终端:“ GET /test.txt HTTP / 1.1” This returns a 200 ok because the file "test.txt" exists in the server's directory. "GET /testing.txt HTTP/1.1" This returns a 404 Not Found because "testing.txt" does not exist in the server's directory.
【文件预览】:
web-server-main
----.gitignore(2KB)
----README.md(495B)
----test.txt(3B)
----webserver.js(791B)

网友评论