Analytics
1.8K members online now
1.8K members online now
Learn how to set up goals and Ecommerce tracking, verify accuracy of attribution traffic sources, and discuss funnel visualization, Multi-Channel Funnels, the Goal Flow Report, and Enhanced Ecommerce
 
Guide Me
star_border
Reply

Does the Mentioned Conversion Code Tracks All Source/Medium Conversions?

[ Edited ]
Follower ✭ ☆ ☆
# 1
Follower ✭ ☆ ☆

Hi All,

 

We are planning to track goal conversion values and the challenge we face is that goal conversion values are dynamic. We run adwords, SEO and other marketing stuffs to generate conversions. So, I just want to know whether the below code tracks all the source/medium conversion values or does it track only adwords conversion values
 

<!-- Google Code for Purchase Conversion Page -->
<script type="text/javascript">
/* <![CDATA[ */
var google_conversion_id = 1234567890;
var google_conversion_language = "en_US";
var google_conversion_format = "1";
var google_conversion_color = "666666";
var google_conversion_label = "Purchase";
if (<? echo $totalValue ?>) {
var google_conversion_value = <? echo $totalValue ?>
}
/* ]]> */
</script>
<script type="text/javascript"
src="http://www.googleadservices.com/pagead/conversion.js">
</script>
<noscript>
<img height=1 width=1 border=0
src="http://www.googleadservices.com/pagead/
conversion/1234567890/?value=
<? echo $totalValue ?>&label=Purchase&script=0">
</noscript>
</body>

 

Should I place this conversion code on purchase confirmation page?
 
And my website has English and Arabic conformation pages separately.  So, does the below code tracks only English page conversion  values and for Arabic do I need to change the conversion_language to Arabic in order to track?
 
var google_conversion_language = "en_US";
 
Kindly help me on this.
1 Expert replyverified_user

Re: Does the Mentioned Conversion Code Tracks All Source/Medium Conversions?

Rising Star
# 2
Rising Star
Hi Prabhu,

This will only track conversions from AdWords clicks (within the last 30 days).

This part (<? echo $totalValue ?>) {
var google_conversion_value = <? echo $totalValue ?>

requires you to programmatically pass the total value.

In order for you to track the dynamic value in Google Analytics you have two choices:

1. Use Ecommerce

2. Fire an event when your goal conversion ocurrs and pass the value of the conversion into your value of your event.

More on ecommerce and event tracking here:

https://developers.google.com/analytics/devguides/collection/analyticsjs/ecommerce

https://developers.google.com/analytics/devguides/collection/analyticsjs/events


Best,

Theo Bennett



Analytics Evangelist at MoreVisibility | Contact Me
Connect on LinkedIn