Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

After the mapping of your inventory's structure and creation of creating the accompanying positions, it is time to create and implement the Adhese ad tags. Ad tags are the basis of our technology and allow us to deliver and measure targeted campaigns.

...

The implementation method with JSON or JSONP makes it possible to bundle all advertisements in one request and visualize the creative in the right place. With this method, it is easy to take into account the moment when the creative has a true change to be seen, better known as viewability or in-view. This implementation method is the most suitable and favorable method favourable method to use in a responsive environment.

...

Code Block
<script src="http://ads.adhese.com/ad/jsonp/callback/sl_homepage_-leadboard/sl_homepage_-banner/sl_homepage_-skyscraper"></script>

The above script also allows you to simultaneously load all your ad creatives at once: the leaderboardthe leaderboard, banner and skyscraper ad. Next to this code, you still need a code that put the ads at in the right position.

Video integration with VAST

The Adhese Vast JS library is meant to ease the integration of VAST ads in video players. It contains cross-domain safe methods for requesting ads from your Adhese account as well as convenience and convenient methods for playing and tracking video ads. It is, however, not a player on its own, and it does not insert anything in the DOM.

  1. Load the JavaScript file:

    Code Block
    languagexml
    <script type="text/javascript" src="adhese-vast.js"></script>
  2. Create an AdheseVastWrapper object:

    Code Block
    languagejs
    var wrapper = new AdheseVastWrapper();
  3. Register a listener for the ADS_LOADED event fired by AdheseVastWrapper.  The The first parameter is the event name, ; the second is the name of your callback function. This function will be called when the wrapper is ready for handling for handling your ad request.

    Code Block
    languagejs
    wrapper.addEventListener("ADS_LOADED", yourCallBackFunction);
    
  4. Initiate a request for ads passing the host of your Adhese account and the sloth path and target parameters you wish to request.

    Code Block
    languagejs
    wrapper.requestAds("http://ads.demo.adhese.com", "_test_", ["preroll","postroll"]);
    
  5. Once the request is finished,  AdheseVastWrapper will will fire the ADS_LOADED event, and your callback function wil will be called.  From From then on, you can access several properties of the wrapper object to get info on the ads.

...

Adhese recommends the use of the IAB SafeFrame standard where possible. Adhese supports SafeFrame by default. To turn off, initialize your Adhese instance with the safeframe option set to false.

...