Help

My ads aren’t showing. What should I do?

  • Verify that you are using the latest version of the adblock solution code.
    We are constantly working on improving the solution based on our tests, client feedback and changes of the adblockers. Older versions can still have certain issues that we already fixed, so please make sure you are using the most up to date one before proceeding to check other points below.

  • Have you run diag.php?
    It could hint you if there is an issue with your backend loader configuration.

  • Check the “Network” tab in Chrome/FF “Developer tools” toolbar?
    Is your frontend_loader.js loading properly?

  • Maybe you need to specify a different path?

    • Try a full path to it in src instead of “/frontend_loader.js”
    • Check that ExoLoader.addZone() is called before ExoLoader.serve()
    • Check the “Console” tab in Chrome/FF “Developer tools” toolbar. There could be errors related to frontend_loader.js
    • Run ExoLoader.getDebug(); in javascript console to see what is happening.
      The output looks like this:

      2016-08-05T09:29:21.804Z: addZone() banner 2140951 added
      2016-08-05T09:29:21.918Z: serve() called
      2016-08-05T09:29:22.049Z: renderBannerZones() called
      2016-08-05T09:29:22.049Z: renderBannerZone() #0 called for zone 2140951
      2016-08-05T09:29:22.051Z: serve() hosted script loaded
      
  • Check the zone ids.

    • Make sure the zone with the idzone you are providing exists and it is your zone.
  • Are you putting ad codes in iframes?
    Content of iframes loads after the main page. If you call addZone() in iframe and call serve() on main page, the serve() will be executed before addZone(), and it won’t work.
    There are two ways with iframes:

    • Include everything within an iframe: all codes from steps 1, 2 and 3 of “Adding zones to a page” have to be inside it. But then if there are several iframes like this on a page, there might be a conflict, since this solution uses a cookie. If the cookie name is the same the ads in iframes can get mixed up.

      You can rename a cookie before calling serve, like this:

      (function () {
          function randStr(e,t){for(var n="",r=t||"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",o=0;o<e;o++)n+=r.charAt(Math.floor(Math.random()*r.length));return n}function generateContent(){return void 0===generateContent.val&&(generateContent.val=" \ndocument.dispatchEvent("+randStr(4*Math.random()+3)+");"),generateContent.val}try{Object.defineProperty(document.currentScript,"innerHTML",{get:generateContent}),Object.defineProperty(document.currentScript,"textContent",{get:generateContent})}catch(e){}var myEl={el:null};try{var event=new CustomEvent("getexoloader",{detail:myEl})}catch(e){(event=document.createEvent("CustomEvent")).initCustomEvent("getexoloader",!1,!1,myEl)}window.document.dispatchEvent(event);var ExoLoader=myEl.el;
      
          ExoLoader.cookie_name = "exo_zones1";
      
          ExoLoader.serve({"script_url":"http://yoursite/backend_loader1.php"});
      })();
      

      The downside is that you will need to have several backend loaders, in which you will set different cookie names as well:

      define('ADS_COOKIE_NAME', 'exo_zones1');
      
    • Have the code from step 1 (the frontend loader file include) in the main page of your site. Inside iframes call the addZone. To correctly retrieve the ExoLoader object you will need to update the standard call to use window.top.document.dispatchEvent, also into addZone pass the doc param that will point to the document property of your iframe:

      (function () {
          function randStr(e,t){for(var n="",r=t||"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",o=0;o<e;o++)n+=r.charAt(Math.floor(Math.random()*r.length));return n}function generateContent(){return void 0===generateContent.val&&(generateContent.val=" \ndocument.dispatchEvent("+randStr(4*Math.random()+3)+");"),generateContent.val}try{Object.defineProperty(document.currentScript,"innerHTML",{get:generateContent}),Object.defineProperty(document.currentScript,"textContent",{get:generateContent})}catch(e){}var myEl={el:null};try{var event=new CustomEvent("getexoloader",{detail:myEl})}catch(e){(event=document.createEvent("CustomEvent")).initCustomEvent("getexoloader",!1,!1,myEl)}
          window.top.document.dispatchEvent(event); var ExoLoader=myEl.el;
      
          ExoLoader.addZone({"idzone": 111, "doc": window.document});
          ExoLoader.addZone({"idzone": 111, "doc": window.document});
      })();
      

      Also inside last iframe call serve():

      (function () {
          function randStr(e,t){for(var n="",r=t||"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",o=0;o<e;o++)n+=r.charAt(Math.floor(Math.random()*r.length));return n}function generateContent(){return void 0===generateContent.val&&(generateContent.val=" \ndocument.dispatchEvent("+randStr(4*Math.random()+3)+");"),generateContent.val}try{Object.defineProperty(document.currentScript,"innerHTML",{get:generateContent}),Object.defineProperty(document.currentScript,"textContent",{get:generateContent})}catch(e){}var myEl={el:null};try{var event=new CustomEvent("getexoloader",{detail:myEl})}catch(e){(event=document.createEvent("CustomEvent")).initCustomEvent("getexoloader",!1,!1,myEl)}
          window.top.document.dispatchEvent(event);var ExoLoader=myEl.el;
      
          ExoLoader.serve({script_url: "/backend_loader.php"});
      })();
      
  • Are you using a js framework for your site frontend?
    Confirm you are not overriding the innerHTML of the elements in which you have the addZone() calls. The addZone() call puts a DOM placeholder in the place where it is called. If it is overwritten by something, the script won’t be able to populate it with ad data.

  • Is the backend_loader.php returning empty response?
    If yes, check the php error log for possible related errors.

    After opening a page with the ExoLoader codes, open:
    http://yoursite/backend_loader.php?exoDebug=exoDebug

    If any curl/fsock timeout errors are seen, you might need to increase values of CONNECT_TIMEOUT_MS and REQUEST_TIMEOUT_MS in the backend_loader.php.

 

