Created
September 4, 2012 19:32
-
-
Save RicoP/3625430 to your computer and use it in GitHub Desktop.
Check if browser uses an adblocker
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
window.usesNoAdBlocker = true; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<html> | |
<body> | |
<script type="text/javascript" src="advertisement.js"></script> | |
<script> | |
if("usesNoAdBlocker" in window) { | |
alert("Cool. You are supporting this site :)"); | |
} | |
else { | |
alert("Would be realy great if you could support this website."); | |
} | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment