Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Google adwords conversion tracker XC5

 
Reply
   X-Cart forums > X-Cart 5 > Dev Questions (X-Cart 5)
 
Thread Tools Search this Thread
  #1  
Old 02-18-2015, 07:38 AM
 
tls tls is offline
 

Advanced Member
  
Join Date: Sep 2014
Posts: 40
 

Default Google adwords conversion tracker XC5

I did not find any directions for how to add the adwords conversion tracker in X-Cart 5. But I have learned just enough to pull it off and thought that I would share how I (And Google Tech support) did it.

Google adwords uses a tag added to the success screen to track if clicks they charged you for became sales.
I think they match this with the cookie that they gave the customer so they know what click became the sale. They show you this in the adwords admin area.

You will need the Custom skin Module installed and active in your store.

Go in via FTP and find the file
/httpdocs/skins/default/en/checkout/success_message.tpl
copy it to
/httpdocs/skins/custom_skin/default/en/checkout/success_message.tpl

The en directory is for English language and may be different for your store. You will probably need to create the checkout directory.

Edit the success_message.tpl in the custom_skin area to add your google tag to the end of it.
Mine looked like this:
<img height="1" width="1" style="border-style:none;" alt="" src="//www.googleadservices.com/pagead/conversion/999999999/?label=XXXXXXXXXX;guid=ON&amp;script=0"/>

Go to your X-Cart admin area and re-deploy the store under the System Settings menu at the top.

The reason for doing this in the custom_skin is so that updates to X-Cart 5 don't overwrite it. If the success_message.tpl file gets updated for some reason that you care about, then you would need to redo this process.

BTW. This also lets Google track how many sales your making, and via big data analysis, who your customers are. So if you or your customers are privacy sensitive, don't do this.

Cheers,
Brian
__________________
X-Cart Business 5.2
Wholesale
Product Filter
Reply With Quote

The following 4 users thank tls for this useful post:
Ksenia (02-19-2015), tony_sologubov (02-19-2015), totaltec (02-18-2015), yari (02-04-2016)
  #2  
Old 02-19-2015, 04:27 AM
  tony_sologubov's Avatar 
tony_sologubov tony_sologubov is offline
 

X-Cart team
  
Join Date: Jan 2009
Posts: 2,431
 

Default Re: Google adwords conversion tracker XC5

Thanks for sharing this, Brian!
__________________
Found a bug in X-Cart? Post it to our bug tracker!
Know how to make X-Cart better? Suggest an idea!
Reply With Quote
  #3  
Old 02-04-2016, 03:25 PM
 
yari yari is offline
 

Newbie
  
Join Date: Feb 2016
Posts: 8
 

Question Re: Google adwords conversion tracker XC5

tls,

I just want to say that I love you. Bus also, you probably used the conversion tracking code adjusted to track revenue as well, could you please share your code? Without the account identifiers, of course. I just want to know which is the variable that you must set up as order value adapted to x-Cart.

What I mean exactly is: in the "naked"" version of the code there is a line:

var google_conversion_value = ##.00;

This line has to be changed for a variable reference so that AdWords can pick up the order subtotal value each time it records a conversion.

Any help on how you did this would be greatly appreciated.

Thanks!
Yari
__________________
yari
Reply With Quote
Reply
   X-Cart forums > X-Cart 5 > Dev Questions (X-Cart 5)



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 09:11 PM.

   

 
X-Cart forums © 2001-2020