2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-03-04 05:16:45 +00:00

JSonp newline patch from Joerg

git-svn-id: https://svn.fhem.de/fhem/trunk@2140 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
rudolfkoenig 2012-11-19 06:58:53 +00:00
parent b6da2e532d
commit 66db19d1ae

View File

@ -509,6 +509,8 @@ FW_answerCall($)
$FW_RETTYPE = "text/plain; charset=$FW_encoding";
if($FW_jsonp) {
$FW_cmdret =~ s/'/\\'/g;
# Escape newlines in JavaScript string
$FW_cmdret =~ s/\n/\\\n/g;
FW_pO "$FW_jsonp('$FW_cmdret');";
} else {
FW_pO $FW_cmdret;