summaryrefslogtreecommitdiffstats
path: root/webchat/hello_web.js
diff options
context:
space:
mode:
authortv <tv@nomic.retiolum>2013-11-06 17:34:33 +0100
committertv <tv@nomic.retiolum>2013-11-06 17:34:33 +0100
commitf66bcf8e0527a1c08445ce0cbf327d5b20045b09 (patch)
tree2a74ccf1b218011febe5350544a8fbda2fd89515 /webchat/hello_web.js
parent38255554031cc8d0a52bd9e1731a0a873b3349c7 (diff)
parent7e68e86baf90dfe91abae7c4589091f089f8565b (diff)
Merge branch 'master' of https://github.com/krebscode/painload
Diffstat (limited to 'webchat/hello_web.js')
-rw-r--r--webchat/hello_web.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/webchat/hello_web.js b/webchat/hello_web.js
index e1f8f312..aa580652 100644
--- a/webchat/hello_web.js
+++ b/webchat/hello_web.js
@@ -3,7 +3,6 @@ var http = require('https');
var sockjs = require('sockjs');
var connect = require('connect');
var irc = require('irc');
-var krebsimage = require('./krebs-img.js');
var Clients = [];
Clients.broadcast = function(object) {
Clients.forEach(function(client) {
@@ -59,7 +58,7 @@ conn.write(JSON.stringify({from: 'system', message: 'hello'}))
var object = JSON.parse(message);
object.from = name
console.log(object.message);
- irc_client.say("#krebs", name + '→' + object.message);
+ irc_client.say("#krebs", name + ' → ' + object.message);
Clients.broadcast(object);
} catch (error) {
@@ -88,10 +87,11 @@ var app = connect()
res.write('<script src="sockjs-0.3.min.js"></script>');
res.write('<script src="jquery-2.0.3.min.js"></script>');
res.write('<script src="client.js"></script>');
- res.write(krebsimage+'<br>');
+ res.write('<div id=bg>');
res.write('hello, this is #krebs:<br>');
res.write('<table id="chatbox"></table>');
res.end('<input type="text" id="input"><br>');
+ res.write('</div>');
})
var server = http.createServer(options, app);