fr | en | es | de

The main tag

New!
Discover the latest tools in the
Analytics Suite, thanks to our new online help.

Contents: Hide

Available via:

These tags provide the main measurement of the pages being traced. There are two types of content tags:

These tags must ALWAYS be placed between the BODY and /BODY tags.

 

The complete tag requires the use of a JavaScript (JS) file which we provide and which is hosted on the web server of the site being traced. This file is named xtcore.js.

This tag is the only tag which is compatible with the other complementary tags (described below). It can also be used to retrieve information on the site's referrers more efficiently and more effectively than the light tag does, and this is why we strongly recommend that you use the complete tag.

Important

If you wish to continue to use the old xiti.js or xtroi.js tags (used up until the 08/10/07), it is possible to rename the xtcore.js in such a way that it is not present in the source code of all of your pages.

The light tag is not compatible with the complementary tags and as a result you cannot benefit from all of the features that our technology has to offer. The light tag should only be used as a last resort if:

Tag template

The tag consists of 2 parts: a SCRIPT part and a NOSCRIPT part. Only one of these parts will be called on the web user's browser, depending on whether or not JavaScript is enabled. It is therefore essential that both parts are set up in the same way on all of your pages, otherwise we will consider that the pages are different.

<script type="text/javascript">

<!--

xtnv = document;  //parent.document or top.document or document        

xtsd = "http://logxxxx";

xtsite = "xxxxx"; //site number

xtn2 = "";        //level 2 site

xtpage = "";      //page name (with the use of :: to create chapters)

xtdi = "";        //implication degree

xt_multc = "";    //customised indicators

xt_an = "";       //numeric identifier

xt_ac = "";       //category

//do not modify below

if (window.xtparam!=null){window.xtparam+="&ac="+xt_ac+"&an="+xt_an+xt_multc;}

else{window.xtparam = "&ac="+xt_ac+"&an="+xt_an+xt_multc;};

 

//-->

</script>

<script type="text/javascript" src="http://www.mysite.com/xtcore.js"></script>

 

<noscript>

<img width="1" height="1" src="http://logxxxx.xxxx/hit.xiti?s=xxxxx&s2=&p=&di=&ac=&an=&" >

</noscript>

The tag variables

Some of this tag's variables are permanent and compulsory, including:

Other variables are optional and depend on the specific page that is being traced (recommended):

There are also more global values which are available on the whole site:

The JavaScript file (xtcore.js )

As far as the complete mode of ChannelOptimizerNX is concerned, a JavaScript file must be hosted on the server. This file MUST NOT BE EDITED as it contains libraries of necessary functions which allow our tool to work correctly on your site.

We recommend that you place the JavaScript file at the website's root, or into a directory which can be easily accessed. Once the file is placed on the server, the file's path must be entered into the SCRIPT part of URL, as shown in the following example http://www.mysite.com/xtcore.js which is specified by default. It is possible to enter a relative or absolute path in this part of the script.

The importance of this file is that it will be called upon by all of the tags of the site that is to be audited. As a result it is quick and simple to update the file: updating the tag = updating the JavaScript file

Note

To get the latest information on tag updates or any enhancements made to the tag please visit the Support Centre on your interface and go to the section entitled Latest News.

Advanced configuration is also possible by going to:

Using the advanced configuration allows you to define certain variables before downloading the xtcore.js file:

SSL mode

A secure version of the tag is available and allows you to measure audience levels for the secure pages of your website. This tag code is linked to our secure servers.

In order to obtain the secure version of a tag all you need to do is click on the "padlock" icon depending on the code type requested.

Note

Please remember to also place your JavaScript file onto a secure server.

Using the xtcustom variable

The xtcustom variable is a general variable which shares the different parameters that you would like to measure. Using the xtcustom variable avoids having to use AT Internet’s predefined variables such as xtpage, xtn2, roimt, xtdi, xt_multc, etc. The Data Manager interface must be used to let our data processing system know which parameter corresponds to which dimension (please refer to the Data Manager user guide).

This variable, just like the xtsd and xtsite variables must be declared before the call to the xtcore.js file.

The xtcustom variable can contain as many parameters as you wish, and the declaration syntax to be used is JSON (the different parameters should be separated by commas. A value which has been allocated to a parameter should be represented with a colon ( : ). All of this information should be written inside curly brackets {}.

Declaring parameters with 1 dimension:

xtcustom = {param1: 'val1',  param2:val2, etc.};

where “paramx” represents the parameter name and “valx” represents the values to be associated with the parameters (between speech marks in the example above)

Declaring parameters with 2 dimensions:

xtcustom = {param1: {param11: 'val11', param12: 'val12', etc.}};

where “paramx” represents the parameter name and “valx” represents the values to be associated with the parameters (between speech marks in the example above). In this example, the parameters “param11” and “param12” depend on the parameter “param1”.  

 

It is possible to combine parameters with both 1 and 2 dimensions whenever you are declaring them in the xtcustom variable.

Declaring level 2 sites via the xtcustom variable:

xtcustom = {myLevel2ID: 3};

You need to retrieve the “MyLevel2ID” parameter from the Data Manager interface and allocate it to the “Level 2” dimension of the object “Pages”

Declaring pages and chapters via the xtcustom variable:

xtcustom = {MyPageLabel: 'my_page', MyChapters:{level1:'my_chapter1',level2:'my_sub_chapter1',level3:'my_sub_chapter2'} };

You need to retrieve the following parameters from the Data Manager interface: “MyPageLabel”, “MyChapters.level1” “MyChapters.level2”, “MyChapters.level3”. These parameters should then be allocated to the following dimensions respectively: “Pages”, “Chapters”, “Level 2 chapters”, “Level 3 chapters”.

An example of complete code with the xtcustom variable for pages, chapters and level 2 sites:

<script type="text/javascript">

<!--

xtnv = document;  //parent.document or top.document or document        

xtsd = "http://logxxxx";

xtsite = "xxxxx"; //site number

xtcustom = {myL2:3, MyPage:'my_page', MyChap:{l1:'my_ch1',l2:'my_sub_ch1',l3:'my_sub_ch2'} };  //custom parameters in JSON format

//-->

</script>

<script type="text/javascript" src="http://www.mysite.com/xtcore.js"></script>

 

<noscript>

<img width="1" height="1" src="http://logxxxx.xxxx/hit.xiti?s=xxxxx" >

</noscript>

 

 

ico_up.gif