From 97558e19820465ad6a71f1bd912f9e7412beb332 Mon Sep 17 00:00:00 2001 From: Kibi Kelburton Date: Tue, 24 Feb 2026 08:03:58 +0100 Subject: [PATCH] g --- public/embed.html | 6 +++--- public/index.html | 8 ++++---- public/viewer.js | 3 ++- 3 files changed, 9 insertions(+), 8 deletions(-) diff --git a/public/embed.html b/public/embed.html index 34aa326..f07d838 100644 --- a/public/embed.html +++ b/public/embed.html @@ -26,8 +26,8 @@ - - - + + + diff --git a/public/index.html b/public/index.html index 85db3c4..9a8f355 100644 --- a/public/index.html +++ b/public/index.html @@ -4,7 +4,7 @@ Screenshare - Viewer - +
@@ -17,8 +17,8 @@
- - - + + + diff --git a/public/viewer.js b/public/viewer.js index b2d8271..81689a7 100644 --- a/public/viewer.js +++ b/public/viewer.js @@ -1,4 +1,5 @@ -const socket = io(); +const basePath = window.location.pathname.replace(/\/[^\/]+\.[^\/]+$/, '').replace(/\/$/, ''); +const socket = io({ path: basePath + '/socket.io' }); const remoteVideo = document.getElementById('remoteVideo'); const overlay = document.getElementById('overlay');