From a157c1eeddf6c01d263f1471ae79c808c1693079 Mon Sep 17 00:00:00 2001 From: Thomas Kolb Date: Thu, 15 Feb 2024 22:44:45 +0100 Subject: [PATCH] visualizer: generalize websocket address --- visualizer/views/index.tpl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/visualizer/views/index.tpl b/visualizer/views/index.tpl index 0b95586..17ce168 100644 --- a/visualizer/views/index.tpl +++ b/visualizer/views/index.tpl @@ -146,7 +146,7 @@ * Websocket handling * *********************************/ - var ws = new WebSocket("ws://localhost:8080/websocket"); + var ws = new WebSocket("ws://" + window.location.host + "/websocket"); ws.onopen = function() { console.log("Websocket connected."); };