mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-01-31 12:49:34 +00:00
fhemweb.js: fix raw definition stuff (Forum #66313)
git-svn-id: https://svn.fhem.de/fhem/trunk@13319 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
090a423a21
commit
9fa9fe74ce
@ -1095,6 +1095,7 @@ FW_digestCgi($)
|
||||
$pv =~ s/\+/ /g;
|
||||
$pv =~ s/%([\dA-F][\dA-F])/chr(hex($1))/ige;
|
||||
my ($p,$v) = split("=",$pv, 2);
|
||||
$v = "" if(!defined($v));
|
||||
|
||||
# Multiline: escape the NL for fhem
|
||||
$v =~ s/[\r]//g if($v && $p && $p ne "data");
|
||||
|
@ -620,7 +620,7 @@ function
|
||||
FW_rawDef()
|
||||
{
|
||||
$("div.rawDef a").each(function(){ // Help on detail window
|
||||
var dev = FW_getLink(this).split(" ").pop();
|
||||
var dev = FW_getLink(this).split(" ").pop().split("&")[0];
|
||||
$(this).unbind("click");
|
||||
$(this).attr("href", "#"); // Desktop: show underlined Text
|
||||
$(this).removeAttr("onclick");
|
||||
@ -891,8 +891,9 @@ FW_longpoll()
|
||||
"×tamp="+new Date().getTime();
|
||||
query = addcsrf(query);
|
||||
|
||||
var loc = (""+location).replace(/\?.*/,"");
|
||||
if(typeof WebSocket == "function" && FW_longpollType == "websocket") {
|
||||
FW_pollConn = new WebSocket((location+query).replace(/^http/i, "ws"));
|
||||
FW_pollConn = new WebSocket((loc+query).replace(/^http/i, "ws"));
|
||||
FW_pollConn.onclose =
|
||||
FW_pollConn.onerror =
|
||||
FW_pollConn.onmessage = FW_doUpdate;
|
||||
|
Loading…
Reference in New Issue
Block a user