Page 1 of 2 12 LastLast
Results 1 to 10 of 30

Hybrid View

  1. #1
    Join Date
    Sep 2008
    Posts
    21
    Plugin Contributions
    0

    Default Jam Jrox integration - can't get it to record

    I believe I set up the zen cart integration for Jrox as described, but once the checkout_success dir and tpl_footer.php file are in place I get a blank page instead of checkout success.

    After processing a transaction Zen Cart recognizes the transaction, but no commission shows up, so I have the feeling the information is not being passes along or something is interfering with the script.

  2. #2
    Join Date
    Mar 2008
    Location
    Cape Town & London (depends on the season)
    Posts
    2,975
    Plugin Contributions
    0

    Default Re: Jam Jrox integration

    Did you visit your site via an affiliate link first? (In other words, set up a test affiliate account, build a link, click that link, then do a test purchase in your store?)

    If you are testing correctly, and get a blank screen, it could be that you have made some code errors in

    /templates/your_template/checkout_success/tpl_footer.php

    ... when you inserted the tracking code.

    Make sure all PHP is clean.
    Make sure directory paths are correct.
    Make sure you do a test purchase off an "affiliate link".

  3. #3
    Join Date
    Sep 2008
    Posts
    21
    Plugin Contributions
    0

    Default Re: Jam Jrox integration

    Yes I did do that, and the tpl_footer.php code is here. All I did was change the url where you see for your viewing I wrote "IputMySitePathHere"

    PHP Code:
    <?php
    /**
     * Common Template - tpl_footer.php
     *
     * this file can be copied to /templates/your_template_dir/pagename<br />
     * example: to override the privacy page<br />
     * make a directory /templates/my_template/privacy<br />
     * copy /templates/templates_defaults/common/tpl_footer.php to /templates/my_template/privacy/tpl_footer.php<br />
     * to override the global settings and turn off the footer un-comment the following line:<br />
     * <br />
     * $flag_disable_footer = true;<br />
     *
     * @package templateSystem
     * @copyright Copyright 2003-2005 Zen Cart Development Team
     * @copyright Portions Copyright 2003 osCommerce
     * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
     * @version $Id: tpl_footer.php 3183 2006-03-14 07:58:59Z birdbrain $
     */
    require(DIR_WS_MODULES zen_get_module_directory('footer.php'));

    if (!
    $flag_disable_footer) {

    ?>

    <!--bof-navigation display -->
    <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>
    <!--eof-navigation display -->

    <!--bof-ip address display -->
    <?php
    if (SHOW_FOOTER_IP == '1') {
    ?>
    <div id="siteinfoIP"><?php echo TEXT_YOUR_IP_ADDRESS '  ' $_SERVER['REMOTE_ADDR']; ?></div>
    <?php
    }
    ?>
    <!--eof-ip address display -->

    <!--bof-banner #5 display -->
    <?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
        
    }
      }
    ?>
    <!--eof-banner #5 display -->

    <!--bof- site copyright display -->
    <div id="siteinfoLegal" class="legalCopyright"><?php echo FOOTER_TEXT_BODY?></div>
    <!--eof- site copyright display -->

    <?php
    // flag_disable_footer
    ##########################################
    ## START JAM INTEGRATION WITH ZEN CART  ##
    ## ZC Integration code by DrByte 8/2006 ##
    ##########################################

    if (isset($zv_orders_id) && (int)$zv_orders_id && isset($order_summary) && is_array($order_summary)) {

      if (!isset(
    $_SESSION['affiliate_order_id']) || $_SESSION['affiliate_order_id'] != $zv_orders_id ) {

          
    $_SESSION['affiliate_order_id'] = $zv_orders_id;

         
    $commissionable_order_formatted number_format($order_summary['commissionable_order'], 2'.''');

         echo 
    '<script language="javascript" type="text/javascript" src="http://IputMySitePathHere/affiliates/sale.php?amount=' $commissionable_order_formatted '&trans_id=' $order_summary['order_number'] . '"></script>';

        }

    }

    #######################################
    ## END JAM INTEGRATION WITH ZEN CART ##
    #######################################

    ?>

  4. #4
    Join Date
    Mar 2008
    Location
    Cape Town & London (depends on the season)
    Posts
    2,975
    Plugin Contributions
    0

    Default Re: Jam Jrox integration

    Looks like you are using Dr Byte's LATER version of the integration code.

    I use the older version, which (Dr Byte tells me) is just as reliable.

    PLEASE NOTE: the code below has a small modification from the original code by Dr Byte, that also allows the subtraction of Gift Voucher payment portion (if applicable) during checkout. I had long debates about this and you may care to look up my posts on this subject.

    In any event, here's the code I use:-

    PHP Code:
    ## START JAM INTEGRATION WITH ZEN CART ##
    ## ZC Integration code by DrByte 8/2006 ##
    ##########################################
    if ((int)$orders_id 0) {
    $JAM $db->Execute("select class, value from " TABLE_ORDERS_TOTAL " where orders_id = '".(int)$orders_id."' AND class in ('ot_coupon', 'ot_gv', 'ot_subtotal', 'ot_group_pricing')");
    while (!
    $JAM->EOF) {
    switch (
    $JAM->fields['class']) {
    case 
    'ot_subtotal':
    $order_subtotal $JAM->fields['value'];
    break;
    case 
    'ot_coupon':
    $coupon_amount $JAM->fields['value'];
    break;
    case 
    'ot_group_pricing':
    $group_pricing_amount $JAM->fields['value'];
    break;
    case 
    'ot_gv':
    $gv_amount $JAM->fields['value'];
    break;
    }
    $JAM->MoveNext();
    }
    $commissionable_order = ($order_subtotal $gv_amount $coupon_amount $group_pricing_amount);
    $commissionable_order number_format($commissionable_order,2,'.','');
    echo 
    "<script language=\"JavaScript\" type=\"text/javascript\" src=\"https://www.IputMySitePathHere/affiliates/sale.php?amount=$commissionable_order&trans_id=$orders_id\"></script></td></tr>

    </table>"
    ;
    }
    #######################################
    ## END JAM INTEGRATION WITH ZEN CART ##
    #######################################

    ?> 

  5. #5
    Join Date
    Sep 2008
    Posts
    21
    Plugin Contributions
    0

    Default Re: Jam Jrox integration

    Nope that didn't work.
    Is $flag_disable_footer = true; supposed to be uncommented? Anyhow I've tried it both ways with both sets of code and it didn't work, so I know that's not the problem.

    I'm going to try removing google analytics to see what that does, as I've heard of some js conflicts with other modules.

  6. #6
    Join Date
    Sep 2008
    Posts
    21
    Plugin Contributions
    0

    Default Re: Jam Jrox integration

    That either I tried it without the analytics script in place. I'm completely baffled at this point

  7. #7
    Join Date
    Jan 2004
    Posts
    66,443
    Plugin Contributions
    279

    Default Re: Jam Jrox integration

    Quote Originally Posted by jasonk View Post
    ... I get a blank page ...
    Related FAQ: https://www.zen-cart.com/tutorials/index.php?article=82
    esp step 2a
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  8. #8
    Join Date
    Sep 2008
    Posts
    21
    Plugin Contributions
    0

    Default Re: Jam Jrox integration

    Thanks, but the error only happens when the template override file exists.

    And after using the debugger, it doesn't seem to be an error at all as there was no file added to the cache.

  9. #9
    Join Date
    Jan 2004
    Posts
    66,443
    Plugin Contributions
    279

    Default Re: Jam Jrox integration

    Quote Originally Posted by jasonk View Post
    Thanks, but the error only happens when the template override file exists.
    Then the error would be a result of a PHP syntax error in the file as it exists on the server.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  10. #10
    Join Date
    Sep 2008
    Posts
    21
    Plugin Contributions
    0

    Default Re: Jam Jrox integration

    so the debugger would give no error result if there was a syntax error?

    I initially only used the actual file downloaded from this page
    http://jam.jrox.com/docs/index.php?article=228
    the url was the only change as indicated in the instructions

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. Jam Jrox Affiliate Integration & Customization Questions...
    By JabberWocky in forum All Other Contributions/Addons
    Replies: 9
    Last Post: 22 Apr 2011, 11:41 PM
  2. JROX JAM Affiliate program integration
    By eazy in forum All Other Contributions/Addons
    Replies: 15
    Last Post: 27 Jan 2011, 01:07 AM
  3. Jrox JAM integration
    By Berzerk in forum General Questions
    Replies: 8
    Last Post: 11 Jan 2011, 08:09 AM
  4. New Jrox JAM integration code for 1.3.8
    By schoolboy in forum General Questions
    Replies: 16
    Last Post: 4 Aug 2009, 01:07 PM

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