Results 1 to 10 of 10
  1. #1
    Join Date
    Jul 2010
    Posts
    7
    Plugin Contributions
    0

    Default Affiliate Trail Integration

    Hello ZenCart Community!

    I've recently installed Zencart v1.3.9d with no addons.

    I am attempting to integrate a 3rd party affiliate program called Affiliate Trail to my shop. The integration seems simple enough, I just add this code to my confirmation page:

    <img src="http://www.yourdomain.com/affiliate/scripts/sale.php?TotalCost=
    XXXXXX.XX&OrderID=XXXXXX&ProductID=XXXXXX" width=1 height=1>

    Where src="the page on my domain"
    Where TotalCost= the orders total cost

    OrderID and ProductID aren't neccesary so the new code looks like:

    <img src="http://www.yourdomain.com/affiliate/scripts/sale.php?TotalCost= XXXXXX.XX" width=1 height=1>

    My question is therefore:

    What is the variable that Zencart uses as a "TotalCost" once an order is confirmed?

  2. #2
    Join Date
    Jan 2004
    Location
    N of San Antonio TX
    Posts
    9,690
    Plugin Contributions
    11

    Default Re: Affiliate Trail Integration

    A little help with colors.
    myZenCartHost.com - Zen Cart Certified, PCI Compatible Hosting by JEANDRET
    Free SSL & Domain with semi-annual and longer hosting. Updating 1.5.2 and Up.

  3. #3
    Join Date
    Jul 2010
    Posts
    7
    Plugin Contributions
    0

    Default Re: Affiliate Trail Integration

    I've tried and I've gotta say - they are slow to respond. I'm also a bit afraid of a standard "use the total cost variable for ZenCart" message instead of a strait answer.

  4. #4
    Join Date
    Jan 2004
    Location
    N of San Antonio TX
    Posts
    9,690
    Plugin Contributions
    11

    Default Re: Affiliate Trail Integration

    They are quick to list Zen Cart compatibility in one area of their site, but when it gets down to the actual list, ZC ain't there.

    Just because particular shopping cart is not listed, do not worry, the chances are that XxYyZz product will work 100%
    does not make me feel too confident.

    I'd also be concerned about the product working with newer versions of PHP and MySql.
    A little help with colors.
    myZenCartHost.com - Zen Cart Certified, PCI Compatible Hosting by JEANDRET
    Free SSL & Domain with semi-annual and longer hosting. Updating 1.5.2 and Up.

  5. #5
    Join Date
    Jul 2010
    Posts
    7
    Plugin Contributions
    0

    Default Re: Affiliate Trail Integration

    That lack of confidence is legitimate.

    "As stated earlier virtually 100% of shopping carts will work with Affiliate Trail"

    Tried to set this up for a friend using Godaddy Quick shopping cart and it was a no go. Their cart allows you to add some variables in the receipt, just not the total cost. Affiliate Trail should state this conditional.

  6. #6
    Join Date
    Jul 2010
    Posts
    7
    Plugin Contributions
    0

    Default Re: Affiliate Trail Integration

    Just received a response from affiliate trail. I haven't tested it yet but I will be confirming asap for others:

    "
    1. Locate the following file: /zencart/tpl_checkout_success_default.php.
    2. Find this code in the file: fields['orders_id']; ?>
    3. Copy/Paste the following code into the file (just under "fields['orders_id']; ?>")

    $affcode = $db->Execute("select * from " . TABLE_ORDERS_TOTAL . " where orders_id = '".(int)$orders->fields['orders_id']."' AND class = 'ot_subtotal'");
    $var1 = (number_format($affcode->fields['value'],2));
    $var2 = $affcode->fields['orders_id'];
    echo ("<img src=\"http://YOURSITE.com/affiliate/scripts/sale.php?TotalCost=$var1&OrderID=$var2\" width=1 height=1>");

    NOTE: Do not forget to edit last line in this code - http://YOURSITE.com should be replaced with your URL where you installed Affiliate Trail.
    "

  7. #7
    Join Date
    Jul 2010
    Posts
    7
    Plugin Contributions
    0

    Default Re: Affiliate Trail Integration

    Closest thing I've found to "fields['orders_id']; ?>" in tpl_checkout_success_default.php was "$zv_orders_id; ?>". Perhaps this version of zencart uses a different variable. I'm going to ask there techs what they think but I'm going to go ahead and test it to see what happens. Will post with a new update soon.

  8. #8
    Join Date
    Jan 2004
    Location
    N of San Antonio TX
    Posts
    9,690
    Plugin Contributions
    11

    Default Re: Affiliate Trail Integration

    Quote Originally Posted by AdrielGreene View Post
    1. Locate the following file: /zencart/tpl_checkout_success_default.php.
    Just that one line lets me know they don't have a clue.

    You may want to remind them that this file was modified with the release of 1.3.9 -- BUT -- that variable did not change
    Last edited by dbltoe; 27 Jul 2010 at 05:29 PM.
    A little help with colors.
    myZenCartHost.com - Zen Cart Certified, PCI Compatible Hosting by JEANDRET
    Free SSL & Domain with semi-annual and longer hosting. Updating 1.5.2 and Up.

  9. #9
    Join Date
    Jul 2010
    Posts
    7
    Plugin Contributions
    0

    Default Re: Affiliate Trail Integration

    I can confirm that the total cost and order variables are called by there code. I'm having an issue still though I don't think its ZenCart related. If it is a little cookie issue as I suspect I'll repost with some advice for anyone else searching for answers.

  10. #10
    Join Date
    Jul 2010
    Posts
    7
    Plugin Contributions
    0

    Default Re: Affiliate Trail Integration

    Great news everyone! I have affiliate trail configured and working! After the above was done I couldn't get affiliate trail to recognize sales. Ultimately I made a new account on my shop that had a different email from the one signed up in affiliate trail and that seems to have done the trick! Once I've used it for some time I'll come back here and let the community know what I think of it.

 

 

Similar Threads

  1. iDev Affiliate Custom Integration
    By independenteasel in forum All Other Contributions/Addons
    Replies: 0
    Last Post: 28 Oct 2011, 09:26 PM
  2. NATS Affiliate integration?
    By NadiaUSA in forum All Other Contributions/Addons
    Replies: 0
    Last Post: 23 Feb 2011, 10:15 PM
  3. Omnistar Affiliate Integration
    By indoubt in forum Built-in Shipping and Payment Modules
    Replies: 0
    Last Post: 10 Feb 2010, 05:41 PM
  4. Post Affiliate Free Integration
    By IncrediBody in forum General Questions
    Replies: 2
    Last Post: 1 Nov 2006, 03:44 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