ddn2003 Posted December 9, 2014 Report Share Posted December 9, 2014 How can I block an embedded javascript on a page. function getQueryVariable(variable) { var query = window.location.search.substring(1); var vars = query.split("&"); for (var i=0;i var pair = vars.split("="); if(pair == variable){return pair;} } return(false); } var affid = getQueryVariable("affid"); var clickid = getQueryVariable("clickid"); var subid = getQueryVariable("subid"); var bannerid = "0"; The alert line changes every time the page loads. Link to comment Share on other sites More sharing options...
BugSir007 Posted December 9, 2014 Report Share Posted December 9, 2014 Hi ddn2003, Glad to talk to you. Actually Maxthon does not support blocking inline javascripts. A workaround ,complicated way, is to inject a js at the document start point with our extension system. That js should re-write the window.alert function if you want to block the alert. Link to comment Share on other sites More sharing options...
ddn2003 Posted December 9, 2014 Author Report Share Posted December 9, 2014 Thanks for the quick reply. I think that is a little above my head. Thanks for the tip nonetheless! Maybe this would be a good feature request? Link to comment Share on other sites More sharing options...
Recommended Posts