Page 1 of 1

js domain using dash (-) bug

Posted: Sun Jan 15, 2017 9:48 pm
by base
I am running otmonitor daemon with a .nl domain with a dash ("-") in it, message.js and status.js fail, wsurl regexp returns null resulting in errors like "The URL 'wsnullmessage.ws' is invalid.",

var wsurl = "ws" + document.URL.match("s?://[a-z0-9.:/]+/") + "message.ws"
should be
var wsurl = "ws" + document.URL.match("s?://[a-z0-9.:/\-]+/") + "message.ws"

in docroot/message.js and status.js

Re: js domain using dash (-) bug

Posted: Sun Jan 15, 2017 11:04 pm
by hvxl
Correct, although you missed a few spots. See this topic.