View Single Post
  #42  
Old 03-04-2013, 11:36 AM
Matt Ecwid's Avatar
Matt Ecwid Matt Ecwid is offline
Ecwid Team
 
Join Date: Oct 2011
Posts: 4,947
Default

Quote:
Originally Posted by Anabolic Designs View Post
Exactly. They are partner pages from all over the world (athletes, personal trainers, small health clubs).

We want to install our store into their FB pages, and track the sales and commissions.

If we can do this without an affiliate package as complicated as PAP, please tell me how, as that is exactly all we want to do.



Exactly this is correct.

Any joy on this one Matvey?
Thank you for the details.

Basing on your needs, I think the following integration will fit:
1. Since you want to put your whole store on a partner site, you will need to follow the instruction from the point #4 fomr this article:
http://kb.ecwid.com/w/page/52731315/...ffiliate%20Pro

Here it goes:

Quote:
1) Find an affiliate ID in the affiliates list in your merchant panel (see the 'Affiliate manager' window):
Let's say the affiliate ID is 'aff1' (you should find the exact ID in your PAP backend)

Quote:
2) Specify it in the clicks tracking code. The code will look like this (the changed part is in bold):
I put it into your tracking code here:

Code:
<script type="text/javascript"><!--
document.write(unescape("%3Cscript id='pap_x2s6df8d' src='" + (("https:" == document.location.protocol) ? "https://" : "http://") + 
"anabolic-designs.postaffiliatepro.com/scripts/trackjs.js' type='text/javascript'%3E%3C/script%3E"));//-->
</script>
<script type="text/javascript"><!--
PostAffTracker.setAccountId('default1');
var AffiliateID = 'aff1';
try {
PostAffTracker.track();
} catch (err) { }
//-->
</script>
Done - it's the tracking code.


Quote:
3) Grab Ecwid integration code from your Ecwid control panel and add the modified clicks tracking code, combine them together. The code is ready, you can give it to your affiliate.
So, as this step says, let's add the tracking code snippet to your store integration code. The result:
Code:
<div>
<script type="text/javascript" src="https://app.ecwid.com/script.js?1575325" charset="utf-8"></script>
<script type="text/javascript"> xProductBrowser("categoriesPerRow=3","views=grid(3 ,3) list(10) table(20)","categoryView=grid","searchView=list"," style="); </script>
<noscript>Your browser does not support JavaScript. Please proceed to <a href="https://anabolic-designs.ecwid.com">HTML version of Anabolic Designs™ | Perform and Transform</a></noscript>
</div>

<script type="text/javascript"><!--
document.write(unescape("%3Cscript id='pap_x2s6df8d' src='" + (("https:" == document.location.protocol) ? "https://" : "http://") + 
"anabolic-designs.postaffiliatepro.com/scripts/trackjs.js' type='text/javascript'%3E%3C/script%3E"));//-->
</script>
<script type="text/javascript"><!--
PostAffTracker.setAccountId('default1');
var AffiliateID = 'aff1';
try {
PostAffTracker.track();
} catch (err) { }
//-->
</script>
That's it - the code above contains the both your store widgets and the affiliate tracking code so you can put it anywhere: in any site or blog as well as in Ecwid FB app - it will work.



Next, you want to track sales coming from that storefront. Here, you will need to follow the instructions from the point #5 of the abovementioned article:
Quote:
5. Add sales tracking code into your Ecwid store.
Regardless of where the clicks tracking code is placed, you'll need to integrate the sales tracking code into your "Thank you for your order" page in Ecwid. After being placed in your control panel, this code will track sales for all of your affiliates.
As far as I can see, you got the sales tracking code:
Code:
<script id="pap_x2s6df8d" src="https://anabolic-designs.postaffiliatepro.com/scripts/salejs.php" type="text/javascript"></script>
<script type="text/javascript">
PostAffTracker.setAccountId('default1');

var sale = PostAffTracker.createSale();
sale.setTotalCost("%order_total%");
sale.setOrderID("%order_id%");

PostAffTracker.register();
</script>
So, all you need to do is to put that code into your Ecwid control panel (System Settings → General → Cart → Checkout Settings → Tracking code on "Thank you for your order" page). That's it.



Notes:
1) As I mentioned above, the sales tracking approach uses the "Tracking code on Thank you for your order page" feature. That feature basically works this way: when the order confirmation page opens, the javascript code you placed there executes. So, for the sales tracking code working it is crucial that the last checkout page ('Thank you page') is reached. It always happens when an offline payment is used (e.g. 'Phone ordering'). As to online payment methods like PayPal, sometimes the page may not be reached. In particular, when a merchant uses the 'Custom tab content' approach on Facebook, the orders placed via PayPal will not be tracked because of the limitation our FB app currently has: if a customer returns to the custom tab from PayPal, they don't reach the confirmation page - rather do they open the main store page. The clicks tracking code, however, will work fine.

The good news is we're currently working on some changes in our FB app that should fix that limitation. They will be released in one of the upcoming Ecwid versions.

2) In order to track from what page an order comes (in addition to the PAP tracking or instead of it), you can also use this approach:
http://kb.ecwid.com/w/page/52602187/...%20came%20from
This way, you will be able to find out the sale source even if PAP tracking doesn't execute on the thank you for your order page.
__________________
Matt K
Ecwid Team

Ecwid Guide for Beginners

Ecwid Help Center

Ecwid video tutorials