ShareASale Affiliate

Hi Everyone, I am trying to setup affiliate marketing with Shareasale and I would really appreciate any help. This is the email I received from them:



This is for PayPal

Once you have the Payment Data Transfer system running, you can use the following tracking codes in your Auto-Return script:





PHP

echo (“https://shareasale.com/sale.cfm?amount=$amount&tracking=$tx_token&transtype=SALE&merchantID=XXXX\” width="1" height="1">");

Where you replace XXXX with your ShareASale merchant ID number.



This is for Google Checkout.



[url]https://help.shareasale.com/index.php?_m=knowledgebase&_a=viewarticle&kbarticleid=127&nav=0,30,31[/url]



Thank you,

Albert

Hello… I was wondering if you got the ShareASale tracking code setup successfully… I’m struggling with how to implement the tracking code for regular credit card transactions in 2.12.



Any guidance would be appreciated.

Hello



As far as I understood, you want to add sales tracking code. If so, please refer to this article in our Knowledge Base in order to implement this feature: [url]CS-Cart Documentation — CS-Cart 4.15.x documentation





Anastasiya Kozlova

CS-Cart Support team

Thank you very much… the only other question I have is what smarty variables do I use for the order subtotal (preferably after discounts) and the order number?



The code that I’m trying to install is as follows…



I created a file called

order_confirmation.override.tpl

And put this in it.





The problem is I forget what else I changed.
I'll continue to look. What this file does is inserts it in the proper place in the order_confirmation page. I think I used mychanges.
I had this tested with all my payment methods and confirmed by share-a-sale.
Bob

Thank you! I’ll give it a try…

@egodshall



were you able to make this work, because I am having a problem with this. I was told by the ShareASale that there is a problem for passing the variable Total order and Order number. They just want to know the right variable name.



They told me X-CART has a solution such as:



Tracking Code details for XCart



X-Cart file to edit:



skin1/customer/main/order_message.tpl

Insert the tracking code:





Where you replace XXXX with your merchant ID number.



Just below the lines:

{if $active_modules.Interneka ne “”} { include file=“modules/Interneka/interneka_tags.tpl” } {/if}

.



And they never heard about CS-CART. I am kind of disappointed. I love the CS-CART and I do have 4 licences,and I believe CS-cart it is much much better than X-CART. And we should have a better voice out there, as far as who is the CS-CART.

And when it comes to this sort of issues I think every little step will help.



I know, maybe I am little bit over react on this matter, but believe me, I couldn’t keep this anymore.



Anyhow, my point is if X-cart recognized and they have a solution CS-cart must have too.



Thank you,




[quote name=‘egodshall’]Thank you very much… the only other question I have is what smarty variables do I use for the order subtotal (preferably after discounts) and the order number?



The code that I’m trying to install is as follows…



[/QUOTE]

CS-CART gave me these instructions. I had it validated by shareasale.

Any reference to a skin, you just substitute yours.

Bob


  1. Enable the “My changes” add-on on the “Add-ons” page in your store administration panel and then create the following directories path in the root directory of your CS-Cart installation:

    “skins/toy_store/customer/addons/my_changes/hooks/checkout”
  2. Create the following directories path in the root directory of your CS-Cart installation:

    “skins/[CUSTOMER_ACTIVE_SKIN]/customer/addons/my_changes/hooks/checkout”, where [CUSTOMER_ACTIVE_SKIN] is an active skin of your storefront.
  3. Create the “order_confirmation.override.tpl” file in the “skins/[CUSTOMER_ACTIVE_SKIN]/customer/addons/my_changes/hooks/checkout” directory with the following part of code:






) Save the file.
4) Clean up the template cache. In order to do it you need to log in to your store administration panel and to add the "?cc" or "&cc" text to the end of the path on any of the store pages in the browser.

Additional note:
The "order_confirmation.tpl" page is the complete page. It is displayed after order placed. In order to use the hook you need to create the order_confirmation.override.tpl file. If you do not use the hook you can edit code in the complete.tpl

Hi Bob,

I will try it now, and I will post the result.



Thank you

I got an error when I used as you instructed. this is the error



HomeYour order has been received



Fatal error: Smarty error: [in addons/my_changes/hooks/checkout/order_confirmation.override.tpl line 4]: syntax error: unrecognized tag: $ order_info.order_id (Smarty_Compiler.class.php, line 445) in /home/howardmi/public_html/lib/templater/Smarty.class.php on line 1095








[quote name='pbannette']CS-CART gave me these instructions. I had it validated by shareasale.
Any reference to a skin, you just substitute yours.
Bob

1) Enable the "My changes" add-on on the "Add-ons" page in your store administration panel and then create the following directories path in the root directory of your CS-Cart installation:
"skins/toy_store/customer/addons/my_changes/hooks/checkout"
2) Create the following directories path in the root directory of your CS-Cart installation:
"skins/[CUSTOMER_ACTIVE_SKIN]/customer/addons/my_changes/hooks/checkout", where [CUSTOMER_ACTIVE_SKIN] is an active skin of your storefront.
3) Create the "order_confirmation.override.tpl" file in the "skins/[CUSTOMER_ACTIVE_SKIN]/customer/addons/my_changes/hooks/checkout" directory with the following part of code:





) Save the file.
4) Clean up the template cache. In order to do it you need to log in to your store administration panel and to add the "?cc" or "&cc" text to the end of the path on any of the store pages in the browser.

Additional note:
The "order_confirmation.tpl" page is the complete page. It is displayed after order placed. In order to use the hook you need to create the order_confirmation.override.tpl file. If you do not use the hook you can edit code in the complete.tpl[/QUOTE]

Hi,

I don’t get an error.

I just copied the code and it is this:





Maybe you have a space after $. I have not spaces. If you have spaces, remove them. and see what happens.
I know what I have works since shareasale made me confirm it works with all payment methods i use.
The reason is that the code from shareasale affiliates went to my old non cs-cart site, which is still running. I have some pages with links to my new cs-cart store. I did not want affiliates to loose a potential commission if the customer first went to my old store and clicked on a link to my new store and purchased something. I wanted the affiliate to get their commission from either store.
Shareasale changed the code so that this would happen. I had to test it to make sure it worked, and it did.
Bob

I am using 2.1.3 version, but should be ok for your version.
Code tags are your friend.

[quote name=‘The Tool’]Code tags are your friend.[/quote]

```php ```

Hi Bob,



I just want to say Thank you for sharing this with all of us. And I think this is the biggest different between CS-CART community and other carts out there.



Albert