diff --git a/html/index.html b/html/index.html
index ee0bc62..bfb1577 100644
--- a/html/index.html
+++ b/html/index.html
@@ -254,7 +254,7 @@
LEADERBOARD
var connection = null;
var serverUrl;
- serverUrl = "ws://" + window.location.hostname +":"+ (parseInt(location.port) + 100);
+ serverUrl = "ws://" + window.location.hostname +":"+ (parseInt(window.location.port) + 100);
connection = new WebSocket(serverUrl);
connection.onopen = function (evt) {