Additional functionalities provided by ATF

Detecting the new ad slots 

When the ad slots from the webpage are being detected, there is the possibility to add new ad slots to the page. In order to do so the new slots have to be described. They will be detected automatically. 

Detecting the consent string

After ATF-Manager is being loaded and the ATF SDK has been activated the first action will be to detect if a consent string is existing. Without consent string presence no additional actions can be executed.

Collapsing ad slots

ATF SDK is automatically collapsing all ad slots where no ad is being rendered. To enable this feature a GPT function is used for each slot:

googletag.pubads().collapseEmptyDivs()

NOTE! ad slots with atf-infinite-scroll attribute cannot be collapsed.

Link to GPT documentation: Collapse empty divs

This feature can be turned on/off by publisher in ATF-Manager.

Lazy loading

There is a possibility to use the lazy loading function provided by Google Publisher Tag. By default this feature is turned off.

To enable this feature publishers need to add an additional code in the data layer.

 dataLayer.push({ 'atf-useLazyLoad': true })

 By default all ad slots are using Single Request Architecture. For Lazy Loading the Multi Request Architecture is desired by some publishers.

There are three parameters that will define how the ads will be loaded. These parameters can be modified by ATF. By default they are set as suggested at the GPT documentation:

  • Fetch slots within number of viewports (default value 5 viewports).

  • Render slots within number of  viewports (default value 2 viewports)

  • Multiply the above values on mobile, where viewports are smaller and users tend to scroll faster (2.0 multiplier)

 Example of data layer script with lazy load:
<script type="text/javascript">   window.dataLayer = window.dataLayer || [];   dataLayer.push({ 'atf-contentType': 'gallery' }); dataLayer.push({ 'atf-channel': 'testchannel123' });   dataLayer.push({ 'atf-useLazyLoad': true }) </script>

Infinite scroll ad tags

There is the possibility to implement ad slots with atf tags for infinite scrolls on websites.  These slots need to be described as follows:

<atf-ad-slot id="Ad_Slot_3" atf-format="vertical" atf-formatSize="300x1000" atf-requestType="single_request" atf-infinite-scroll> </atf-ad-slot>

An auction for infinite scroll ad slots by default is run 200px before viewport. This can be adjusted by ATF.