How to handle the err_blocked_by_client using Javascript?
问题 My aim is to detect the ad-blocker. I found couple of good examples like FuckAdBlock. When the ad service call is blocked by the ad-blocked we get the error "err_blocked_by_client". I want to handle this error, in the following way : var xhr = new XMLHttpRequest(); try { xhr.open("GET","http://static.adzerk.net/ados.js", false); xhr.onreadystatechange = function (oEvent) { if (xhr.readyState === 4) { if (xhr.status === 200) { console.log(xhr.responseText) } else { console.log("Error", xhr