This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm that you accept these cookies being set.

Object does not trigger a custom javascript
#1
Hello,

we want to reload a page by triggering a KNX object in Wiser for KNX, we reused a javascript that works fine on every device (so the code is fine) but in this case it doesn't work.

Javascript console has this warning:

DevTools failed to load source map: Could not load content for http://192.168.178.8/scada/resources/min...min.js.map: HTTP error: status code 404, net::ERR_HTTP_RESPONSE_CODE_FAILURE

we have a VPN and everything seems to work fine on that side, any ideas?

Thank you for your help.
Reply
#2
Paste all you have in custom JS
------------------------------
Ctrl+F5
Reply
#3
$(function(){
grp.listen('32/5/98', function(object, state) {
var value = object.value;
console.log("dopo listen");
if (value == 1) {
console.log("evento1");
const body = document.body;
body.click();
if (!localStorage.getItem("reload")) {
localStorage.setItem("reload", "true");
location.reload();
}
} else if (value == 0) {
console.log("evento2");
localStorage.removeItem("reload");
} else {
localStorage.removeItem("reload");
console.log("niente");
};
});
});

Smile We found the problem,

the script worked fine but on some browser the cache must be deleted.


Big Grin our bad, but thank you for your help.
Reply


Forum Jump: