Language switcher

#languages]

–Hidden comment

Use attributes in format region_from and region_to= to change the languages showing in language switcher.
Available regions are:
europe_from europe_to
asia_from asia_to
mideast_from mideast_to
america_from america_to

Example:
europe_from=0 europe_to=22 will put all languages (ordered in language switcher settings) from 1 to 21 to Europe region:
asia_from=22 asia_to=25 will put all languages from 23 to 24 (so only 2) into Asia region.

Integrations

Maximize the value of your existing affiliate marketing software and extend its possibilities with a wide range of integrations, plugins and apps. All built to improve the strong foundations of Post Affiliate Pro.

ThriveCart

The no. 1 cart software that grows your income from existing traffic and pays for itself many times over with high converting checkout pages, upsells & affiliate campaigns.

ThriveCart (https://thrivecart.com/) is a modern shopping cart.

Integration with ThriveCart is made by using custom variables and webhook with our built-in plugin.

It is possible to track total cost, product IDs, order ID, customer name and email (supports Lifetime Commissions).

Custom variables

The idea is to set your ThriveCart links (to checkout) with an extra value. The value would be the tracking cookie value (visitorId) which we will need in webhook to track a sale later.
To do this you have to make sure each ThriveCart link has a unique ID. If it does not have an ID already, you have to add a unique one. The HTML code of your link should then look like this:

<a id="link-unique-id" href="http://webactix.thrivecart.com/example-product/">Example product</a>

As you can see, the links has “link-unique-id” set. We will work with this.

The second step is to add the following code to a page with your ThriveCart links. If the page has more buttons you have to add such a code for each (with specific link unique ID):

<script id="pap_x2s6df8d" src="https://URL_TO_PostAffiliatePro/scripts/trackjs.js" type="text/javascript"></script>
<script type="text/javascript">
PostAffTracker.writeCookieToLink('link-unique-id', 'passthrough[visitorid]');
</script>

What is this good for? The code will load tracking cookie value, then it will search for a link with ID “link-unique-id” and add the cookie value to the link with parameter name passthrough[visitorid] – this is the custom field ThriveCart allows us to use.

ThriveCart plugin

The next step is to activate and to configure your ThriveCart plugin. Login to your merchant panel and navigate to Configuration > Plugins. Find and activate the plugin ThriveCart webhook handling.

Now, to configure the plugin you need a secret word value from your ThriveCart so login to its admin panel and navigate to Settings > API & Webhooks > ThriveCart order validation and copy the secret word from there. Set the copied secret to your plugin in Post Affiliate Pro.

Webhook setup

The last step is to configure a webhook to send data to your plugin in Post Affiliate Pro. In ThriveCart admin navigate to Settings > API & Webhooks > Webhooks & notifications and create a new webhook – set whatever name you like and use this URL:

https://URL_TO_PostAffiliatePro/plugins/ThriveCart/thrivecart.php

That’s it. Your store has just been integrated.

Do not forget to integrate your site with the click tracking code too.

If you do not want to use webhooks, you can follow these steps instead:

Shop setup

To be able to track a sale you have to enable Success URL in each of your products. ThriveCart sends order details there, so we will integrate the sale tracking code there. The Success URL should be able to read URL params, that is the only requirement.

To setup Success URL of a product navigate to Products and edit it. Navigate to Product > Fulfillment section and setup a Success URL. The same for Bump > Fulfillment in case you use it.

Sale tracking – per order

If you want to track per order commission, use the following code and place it to you Success page:

<script id="pap_x2s6df8d" src="https://URL_TO_PostAffiliatePro/scripts/trackjs.js" type="text/javascript"></script>
<script type="text/javascript">
PostAffTracker.setAccountId('Account_ID');
var sale = PostAffTracker.createSale();
sale.setTotalCost('<?php echo ($_GET['thrivecart']['order_total']/100) ?>');
sale.setOrderID('<?php $_GET['thrivecart']['order_id'] ?>');
sale.setProductID('<?php $_GET['thrivecart']['product_id'] ?>');

PostAffTracker.register();
</script>

The method used for sale tracking is PHP. If your site does not work with PHP, use a different approach of reading URL parameters. You can contact us in case you need a help with it.

Per product tracking

In case you want to track each product separately, use the following code. The method uses PHP code:

<script id="pap_x2s6df8d" src="https://URL_TO_PostAffiliatePro/scripts/trackjs.js" type="text/javascript"></script>
<script type="text/javascript">
PostAffTracker.setAccountId('Account_ID');
<?php
$i = 0;
foreach ($_GET['thrivecart']['order'] as $product) {
  echo "var sale = PostAffTracker.createSale();";
  echo "sale.setTotalCost('".($product['p']/100)."');";
  echo "sale.setOrderID('".$_GET['thrivecart']['order_id']."($i)');";
  echo "sale.setProductID('".$product['id']."');";
}
?>
PostAffTracker.register();
</script>

That’s it. Do not forget to integrate your site with the click tracking code.

If you want to track additional values, you can also use currency:

$_GET['thrivecart']['order_currency']

and customer email:

$_GET['thrivecart']['customer']['email']

and customer name:

$_GET['thrivecart']['customer']['firstname']
$_GET['thrivecart']['customer']['lastname']
Back to Integrations Create account for FREE

Our website uses cookies. By continuing we assume your permission to deploy cookies as detailed in our privacy and cookies policy.

×

Schedule a one-on-one call and discover how Post Affiliate Pro can benefit your business.

We’re available on multiple dates

Schedule a call