get value of tag after specific interval using TagSSI in html. - Printable Version +- Ewon Technical Forum (https://techforum.ewon.biz) +-- Forum: Development (https://techforum.ewon.biz/forum-50.html) +--- Forum: BASIC Script (https://techforum.ewon.biz/forum-52.html) +--- Thread: get value of tag after specific interval using TagSSI in html. (/thread-567.html) |
get value of tag after specific interval using TagSSI in html. - MadhuriSalunkhe - 09-04-2018 hi all, i designed a custom web page and show status of components with red and green color depending on its tags values. eg. i want to shows equipment 'Furnace Pump water starter' with its status. (i use small square to show status.) if any alarm tag of Furnace page has value 1 then square will shows in red else green. so, for above scenario, currently i use tagSSI to get tag value <%#TagSSI,FcePumpWD%> == 1 But it works only when page loaded for first time. if i change value of FcePumpWD to 0, then its not reflect on my custom page, still it insert old value only. and i don't want to refresh whole page. Following is my code:- var refreshStatus = setInterval(function(){ if ($("#divFCE1").html()== undefined) {} else { if (<%#TagSSI,FcePumpWD%> == 1) { $("#divFCE1").removeClass("squareGr"); //status shows in green colour $("#divFCE1").addClass("square"); // status shows in red colour } else { $("#divFCE1").removeClass("square"); $("#divFCE1").addClass("squareGr"); } } }, 6000); Plz guide me on the same. RE: get value of tag after specific interval using TagSSI in html. - simon - 10-04-2018 If you do not want to refresh the page, you have to use AJAX in your webpage. See https://techforum.ewon.biz/thread-81.html |