ConversionRuler Tracking Snippets
ConversionRuler Tracking Snippets are a mix of JavaScript code and HTML code which allows ConversionRuler to track actions of visitors to your site.
The basic layout of the tracking snippet is:
- Script which loads ConversionRuler JavaScript code for each page
- Script which records a landing or an action on a page
- HTML which records a landing or an action in browsers which do not support JavaScript
Each component of the Tracking Snippet can be implemented separately for a website which wishes to implement ConversionRuler tracking in a more modular way.
Script which loads ConveresionRuler
This script is written in such a way that it loads ConversionRuler tracking code based on whether the current page is a http:// or https:// page (Secure or non-Secure). It loads the script from ConversionRuler's servers:
http://www.conversionruler.com/bin/js.php?siteid=Site ID
This script is dynamically generated and is based on the features selected for the Site ID passed through. In addition, this script can take the following additional query string parameters:
- nocache - Integer value which changes how the script returns caching headers. Adding nocache=1 to the script loading API will set caching headers such that the script is loaded upon every page load.
- crcookie - Force the use of a particular cookie for tracking. If a site wishes to use first-party cookies, they can pass the desired cookie to ConversionRuler for recording. The cookie should be a 32-character hexadecimal string containing only the numbers 0 through 9 and A through F, e.g. 324d8a1d3f81e730d5099a48cee0c5b6
Script which records a landing or an action on a page
At present, there are two different methods to record a landing and/or action:
Passing values can be performed by passing values to the Tracking Queue or the cr_track function, like so:
var _crq =