Popup: Adding variables to the link for traffic optimization

The publisher can add variables to the ad tag that they place on their sources for better selection of ads:

<script src="//example.com/v2/loader.js?_t=52468" data-ts="1574069688" data-token="9bb42c5f57e5f1a290e4cd606ef25f1602f1637e" data-promo-cdn="example.com" data-q="QUERY" data-s1="S1" data-s2="S2" data-s3="S3"></script>

Variables are divided into types:

  • “data-q=”QUERY”” – keywords or a phrase are passed in the link instead of “QUERY”, which are used to improve targeting. The setting is applied at the discretion of the publisher. Ad scripts automatically take the keyword from the page title.
  • “data-s1=”S1″” — instead of “S1” the traffic source is substituted. If the script is hosted on a specific site, “S1” does not need to be specified. When the same script is added to different sites, the domain of the site where the script is located should be entered in the “S1” parameter.
  • “data-s2=”S2″” — instead of “S2”, a sub-traffic source is assigned. Consider two examples of auxiliary sources.

In the first case, there is a site with categories that are located on sub-domains. Therefore, we will write the main domain in the “S1” parameter, and the sub-domain in “S2”:

<script src="//example.com/v2/loader.js?_t=52468" data-ts="1574069688" data-token="9bb42c5f57e5f1a290e4cd606ef25f1602f1637e" data-promo-cdn="example.com" data-s1="website.com" data-s2="movie.website.com"></script>
<script src="//example.com/v2/loader.js?_t=52468" data-ts="1574069688" data-token="9bb42c5f57e5f1a290e4cd606ef25f1602f1637e" data-promo-cdn="example.com" data-s1="website.com" data-s2="music.website.com"></script>

In the second case, there is an advertising network that sells traffic from various sites. Then in “S1” you can substitute the name of the advertising network, and in “S2” – the domain or ID of the site where the advertising script is located. It will look like this:

<script src="//example.com/v2/loader.js?_t=52468" data-ts="1574069688" data-token="9bb42c5f57e5f1a290e4cd606ef25f1602f1637e" data-promo-cdn="example.com" data-s1="adnetwork.com" data-s2="website_1.com"></script>
<script src="//example.com/v2/loader.js?_t=52468" data-ts="1574069688" data-token="9bb42c5f57e5f1a290e4cd606ef25f1602f1637e" data-promo-cdn="example.com" data-s1="adnetwork.com" data-s2="website_2.com"></script>
  • “data-s3=”S3″” — instead of the “S3” parameter, click_id can be specified if the publisher plans to use postback. The publisher sets the values for “S3” at its discretion. When “S3” is not specified, the platform generates a click_id.

Parameters “S1” and “S2” apply if the same ad tag is used on different sites or projects with a large number of content categories. There are no strict usage rules for the ‘S3’ parameter and the ‘query’ parameter.

A publisher can place one ad tag on two different sites. If he writes the names of the sites or their domains in the “S1” parameter (data-s1=”website1″ and data-s1=”website2″), you can find out from which site the traffic and most conversions came from. It will also be possible to understand how to optimize sites. Without this information, it will not be possible to determine the site with the best result and select high-quality advertising.

You can read more about creating Pop Ads and connecting the script here.

Scroll to Top