NATS4 track and strack

From TMMwiki
Jump to: navigation, search
Reporting Admin
The Reporting Admin
track and strack
Fraud Reports

What is Track?

NATS uses track to handle primary tracking for in-bound affiliate traffic. This can usually be found in affiliate linkcodes, such as the following example:


In the above link, NATS will replace <link_domain> with the actual link domain for your site and replace xxxxxxx with the proper affiliate NATSCode. This can be seen in the following image:

Figure 1.1  An Example link code using the standard track feature

How Does track Work?

As surfers hit the track link, or linkcode, NATS will perform its tracking, cookie, and session procedures before redirecting the surfer to their original destination tour URL from the sites admin. The NATSCode itself, or the Link Domain (if no NATSCode is present) will be used by NATS to match a link domain or site ID to the correct tour URL.

Same Surfer Hits Different Track Links?

If the same surfer hits more than one track link, also known as linkcode, NATS will use the tracking information for the most recent affiliate. For example:

  • A surfer passes through the tracking link for affiliate 1, and NATS creates a cookie and starts tracking for affiliate 1. If the same surfer then travels through a tracking link for affiliate 2, NATS begins tracking for affiliate 2, forgetting about affiliate 1.

The only exception to this is In-House affiliates. In-house affiliates will not override the old affiliate's NATSCode, so the old affiliate's code will be used. Continuing from the above example:

  • If affiliate 3 is an In-House affiliate and the surfer goes through the tracking link for affiliate 3, NATS will ignore tracking for this affiliate and will use the tracking information for affiliate 2.

You can mark an affiliate as In-House through the Affiliate Admin Settings.

What is strack?

In contrast to track, strack replaces one site ID or program ID with another site or program ID. If you need to provide links from one NATS site to another, for example, you can use /strack/ to replace the default site ID in the NATS code with a new site ID for the other site. This also serves the purpose of preserving relevant affiliate information, as well as ensuring that affiliates get credit for any sales that have been made.

strack Formatting

  • linkdomain is the link domain of the site in NATS, which will usually be something like or, where is the domain of your main tour or content site.
  • nats_code is the NATS code from your affiliate or the default NATS code for the site. Normally this is available to you on a PHP-enabled site through the usage of the following in-line PHP if statement -- <?=(!empty($_REQUEST['nats']) && !preg_match('/[\'\"<>()\\\+\[\]]/', $_REQUEST['nats']))?$_REQUEST['nats']:xxxxxx?> -- which translates to "If there is a value for NATS set in either GET, POST, or Cookie, use that value. Otherwise, use the default value provided (which is different for every site)."
  • site_id_or_shortname is the ID number or shortname of your desired site. This variable represents the target site and may be different than the site currently being viewed. If you wish to indicate that you do not want to override the site ID number with a new one, you can use the value of 0 as the site ID.
  • tour_id_or_shortname is the ID number or shortname of your desired tour. This is the target tour and may be different than the site currently being viewed. You will need to have the site ID set to the site that your tour is available on to use this variable.
  • program_id_or_shortname is the ID number or shortname of the desired program. You can use this variable to switch from one program to another in your NATS. Switching programs can be useful for things such as special offer links. If you do not wish to change the program, set this value to 0.
  • track_flag is going to count as a new hit and reset the tracking cookie if it wasn't set to 0. If track_flag wasn't set then it will track the hit. If you don't want to track the hit then set the track_flag to 0.
  • optional_subdirectory_path specifies a path to a specific script, document, or subdirectory that is added onto the end of the URL after the tracking redirect. For example, if your site's main tour URL in the Sites Admin is and you pass in /tour1/videos, it will add /tour1/videos to end of the URL after redirecting the surfer.