2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-01-31 06:39:11 +00:00

fhemweb.js: user replace instead of replaceAll (Forum #77432)

git-svn-id: https://svn.fhem.de/fhem/trunk@23282 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
rudolfkoenig 2020-12-02 21:44:45 +00:00
parent b5301df525
commit e1057e6d9b

View File

@ -309,11 +309,11 @@ FW_jqueryReadyFn()
$("#content > #workbench").html(data);
var mtype = $("#content > #workbench a[name]").attr("name"), aTag;
if(mtype) {
var mv = (mtype+""+val).replaceAll(/[^a-z0-9_]/ig,'_');
var mv = (""+mtype+val).replace(/[^a-z0-9_]/ig,'_');
aTag = $("#content > #workbench").find("a[name="+mv+"]");
}
if(!$(aTag).length) { // old style syntax without type
var v = (val).replaceAll(/[^a-z0-9_]/ig,'_');
var v = (val).replace(/[^a-z0-9_]/ig,'_');
aTag = $("#content > #workbench").find("a[name="+v+"]");
}
if($(aTag).length) {