Results 1 to 5 of 5
  1. #1
    Join Date
    Jan 2014
    Location
    new york
    Posts
    3
    Plugin Contributions
    0

    Default How to install Shopzilla revenue tracking script?

    I'am currently using zen cart, and I want to do marketing with shopzilla. They want to track my website order revenue.

    They asked me to install

    <script language="javascript">
    <!--
    /* Performance Tracking Data */
    var mid = '';
    var cust_type = '';
    var order_value = '';
    var order_id = '';
    var units_ordered = '';
    //-->
    </script>
    <script language="javascript" src="https://www.shopzilla. com/css/roi_tracker.js"></
    script>

    in which file would i copy and paste this script to track the order revenue?

  2. #2
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: How to install Shopzilla revenue tracking script?

    Did they tell you which page they want this on? I would think the order confirmation or checkout_success page would be it, but you need direction from them. In any case, you would not paste the code into any PHP file; you would rename them to start with jscript_ and save them in one of the /jscript/ folders, depending on what page they are needed in. The /jscript/ folders for a template or page will autoload all files that start with jscript_.
    jscript_shopzilla_data.js
    (do not include <script> tags in this file)
    Code:
    <!--
    /* Performance Tracking Data */
    var mid = '';
    var cust_type = '';
    var order_value = '';
    var order_id = '';
    var units_ordered = '';
    //-->
    jscript_shopzilla_tracker.js
    Code:
    <script language="javascript" src="https://www.shopzilla. com/css/roi_tracker.js"></
    script>
    I'm not certain of the way to call an external script in this format, so anyone with authoritative info, please chime in.

    You also need to get the current order info into the script variables, which is another task. You might need to name the file jscript_shopzilla_data.php and include some PHP code to insert the variables.
    Last edited by gjh42; 16 Jan 2014 at 07:45 PM.

  3. #3
    Join Date
    Jan 2014
    Location
    new york
    Posts
    3
    Plugin Contributions
    0

    Default Re: How to install Shopzilla revenue tracking script?

    Quote Originally Posted by gjh42 View Post
    Did they tell you which page they want this on? I would think the order confirmation or checkout_success page would be it, but you need direction from them. In any case, you would not paste the code into any PHP file; you would rename them to start with jscript_ and save them in one of the /jscript/ folders, depending on what page they are needed in. The /jscript/ folders for a template or page will autoload all files that start with jscript_.
    jscript_shopzilla_data.js
    (do not include <script> tags in this file)
    Code:
    <!--
    /* Performance Tracking Data */
    var mid = '';
    var cust_type = '';
    var order_value = '';
    var order_id = '';
    var units_ordered = '';
    //-->
    jscript_shopzilla_tracker.js
    Code:
    <script language="javascript" src="https://www.shopzilla. com/css/roi_tracker.js"></
    script>
    I'm not certain of the way to call an external script in this format, so anyone with authoritative info, please chime in.

    You also need to get the current order info into the script variables, which is another task. You might need to name the file jscript_shopzilla_data.php and include some PHP code to insert the variables.
    Hello,

    Thank you GJH42 for the quick response, they asked me to paste the code to;

    "Yes, the code would need to be placed on the order confirmation/thank you page as explained in the previous e-mails."

    Are the files from /public_html/includes/templates/classic/templates,

    either "tpl_checkout_confirmation_default.php" or "tpl_checkout_success_default.php"

    I apologize for these questions I'am fairly new.

    Thank you

  4. #4
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: How to install Shopzilla revenue tracking script?

    I'm not certain which of those pages would be correct... but checkout_confirmation sends the info, while checkout_success may no longer have all of it.
    In any case, you do not need to edit any existing PHP files, but put your added script code in jscript_ files. They would likely go in /includes/modules/pages/checkout_confirmation/, named as indicated above.

    See the wiki for complete info on adding javascript:
    http://www.zen-cart.com/wiki/index.p...s_-_Javascript

  5. #5
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: How to install Shopzilla revenue tracking script?

    On reflection, I think the second file would be

    jscript_shopzilla_tracker.php
    PHP Code:
    <script language="javascript" src="https://www.shopzilla. com/css/roi_tracker.js"></
    script
    The first file would also need to have the .php extension so that PHP variables can be processed.

 

 

Similar Threads

  1. Shopzilla Tracking Code Placement?
    By sartor in forum All Other Contributions/Addons
    Replies: 12
    Last Post: 5 Sep 2011, 09:20 AM
  2. Script for Shopzilla "performance tracking"
    By marvin in forum All Other Contributions/Addons
    Replies: 0
    Last Post: 10 Nov 2009, 04:28 AM
  3. Shopzilla tracking in Worldpay integration
    By crazycucumber in forum Addon Payment Modules
    Replies: 1
    Last Post: 24 Apr 2007, 09:13 AM
  4. Tracking Code placement - Shopzilla
    By crazycucumber in forum General Questions
    Replies: 0
    Last Post: 3 Apr 2007, 08:29 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