";
if($FW_ss) { # FS20MS2 special: on and off, is not the same as toggle
my $webCmd = AttrVal($d, "webCmd", undef);
@@ -3207,6 +3209,13 @@ FW_widgetOverride($$)
+
+
confirmJSError
+ JavaScript errors are reported in a dialog as default.
+ Set this attribute to 0 to disable the reporting.
+
+
+
CORS
If set to 1, FHEMWEB will supply a "Cross origin resource sharing"
@@ -3944,6 +3953,14 @@ FW_widgetOverride($$)
+
+
confirmJSError
+ JavaScript Fehler werden per Voreinstellung in einem Dialog gemeldet.
+ Durch setzen dieses Attributes auf 0 werden solche Fehler nicht
+ gemeldet.
+
+
+
CORS
Wenn auf 1 gestellt, wird FHEMWEB einen "Cross origin resource sharing"
diff --git a/fhem/www/pgm2/fhemweb.js b/fhem/www/pgm2/fhemweb.js
index fdc003ca3..ca27ae0e1 100644
--- a/fhem/www/pgm2/fhemweb.js
+++ b/fhem/www/pgm2/fhemweb.js
@@ -35,7 +35,8 @@ window.onbeforeunload = function(e)
window.onerror = function(errMsg, url, lineno)
{
url = url.replace(/.*\//,'');
- FW_okDialog(url+" line "+lineno+":
"+errMsg);
+ if($("div#content").attr("data-confirmJSError") != 0)
+ FW_okDialog(url+" line "+lineno+":
"+errMsg);
}