Configure your PayPal IPN script to notify ConversionRuler

From Market Ruler Help
Revision as of 17:07, 23 July 2012 by Admin (talk | contribs) (Created page with 'If your cart already supports PayPal IPN then you'll need to customize your script to communicate directly with ConversionRuler using the '''custom''' parameter passed in [[I…')
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

If your cart already supports PayPal IPN then you'll need to customize your script to communicate directly with ConversionRuler using the custom parameter passed in originally.

An example, written in PHP to track order amounts and order numbers is:

<?php
/* This is your custom IPN processing file */
... regular IPN tracking ...
$custom = isset($_REQUEST['custom']) ? $_REQUEST['custom'] : null;
if ($custom) {
    $custom .= "&cramount0=" . urlencode($_REQUEST['mc_gross']);
    $custom .= "&crtext0=" . urlencode($_REQUEST['txn_id']);
    file_get_contents("https://www.conversionruler.com/bin/tracker.php?" + $custom);
}

Note the URL used to notify ConversionRuler is:

https://www.conversionruler.com/bin/tracker.php

Which takes a few query string parameters:

  • crsite - The Site ID to track (You may also use the name siteid)
  • crcookie - The user's identification
  • craction - The action code to record
  • cramount0 - The order amount
  • crtext0 - The order number