fhemweb.js: fix get # and co (Forum #57562)

git-svn-id: https://svn.fhem.de/fhem/trunk@12171 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
rudolfkoenig
2016-09-18 16:28:54 +00:00
parent 2de1f62f0c
commit 723e5f0243

View File

@@ -157,7 +157,7 @@ FW_jqueryReadyFn()
} else if(val.match(/^\s*get\s+/)) {
// make get use xhr instead of reload
//return true;
FW_cmd(FW_root+"?cmd="+val+"&XHR=1", function(data) {
FW_cmd(FW_root+"?cmd="+encodeURIComponent(val)+"&XHR=1", function(data){
if( !data.match( /^<html>.*<\/html>/ ) ) {
data = data.replace( '<', '&lt;' );
data = '<pre>'+data+'</pre>';