Conversion Tracking

Overview

TripAdvisor offers a conversion tracking solution to help hotels track the revenue of advertising on TripAdvisor.

Hotels can view this calculated revenue in their Management Center page on TripAdvisor.

In order to enable this functionality for their hotel clients, and to be certified as a Plus Partner, partners must configure their websites to notify TripAdvisor of any booking that occurs as a result of a lead sent by TripAdvisor.

Conversion Tracking Details

Conversion Tracking functionality is facilitated by using a TripAdvisor pixel tag.

The Connectivity Partner must place a TripAdvisor pixel tag on every page controlled by the Connectivity Partner. This will include every page of each hotel the Connectivity Partner manages.

TripAdvisor fully handles credit attribution.

 

As a Connectivity Partner, you enable Conversion Tracking with the following steps:

       1) Pixel Tag: Download the pixel tag from TripAdvisor.

       2) Page Impressions: Place the pixel tag on every hotel page you control and call the impressionWithReferer() function.

       3) Booking Conversions: Place the pixel tag on every booking confirmation page and call the conversionWithReferer() function.

 

Note The pixel tag cannot be called from within an iframe, because iframes will prevent the pixel from firing.

Pixel Tag

The approved method of sending tracking data to TripAdvisor utilizes a custom javascript library supplied by TripAdvisor to generate the pixels for you.

The javascript file is available at either of the following URLs:

http://www.tripadvisor.com/js3/conversion/pixel.js

https://www.tripadvisor.com/js3/conversion/pixel.js

You must include this file in the <HEAD> tag of all HTML documents that will generate a pixel.

Page Impressions

The pixel tag should be called using the impressionWithReferer() method and the arguments described in the following table.

Function Parameters

Name Type Description
partnerName string
Unique partner identifier.
 
This is the ID you received via email when you signed up.
 
It must be 15 characters.

 

Example Request

TAPixel.impressionWithReferer("002F1110018OjjJ");

TripAdvisor offers a conversion tracking solution to help hotels manage their TripAdvisor advertizing.

In order to enable this functionality for their hotel clients, and to be certified as a Premium Partner, partners must configure their websites to notify TripAdvisor of any booking that occurs as a result of a lead sent by TripAdvisor.

The approved method of sending this data to TripAdvisor utilizes a custom javascript library supplied by TripAdvisor to generate the pixels for you. The javascript file is located at http://www.tripadvisor.com/js3/conversion/pixel.js. You must include this file in the HEAD tag of all HTML documents that will generate a pixel.

Booking Conversions

Place a pixel tag on the booking confirmation page using the conversionWithReferer() method and arguments described in the following table.

Note that this must be done for every booking confirmation page controlled by the Connectivity Partner.

Function Parameters

Name Type Description
partnerName string
Unique partner identifier.
 
This is the ID you received via email when you signed up, e.g. "002F1110018OjjJ"
 
It must be 15 characters.
partnerId string
The unique identifier for the hotel in the Connectivity Partner's database.
gdv integer
The total value of the booking in cents, excluding tax and fees.
currency string
The ISO 4317 currency code associated with the gbv parameter.
tax integer
Tax paid at time of booking in cents.
fees integer
Fees paid at time of booking in cents.
startDate string
The check-in date of the traveler.
The date will be in the form YYYY-MM-DD.
For example, '2013-09-17'.
endDate string

The check-out date of the traveler.

The date will be in the form YYYY-MM-DD.

For example, '2013-09-18'.

numAdults integer The number of adults traveling.
order_number string

Order confirmation number of the booking event.

This number must be unique for each booking.

Example Request

TAPixel.conversionWithReferer("002F1110018OjjJ", "123456", 15400, "USD", 1400, 1000, "2013-07-01", "2013-07-03", 2, "1234ABC");

Sample Code

When somebody clicks a link on the TripAdvisor site through to the hotels booking pages, and proceeds through to a "booking confirmation page", these booking web pages are the "pages under the Connectivity Partner's control".

What needs to happen is the Connectivity Partner must add a small bit of JavaScript to each of these pages under their control.

These are the two steps:
1. There are usually one or more pages where a traveller can select dates, room type, etc. as they are going through the booking process. These pages need to have JavaScript to show that there has been an 'impression' on these pages.

2. There is a single "booking confirmation page" where somebody can confirm their booking choice and submit it at the end of the booking process.
This page needs to have JavaScript on it which will tell TripAdvisor that a conversion has occurred.

The JavaScript for the impressions pages would consist of something like the following near the top of the HTML for the page:


<!-- Purpose : Conversion-Tracking for TripAdvisor -->
<script type="text/javascript" src="http://www.tripadvisor.com/js3/conversion/pixel.js"></script>


Then, somewhere further down in the HTML, something like the following must be added:


<!-- Purpose : Conversion-Tracking for TripAdvisor -->
<script type="text/javascript">
if (TAPixel !== null && typeof TAPixel === 'object') { TAPixel.impressionWithReferer("<UNIQUE PARTNER IDENTIFIER>");
}
</script>


For the booking confirmation page the last bit of JavaScript is slightly different. It needs to call conversionWithReferer() instead of impressionWithReferer().
And the appropriate additional parameters for the "conversionWithReferer()" function must be provided.