RSS

Tracking with Google Analytics

Wed, Oct 15, 2008

Program Tips & Guidelines

Viator Partners can now have enhanced website tracking using Google Analytics.

Here are the steps to setting up tracking:

1) CREATE an account at Google Analytics or log into your existing Google Analytics account. (Hint: You can use your existing Google Analytics account if you already have one)
http://www.google.com/analytics/

2) ADD a new website profile for your partner site. Enter the URL for your Partner home page (ie. www.partner.viator.com/en/9999 — replace 9999 with your PUID number). Select “Finish”.

(Hint: don’t include http:// it’s already there)

</p>

(Hint: Click on any image for larger view)

3) On the next screen, CAPTURE the Web Property ID/Google Tracker Number. Note: Do NOT use the entire Google Tracking Code in this box, you will be using the Viator Code below with the Google Tracking Number only. This number should start with “UA-”.

4) ENABLE E-commerce Tracking for this account, by following these steps in the Google interface.

Select Edit

</p>

Select Edit (Upper Right)

</p>

Select “Yes, an E-commerce Site” and “Save Changes”

</p>

5) COPY the code below and Replace UA-XXXXXXXX-X with your Web Property ID/Google Tracker Number below — leave the quotes (”) in tact.

Remember you will using the Viator Code below — not the “New Tracking Code” provided by Google.

<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
var pageTracker = _gat._getTracker("UA-XXXXXXXX-X");
pageTracker._trackPageview();
if (analyticsTrans != null && typeof(analyticsTrans) != 'undefined') {
pageTracker._addTrans(
analyticsTrans.analyticsOrderID,
analyticsTrans.analyticsPartnerID,
analyticsTrans.analyticsTotalPrice,
analyticsTrans.analyticsTax,
analyticsTrans.analyticsShipping,
analyticsTrans.analyticsCustomerCity,
analyticsTrans.analyticsCustomerState,
analyticsTrans.analyticsCustomerCountry
);
}
for (var i=0;i<analyticsItemArr.length;i++) {
pageTracker._addItem(
analyticsItemArr[i].analyticsOrderID,
analyticsItemArr[i].analyticsProductCode,
analyticsItemArr[i].analyticsProductName,
analyticsItemArr[i].analyticsProductCategory,
analyticsItemArr[i].analyticsProductPrice,
analyticsItemArr[i].analyticsPAX
);
}
pageTracker._trackTrans();
</script>


6) ADD the code to BOTH HTML FOOTERS (Nonsecure and secure) in the Viator Partner Admin. Be sure to remove any default code in the HTML Footer entry boxes before adding the Viator-Google code.

Note: if you have existing footer code, please add the Viator-Google code to the Bottom of the Footer.

</p>

Click OK on the warning page.

</p>

7) SAVE Settings after adding the Footer Code on the Viator Partner Admin.

</p>

8 ) To VERIFY the settings, click on your Viator Partner site to generate statistics for the Google Anayltics system.
9 ) Be patient because the statistics don’t show up immediately - it will take 24 hours - it is normal for it to say that tracking isn’t installed for a while.

10 ) After 24 hours, the system should reflect activity from the Viator Partner site.

IMPORTANT: Sales figures reported on Google Analytics show purchases only and do not reflect cancellations or modifications which will affect commission payments.

Questions about Google Analytics? Click here.

(updated 24Aug2009)


This post was written by:

John - who has written 38 posts on Viator Partner Blog.


Contact the author

Comments are closed.