From b238339ffb4b02617c91c5e508871e85cfa844c0 Mon Sep 17 00:00:00 2001 From: Dario Ernst Date: Wed, 28 Dec 2016 19:59:14 +0100 Subject: [PATCH] client now working and connecting right host --- client/index.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/client/index.html b/client/index.html index 8e27a2d..914a1f3 100644 --- a/client/index.html +++ b/client/index.html @@ -10,7 +10,7 @@ - + @@ -142,7 +142,7 @@ // Socket stuff var socket; var connect = function() { - socket = new WebSocket('ws://192.168.1.42:8000'); + socket = new WebSocket('ws://'+window.location.hostname+':8000'); socket.onmessage = function(event) { console.log(event.data); var serverMessage = JSON.parse(event.data);