ResOnline Pty Ltd

Google Analytics Code

Google Analytics Code

Previous topic Next topic No directory for this topic  

Google Analytics Code

Previous topic Next topic Topic directory requires JavaScript JavaScript is required for the print function  

To find your Google Analytics Code, follow the steps below...

 

 

To access your tracking code from within your Google Analytics account:

 

1.Log in to Google Analytics at http://www.google.com/analytics

2.From the Overview page, select the account that has the profile for the tracking code you're looking for, as the code is profile-specific.

3.Select the profile from the accounts Overview page.

4.From that profile's Actions column, click Edit

5.At the top right of the 'Main Website Profile Information' box, click Check Status

6.Your tracking code can be copied and pasted from the text box in the Instructions for adding tracking section

 

Once you have found the google analytics code simply copy it into the positions provided in "Booking Button"

 

clip0089

 

 

Google E-Commerce Support and Google Tracking how to.

 

Please find below some example scripts which can be used to place inside the Resonline Booking Process.  Placing these scrips inside the correct locations will inform google of not only tracking of your clients visits, but also tracking the Commercial Value of the booking.

This facility is particularly useful when you are using the Pay Per Click facility with Google Analytics and you want to know if you are getting a return on your investment.

 

We recommend you employ the services of a web developer to get this correct, as it can be daunting if you are not an IT Professional.

 

We also highly Recommend that you receive the code as generated directly from Google as they do change their code from time to time.  The code below may be out of date, we are just supplying these scripts as a guide to help you understand what is possible.

 

Stand-alone Booking Page script

 

Note: You will need to change the ??????? area with your google Analytics Code.

 

<script type="text/javascript">

 

 var _gaq = _gaq || [];

 _gaq.push(['_setAccount', '????????????']);

 _gaq.push(['_trackPageview']);

 

 (function() {

var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;

ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';

var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);

 })();

 

</script>

 

 

Guest Details & Payment Page

 

Note: You will need to change the ??????? area with your google Analytics Code.

 

<script type="text/javascript">

 

 var _gaq = _gaq || [];

 _gaq.push(['_setAccount', '???????????????']);

 _gaq.push(['_trackPageview']);

 

 (function() {

var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;

ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';

var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);

 })();

 

</script>

 

 

Confirmation Page

 

Note: You will need to change the ??????? area with your google Analytics Code and variables.  For E-commerce, there are a number of variables that google supplies, so we recommend you employ the services of a web developer to get this correct, as it can be daunting if you are not an IT Professional.

 

You will also notice below the fields wrapped in square brackets.  eg, [BOOKING_ID].  These are important as our software will replace these with the actual data that that relates to the booking being placed.  You can imagine the [SALE_PRICE] field will receive the booking amount, which will then be sent to google and it will then know the value of the booking and help you with your ROI analysis.

 

<script type="text/javascript">

 var _gaq = _gaq || [];

 

 _gaq.push(['_setAccount', '??????????????????']);

 

 _gaq.push(['_trackPageview']);

 _gaq.push(['_addTrans',

'[BOOKING_ID]',           // order ID - required

'[HOTEL_NAME]',           // affiliation or store name

'[SALE_PRICE]',           // total - required

'0',                      // tax

'0',                      // shipping

'Unknown',                // city

'Unknown',                // state or province

'Unknown'                 // country

 ]);

 

// add item might be called for every item in the shopping cart

// where your ecommerce engine loops through each item in the cart and

// prints out _addItem for each

 _gaq.push(['_addItem',

'[BOOKING_ID]',           // order ID - required

'[ROOM_ID]',              // SKU/code - required

'[ROOM_NAME]',            // product name

'',                       // category or variation

'[SALE_PRICE]',           // unit price - required

'1'                       // quantity - required

 ]);

 

 (function() {

var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;

ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';

var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);

 })();

 

 function clear_form()

 {

document.register.reset(); 

 }

 

</script> 

 

 

<!-- Google Code for Confirmation Page Conversion Page -->

<script type="text/javascript">

/* <![CDATA[ */

var google_conversion_id = ?????????;

var google_conversion_language = "en";

var google_conversion_format = "2";

var google_conversion_color = "ffffff";

var google_conversion_label = "?????????";

var google_conversion_value = [SALE_PRICE];

/* ]]> */

</script>

<script type="text/javascript" src="http://www.googleadservices.com/pagead/conversion.js">

</script>

<noscript>

<div style="display:inline;">

<img height="1" width="1" style="border-style:none;" alt="" src="http://www.googleadservices.com/pagead/conversion/?????????/?label=????????????&guid=ON&script=0"/>

</div>

</noscript>