main.js 799 B

12345678910111213141516171819
  1. (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
  2. (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
  3. m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
  4. })(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
  5. ga('create', 'UA-33096931-4', 'auto');
  6. ga('send', 'pageview');
  7. window.onload = function() {
  8. setTimeout(function() {
  9. var ad = document.querySelector("ins.adsbygoogle");
  10. if (ad && ad.innerHTML.replace(/\s/g, "").length == 0) {
  11. if (typeof ga !== 'undefined') {
  12. ga('send', 'event', 'Adblock', 'Yes');
  13. } else if (typeof _gaq !== 'undefined') {
  14. _gaq.push(['_trackEvent', 'Adblock', 'Yes']);
  15. }
  16. }
  17. }, 2000);
  18. };