jaap:
Hello Shrimp,
**Conversion tracking for "create_account_success" page **
Maybe I confused the issue by mentioning that (I think) the mod ONLY installs conversion tracking for "checkout_success" page. I may be underestimating the mod here ...
BUT I actually want to know how to track "create_account_success" page conversions (SGA setting I missed? Or else where to find </body> tag?). My store sells high-value items, the prices of which are only displayed to "logged-in" users. It is the number of user registrations that I want to track. I hope this clarifies.
Thanks, Jaap
canopyxchange.za.net
Jaap,
econcepts can answer best but it places a code on all pages.... checkout_success would show as an ecommerce transaction.... I think in order to determine where the users are coming from that register you would have to include an additional code that you can find in the analytics documentation... I would suggest modifying the google_analytics.php file in the templates by adding another if statement after the:
if($page_directory == 'includes/modules/pages/checkout_success')
{
$order_query = "select orders_id, " . GOOGLE_ANALYTICS_TARGET . "_city as city, " . GOOGLE_ANALYTICS_TARGET . "_state as state, " . GOOGLE_ANALYTICS_TARGET . "_country as country from " . TABLE_ORDERS . " where customers_id = :customersID order by date_purchased desc limit 1";
$order_query = $db->bindVars($order_query, ':customersID', $_SESSION['customer_id'], 'integer');
$order = $db->Execute($order_query);
$google_analytics = array();
$totals = $db->Execute("select value, class from " . TABLE_ORDERS_TOTAL . " where orders_id = '" . (int)$order->fields['orders_id'] . "' and (class = 'ot_total' or class = 'ot_tax' or class = 'ot_shipping')");
while (!$totals->EOF) {
$google_analytics[$totals->fields['class']] = number_format($totals->fields['value'], 2, '.', '');
$totals->MoveNext();
}
to check to see if the customer is on the page you desire then modify the above if statement to spit out the required code to track that page.
Good Luck!
Shrimp