node+socket.io的简单聊天室
发布于 2年前 作者 thesadboy 3275 次浏览

基于Node和socket.io的简单聊天室,欢迎拍砖,实现了上下线广播,一对多一对一聊天,功能很少,连用户管理都没有做,登录界面直接输入用户名即可(同名的会被覆盖的,囧),只是学学socket.io和node。 源码: https://github.com/thesadboy/ChatRoom.git 预览地址: http://node-chatroom.ap01.aws.af.cm/ –新增上下线/点对点消息声音提醒。

5 回复

Cannot POST /signup

Request Headersview parsed
POST /signup HTTP/1.1
Host: node-chatroom.ap01.aws.af.cm
Connection: keep-alive
Content-Length: 34
Cache-Control: no-cache
Pragma: no-cache
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Origin: http://node-chatroom.ap01.aws.af.cm
User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.30 (KHTML, like Gecko) Chrome/26.0.1403.0 Safari/537.30
Content-Type: application/x-www-form-urlencoded
Referer: http://node-chatroom.ap01.aws.af.cm/signup
Accept-Encoding: gzip,deflate,sdch
Accept-Language: zh-CN,zh;q=0.8,zh-TW;q=0.6
Accept-Charset: UTF-8,*;q=0.5
Form Dataview sourceview URL encoded
username:jiyinyiyong
username:node
Response Headersview parsed
HTTP/1.1 404 Not Found
Accept-Ranges: bytes
Age: 0
Content-Encoding: gzip
Content-Type: text/plain
Date: Fri, 22 Feb 2013 09:52:29 GMT
Server: nginx
Vary: Accept-Encoding
Via: 1.1 varnish
X-Powered-By: Express
X-Varnish: 2086511932
Content-Length: 45
Connection: keep-alive

应该是能用的哦,可能是服务不稳定吧?

很好的教程啊

好东西,研究一下,最近正打算给火星问答添加聊天室和实时问答应用呢

回到顶部