Commit 41b71105 authored by 宿召阳's avatar 宿召阳

bug fix

parent d38a963d
......@@ -44,7 +44,9 @@ $.fn.webSocket = function(opt){
//告诉服务器端有用户登录
socket.emit('login', {userid:message.id, filename:message.filename});
socket.on('message',function(obj){
tag.append('<p>'+escapeString(obj.content)+'</p>');
//去除log中的颜色控制字符
var regx = /\x1B\[([0-9]{1,3}((;[0-9]{1,3})*)?)?[m|K]/g;
tag.append('<p>'+escapeString(obj.content.replace(regx,''))+'</p>');
});
return tag[0];
} ,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment