Skip to content

Instantly share code, notes, and snippets.

@equijada001
Created December 3, 2012 21:57
Show Gist options
  • Save equijada001/4198477 to your computer and use it in GitHub Desktop.
Save equijada001/4198477 to your computer and use it in GitHub Desktop.
Conversion tracking code, removes the the '$' symbol in front of the donation amount. Replace site ID and product name.
<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">
try{
var pageTracker = _gat._getTracker("UA-353912-1");
pageTracker._trackPageview();
pageTracker._addTrans(
'[[S120:dc:transactionID]]',
'3WDW1300XXXXX',
'[[E130:"[[S120:dc:giftAmount]]" "$" "" replaceall]]',
'0',
'0',
'[[S120:dc:city]]',
'[[S120:dc:stateProvince]]',
''
);
pageTracker._trackTrans();
} catch(err) {}
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment