Results 1 to 10 of 2161

Hybrid View

  1. #1
    Join Date
    Jan 2009
    Posts
    14
    Plugin Contributions
    0

    Default Re: Simple Google Analytics - Support

    Quote Originally Posted by econcepts View Post
    James,

    Do you have an affiliate program (like JAM / JROX) installed on your site? This the way this is installed causes it to override the thank you page (footer) of the site and thus renders the Google Analytics Tracking code non-working (it removes it from the page).

    If that is the case you can read my post in the link below for installing it with JROX / JAM. Go to the following link and scroll to the bottom of the page (July 22 post). You'll see the instructions for how to do this.

    http://www.zencartoptimization.com/2...-the-workbook/

    If this does not correct your issue let me know and I can take a look.

    Thanks!

    Hey Thanks so much for your help. We followed the instructions you provided and the Simple Google Analytics eCommerce Tracking worked. BUT, our iDefAffiliate program did not work anymore. So, we had to back out the changes and add revert back to the 'tple_footer.php' file that you recommended we removed.

    We did try to add the iDev Affiliate code to the 'tpl_main_page.php' as you suggested to move the JAM code. But, this caused the site to not even load. We don't have a test environment and we are not php coders, but we do want iDevAffiliate and Google Analytics eCommerce tracking to work at the same time. Do you have a suggested approach to resolve this issue?

    For your reference, this is the instructions that the iDevAffiliate gives for Zen integration:

    ZenCart Version 1.3.x or Newer
    1. Download the template override file: Download Here
    2. Save the file to your local harddrive.
    3. Edit that file and near the bottom, adjust the path to your iDevAffiliate installation folder/directory.
    4. Upload that file to your /zencart/includes/templates/your_template_directory/checkout_success/tpl_footer.php directory.

    Notes:
    1. The directory your_template_directory is the ZenCart template directory you're using.
    2. If the directory checkout_success doesn't exist, create it and upload tpl_footer.php into it.

    Here are the contents of the 'template override file they provided:

    <?PHP
    require(DIR_WS_MODULES . zen_get_module_directory('footer.php'));
    if (!$flag_disable_footer) {
    ?>

    <div id="navSuppWrapper">
    <div id="navSupp">
    <ul>
    <li><?PHP echo '<a href="' . HTTP_SERVER . DIR_WS_CATALOG . '">'; ?><?PHP echo HEADER_TITLE_CATALOG; ?></a></li>
    <?PHP if (EZPAGES_STATUS_FOOTER == '1' or (EZPAGES_STATUS_FOOTER == '2' and (strstr(EXCLUDE_ADMIN_IP_FOR_MAINTENANCE, $_SERVER['REMOTE_ADDR'])))) { ?>
    <li><?PHP require($template->get_template_dir('tpl_ezpages_bar_footer.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_ezpages_bar_footer.php'); ?></li>
    <?PHP } ?>
    </ul>
    </div>
    </div>
    <?PHP
    if (SHOW_FOOTER_IP == '1') {
    ?>
    <div id="siteinfoIP"><?PHP echo TEXT_YOUR_IP_ADDRESS . ' ' . $_SERVER['REMOTE_ADDR']; ?></div>
    <?PHP
    }
    ?>
    <?PHP
    if (SHOW_BANNERS_GROUP_SET5 != '' && $banner = zen_banner_exists('dynamic', SHOW_BANNERS_GROUP_SET5)) {
    if ($banner->RecordCount() > 0) {
    ?>
    <div id="bannerFive" class="banners"><?PHP echo zen_display_banner('static', $banner); ?></div>
    <?PHP
    }
    }
    ?>
    <div id="siteinfoLegal" class="legalCopyright"><?PHP echo FOOTER_TEXT_BODY; ?></div>

    <?PHP }

    if ((int)$orders_id > 0) {
    $IDEV = $db->Execute("select class, value from " . TABLE_ORDERS_TOTAL . " where orders_id = '".(int)$orders_id."' AND class in ('ot_coupon', 'ot_subtotal', 'ot_group_pricing')");
    while (!$IDEV->EOF) {
    switch ($IDEV->fields['class']) {
    case 'ot_subtotal':
    $order_subtotal = $IDEV->fields['value'];
    break;
    case 'ot_coupon':
    $coupon_amount = $IDEV->fields['value'];
    break;
    case 'ot_group_pricing':
    $group_pricing_amount = $IDEV->fields['value'];
    break;
    }
    $IDEV->MoveNext();
    }
    $idev_sale_amount = ($order_subtotal - $coupon_amount - $group_pricing_amount);
    $idev_sale_amount = number_format($idev_sale_amount,2,'.','');

    // Make sure the below path is correctly pointing to your installation folder/directory.
    echo "<img border=\"0\" src=\"http://www.yourdomain.com/idevaffiliate/sale.php?idev_saleamt=$idev_sale_amount&idev_ordernum=$orders_id\" height=\"1\" width=\"1\">";

    echo "</td></tr></table>";
    }

    ?>

  2. #2
    Join Date
    Dec 2005
    Posts
    1,509
    Plugin Contributions
    6

    Default Re: Simple Google Analytics - Support

    Quote Originally Posted by jamesmcl515 View Post

    Hey Thanks so much for your help. We followed the instructions you provided and the Simple Google Analytics eCommerce Tracking worked. BUT, our iDefAffiliate program did not work anymore. So, we had to back out the changes and add revert back to the 'tple_footer.php' file that you recommended we removed.

    We did try to add the iDev Affiliate code to the 'tpl_main_page.php' as you suggested to move the JAM code. But, this caused the site to not even load. We don't have a test environment and we are not php coders, but we do want iDevAffiliate and Google Analytics eCommerce tracking to work at the same time. Do you have a suggested approach to resolve this issue?

    For your reference, this is the instructions that the iDevAffiliate gives for Zen integration:

    ZenCart Version 1.3.x or Newer
    1. Download the template override file: Download Here
    2. Save the file to your local harddrive.
    3. Edit that file and near the bottom, adjust the path to your iDevAffiliate installation folder/directory.
    4. Upload that file to your /zencart/includes/templates/your_template_directory/checkout_success/tpl_footer.php directory.

    Notes:
    1. The directory your_template_directory is the ZenCart template directory you're using.
    2. If the directory checkout_success doesn't exist, create it and upload tpl_footer.php into it.

    Here are the contents of the 'template override file they provided:

    <?PHP
    require(DIR_WS_MODULES . zen_get_module_directory('footer.php'));
    if (!$flag_disable_footer) {
    ?>

    <div id="navSuppWrapper">
    <div id="navSupp">
    <ul>
    <li><?PHP echo '<a href="' . HTTP_SERVER . DIR_WS_CATALOG . '">'; ?><?PHP echo HEADER_TITLE_CATALOG; ?></a></li>
    <?PHP if (EZPAGES_STATUS_FOOTER == '1' or (EZPAGES_STATUS_FOOTER == '2' and (strstr(EXCLUDE_ADMIN_IP_FOR_MAINTENANCE, $_SERVER['REMOTE_ADDR'])))) { ?>
    <li><?PHP require($template->get_template_dir('tpl_ezpages_bar_footer.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_ezpages_bar_footer.php'); ?></li>
    <?PHP } ?>
    </ul>
    </div>
    </div>
    <?PHP
    if (SHOW_FOOTER_IP == '1') {
    ?>
    <div id="siteinfoIP"><?PHP echo TEXT_YOUR_IP_ADDRESS . ' ' . $_SERVER['REMOTE_ADDR']; ?></div>
    <?PHP
    }
    ?>
    <?PHP
    if (SHOW_BANNERS_GROUP_SET5 != '' && $banner = zen_banner_exists('dynamic', SHOW_BANNERS_GROUP_SET5)) {
    if ($banner->RecordCount() > 0) {
    ?>
    <div id="bannerFive" class="banners"><?PHP echo zen_display_banner('static', $banner); ?></div>
    <?PHP
    }
    }
    ?>
    <div id="siteinfoLegal" class="legalCopyright"><?PHP echo FOOTER_TEXT_BODY; ?></div>

    <?PHP }

    if ((int)$orders_id > 0) {
    $IDEV = $db->Execute("select class, value from " . TABLE_ORDERS_TOTAL . " where orders_id = '".(int)$orders_id."' AND class in ('ot_coupon', 'ot_subtotal', 'ot_group_pricing')");
    while (!$IDEV->EOF) {
    switch ($IDEV->fields['class']) {
    case 'ot_subtotal':
    $order_subtotal = $IDEV->fields['value'];
    break;
    case 'ot_coupon':
    $coupon_amount = $IDEV->fields['value'];
    break;
    case 'ot_group_pricing':
    $group_pricing_amount = $IDEV->fields['value'];
    break;
    }
    $IDEV->MoveNext();
    }
    $idev_sale_amount = ($order_subtotal - $coupon_amount - $group_pricing_amount);
    $idev_sale_amount = number_format($idev_sale_amount,2,'.','');

    // Make sure the below path is correctly pointing to your installation folder/directory.
    echo "<img border=\"0\" src=\"http://www.yourdomain.com/idevaffiliate/sale.php?idev_saleamt=$idev_sale_amount&idev_ordernum=$orders_id\" height=\"1\" width=\"1\">";

    echo "</td></tr></table>";
    }

    ?>
    Yes, this install of iDev is basically the same as it is with JAM (same concept, same files altered.)

    You would still want to follow the same instructions as for JAM (of course removing the JAM portion and replacing with the iDev affiliate one).

    If you need help send me a private message and I'll take a look.

    Thanks!
    Eric
    20 Ways to Increase Sales Using Zen Cart
    Zen Cart contribs: Simple Google Analytics, Export Shipping Information

  3. #3
    Join Date
    Jan 2009
    Posts
    14
    Plugin Contributions
    0

    Default Re: Simple Google Analytics - Support

    Quote Originally Posted by econcepts View Post
    Yes, this install of iDev is basically the same as it is with JAM (same concept, same files altered.)

    You would still want to follow the same instructions as for JAM (of course removing the JAM portion and replacing with the iDev affiliate one).

    If you need help send me a private message and I'll take a look.

    Thanks!
    Hey Eric,

    Once again you are an amazing resource for the Zen Cart community, thank you. Before we give this another shot, I have one additional question.

    Do we need to include the entire contents of the 'tpl_footer.php' page on the 'tpl_main_page.php' page or just a snippet that is relevant to iDev?

    Thanks again,
    James

  4. #4
    Join Date
    Dec 2005
    Posts
    1,509
    Plugin Contributions
    6

    Default Re: Simple Google Analytics - Support

    Quote Originally Posted by jamesmcl515 View Post
    Hey Eric,

    Once again you are an amazing resource for the Zen Cart community, thank you. Before we give this another shot, I have one additional question.

    Do we need to include the entire contents of the 'tpl_footer.php' page on the 'tpl_main_page.php' page or just a snippet that is relevant to iDev?

    Thanks again,
    James
    James,

    Thanks for the kind words. I love to help.

    To answer your question ...

    You do NOT want to include the entire contents of the tpl_footer.php file in the tpl_main_page.php

    You only want to include the bit that I have indicated in the instructions at that previous link (let me know if you need that again.)

    It would look something like this (at the bottom of your tpl_main_page.php).

    PHP Code:
    < ?php
    require($template->get_template_dir('.php',DIR_WS_TEMPLATE$current_page_base,'google_analytics') . '/google_analytics.php');
    ?>
    < ?php
    if ($_GET['main_page']=="checkout_success") {

    ##########################################
    ## START iDevAffiliate INTEGRATION WITH ZEN CART ##
    ##########################################


    Insert your iDeve Affiliate code here taken from your tpl_footer.php page


    #######################################
    ## END iDevAffiliate INTEGRATION WITH ZEN CART ##
    #######################################

    } // end if for determining if this was the checkout_success page.?> 
    Let me know if that helps. Remember, once you do this and find it is working you will need to remove that "checkout_success" directory (the one under your custom template NOT the core one!) for the override to work.

    If you need me to fix it for you let me know and I can take a look (I'll PM you the details).
    Eric
    20 Ways to Increase Sales Using Zen Cart
    Zen Cart contribs: Simple Google Analytics, Export Shipping Information

  5. #5
    Join Date
    Sep 2008
    Location
    San Diego
    Posts
    159
    Plugin Contributions
    0

    Default Re: Simple Google Analytics - Support

    I am sure I followed your instructions, have installled a couple of times on my site at createadesign.net, but I still get:
    The Google Analytics tracking code has not been detected on your website's home page
    on the Google site, and i have an inverted yellow triangle under Status
    any suggestions or help would be greatly appcreciated
    Rufusclc

  6. #6
    Join Date
    Dec 2005
    Posts
    1,509
    Plugin Contributions
    6

    Default Re: Simple Google Analytics - Support

    I went to your site and it looks like there is a problem near the bottom of the page (when I view source). The closing BODY and HTML tags are missing (which again leads me to to believe there is an issue with code near the bottom somewhere. Looks like the menu calls just stop after "Newsletter Unsubscribe" -- look around that area in your code for a possible error (maybe non-related to this mod?)

    Make sure you did Step 3 of the install (added the line of code that calls "google_analytics.php".

    Also make sure you add that line of code to the proper page. It looks like you are using a form of the Apple zen template. You will want to add the line of code in step 3 to the tpl_main_page.php in the same folder that your template is running from (like "apple").

    Finally, make sure you upload the "google_analytics" folder to your custom template directory as well (not the default one).

    Let me know if this helps.

    The only reason code won't show (tracking) with this mod is due to one of the three reasons above.
    Eric
    20 Ways to Increase Sales Using Zen Cart
    Zen Cart contribs: Simple Google Analytics, Export Shipping Information

 

 

Similar Threads

  1. v150 Simple Google Analytics .sql error !
    By Miff in forum All Other Contributions/Addons
    Replies: 0
    Last Post: 10 Feb 2012, 11:33 PM
  2. Simple Google Analytics-not working
    By RobertG in forum Templates, Stylesheets, Page Layout
    Replies: 6
    Last Post: 11 Nov 2010, 06:07 PM
  3. Simple (From Google) Analytics Install
    By DagLindt in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 26 May 2009, 10:46 PM
  4. Simple google analytics- help
    By Pet Herbal Remedies in forum All Other Contributions/Addons
    Replies: 4
    Last Post: 1 Oct 2008, 10:37 PM
  5. Simple Google Analytics not working
    By jvanree in forum All Other Contributions/Addons
    Replies: 0
    Last Post: 29 May 2008, 03:46 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg