Make easier to use demos, change to boot.js in further prep for long polling as an option

This commit is contained in:
David Botton 2021-01-31 19:58:19 -05:00
parent 18e617648f
commit 5237b518d4
8 changed files with 62 additions and 24 deletions

View file

@ -42,7 +42,7 @@ function Setup_ws() {
ws.onerror = function (event) {
console.log ("onerror: reconnect");
ws = null;
ws = new WebSocket (adr + "?" + clog['connection_id']);
ws = new WebSocket (adr + "?r=" + clog['connection_id']);
ws.onopen = function (event) {
console.log ("onerror: reconnect successful");
Setup_ws();
@ -56,7 +56,7 @@ function Setup_ws() {
ws.onclose = function (event) {
console.log ("onclose: reconnect");
ws = null;
ws = new WebSocket (adr + "?" + clog['connection_id']);
ws = new WebSocket (adr + "?r=" + clog['connection_id']);
ws.onopen = function (event) {
console.log ("onclose: reconnect successful");
Setup_ws();