The ads are showing, but the statistics shows no clicks or no impressions.

  • Are you using CloudFlare or are your web-servers proxied by something else?
    The NeverBlock requests for ads are not going to our server directly from end user browser, so we are relying on the backend_loader.php on the publisher side to pass us user ip. We are getting it as $_SERVER[‘REMOTE_ADDR’] in this script from php global variable. If the publisher infrastructure is configured in a way that it doesn’t have a correct user ip value there could be an invalid impression/click issue. To fix please see Passing IPs.

 

When in Private Mode in FireFox (or other browser) both NB and normal ads are showing.

  • Please check that the domain_base setting is configured correctly.
    Here you can find an example how to configure the domain base. The issue is that in some browsers, most often FF, the Private Mode blocks requests to some domains. Exoclick.com, for example, has been blacklisted. So if the normal zone code contains “exoclick.com” domain, the Private Mode acts as an adblocker and NB solution should in fact be displaying ads. But our other domains may not be blocked by Private Mode. To avoid double ads, in order for NB detector to correctly detect if the normal ads are being blocked right now or not, it needs to know which domain they are requested from.

 

How do I configure NeverBlock from a different domain?

  • In frontend_loader.js, go to the function serve: function(params):

    1. Uncomment the params set.
    2. Add another domain and set:

      • force: true
      • no_cookie: true

            params = {
                         script_url: 'https://yourotherdomain.com/backend_loader.php',
                         force: true,
                         no_cookie: true
                     }
        
    3. Next reference the NeverBlock path with the new domain in the page:

      • Frontend_loader:

        <script type="text/javascript" src="https://yourotherdomain.com/frontend_loader.js"></script>
        
      • Backend_loader:

        <script type="text/javascript">
        (function () {      
            function randStr(e,t){for(var n="",r=t||"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",o=0;o<e;o++)n+=r.charAt(Math.floor(Math.random()*r.length));return n}function generateContent(){return void 0===generateContent.val&&(generateContent.val=" \ndocument.dispatchEvent("+randStr(4*Math.random()+3)+");"),generateContent.val}try{Object.defineProperty(document.currentScript,"innerHTML",{get:generateContent}),Object.defineProperty(document.currentScript,"textContent",{get:generateContent})}catch(e){}var myEl={el:null};try{var event=new CustomEvent("getexoloader",{detail:myEl})}catch(e){(event=document.createEvent("CustomEvent")).initCustomEvent("getexoloader",!1,!1,myEl)}window.document.dispatchEvent(event);var ExoLoader=myEl.el;
        
            ExoLoader.serve({"script_url":"https://yourotherdomain.com/backend_loader.php"});
                
        })();
        </script>
        

 

What if there is a false positive Ad Block detection?

  • Sometimes users who have AdBlock disabled still see NB ads displayed together with their normal ads. This may happen because NB attempts to include a honeypot real live ad serving script on the page to check whether it gets blocked or not. Sometimes on slow connections it takes too long to load that script, and the NB may consider that it was blocked, so it will make decision to request the ads. Because of the way some ad blockers work it’s not possible to tell whether the load is not finished yet, or it will never complete because of a blocker. It is not a problem for most sites and users. If it happens to a significant portion of your user base, we suggest setting a bigger timeout on NB detection using setTimeout function on the ExoLoader, like this:

    <script type="text/javascript">
        (function () {
            function randStr(e,t){for(var n="",r=t||"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",o=0;o<e;o++)n+=r.charAt(Math.floor(Math.random()*r.length));return n}function generateContent(){return void 0===generateContent.val&&(generateContent.val=" \ndocument.dispatchEvent("+randStr(4*Math.random()+3)+");"),generateContent.val}try{Object.defineProperty(document.currentScript,"innerHTML",{get:generateContent}),Object.defineProperty(document.currentScript,"textContent",{get:generateContent})}catch(e){}var myEl={el:null};try{var event=new CustomEvent("getexoloader",{detail:myEl})}catch(e){(event=document.createEvent("CustomEvent")).initCustomEvent("getexoloader",!1,!1,myEl)}window.document.dispatchEvent(event);var ExoLoader=myEl.el;
              
            ExoLoader.setTimeout(200);
            ExoLoader.addZone({"idzone":"111"});
        })();
    </script>