PrestaShop
Integrate Post Affiliate Pro with PrestaShop using a free module for seamless online store operations. Configure tracking codes and PayPal integration by editing specific PHP files. Ensure compatibility with PrestaShop 1.7.6.7.
PrestaShop integration
An open source ecommerce software that helps to create a successful online stores for free.
Fast, efficient and easy to use, PrestaShop’s free e-commerce solution provides everything you need to open, operate and maintain a successful online store.
How to integrate PostAffiliatePro with PrestaShop
The easiest way to integrate PrestaShop with Post Affiliate Pro (Network) is to use our integration module (free downloadable module by Quality Unit, version 3.20.4)
It is a standard PrestaShop module which you can install as any other module. Configure it after installation and integration is done. The plugin automatically integrates all the needed integration codes.
NOTES:
- If you are using performance setting “Move JavaScript to the end” in your PrestaShop, please turn it off as it breaks down the tracking functionality.
- The module is currently tested with PrestaShop version 1.7.6.7. The module might very well work with newer versions as well, we just didn’t test it or we simply haven’t updated this note yet.
Localization of file and add tracking code (older versions of PrestaShop)
Connect to your FTP and find the file order-confirmation.php
. This file process orders. Download it, open it in any text editor and find this line:
'HOOK_PAYMENT_RETURN' => Hook::paymentReturn(intval($id_order), intval($id_module))));
Add this tracking code after the line mentioned above. The code is for tracking total cost and order ID:
?><script id="pap_x2s6df8d" src="https://URL_TO_PostAffiliatePro/scripts/trackjs.js" type="text/javascript"></script>
<script type="text/javascript">
var sale = PostAffTracker.createSale();
sale.setTotalCost('<?php echo $order->total_paid_real; ?>');
sale.setOrderID('<?php echo $id_order; ?>');
PostAffTracker.register();
</script>
<?php
Now save the file and upload it back to FTP.
PayPal part 2
Next thing to do is to find file validation.php
, also inside shop/modules/paypal/ . Edit this file and find this line of code:
$ch = curl_init('https://' . $paypalServer . '/cgi-bin/webscr');
Put following code right after that line of code:
/* PAP4 integration */
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "https://URL_TO_PostAffiliatePro/plugins/PayPal/paypal.php");
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, $_POST);
curl_exec($ch);
/* end of PAP4 integration */
Also, you have to activate PayPal IPN plugin inside of your Merchant panel > Plugins. Edit the plugin settings and change separator to ||
.
PayPal part 3
Last thing to do is to find this line of code inside validation.php
:
if ($result == 'VERIFIED') {
Put following code right after that line of code:
/* PAP INTEGRATION */
$separator = '||';
if ($_POST['custom'] != '') {
$explodedCustomValue = explode($separator, $_POST['custom'], 2);
if (count($explodedCustomValue) == 2) {
$_REQUEST['custom'] = $_POST['custom'] = $explodedCustomValue[0];
}
}
/* END PAP INTEGRATION */
That’s all necessary in order to integrate PrestaShop + PayPal.
What is PrestaShop?
PrestaShop is an open-source e-commerce platform that allows businesses to create and manage their online stores with ease. Renowned for its flexibility, PrestaShop offers extensive customization through a wide array of themes and modules. This enables businesses to tailor their online storefronts to meet specific needs and branding requirements. Equipped with features like catalog management, seamless order processing, support for multiple payment gateways, and integrated SEO tools, PrestaShop is a robust solution ideal for small to medium-sized enterprises looking to establish or enhance their online presence.
PrestaShop was founded in 2007 by Igor Schlumberger and Bruno Lévêque in Paris, France. What began as a student project rapidly evolved into a leading e-commerce platform due to its customizable open-source model. Over the years, PrestaShop has released numerous versions, continually enhancing its functionality and user-friendly interface to keep pace with the evolving needs of online retailers.
PrestaShop is designed with small to medium-sized retailers, entrepreneurs, and startups in mind—those seeking a customizable online store solution without prohibitive costs. With its multi-language and multi-currency capabilities, PrestaShop is also well-suited for global businesses aiming to provide localized shopping experiences. Developers favor PrestaShop for its open-source nature, which offers comprehensive flexibility to modify and extend the platform’s capabilities.
Key Features of PrestaShop
- Open-Source Flexibility: Access and modify the source code to create a unique e-commerce platform tailored to your business needs.
- Extensive Customization Options: Choose from thousands of add-ons and templates to personalize your online store’s appearance and functionality.
- Multilingual and Multicurrency Support: Reach a global audience with support for multiple languages and currencies.
- Integrated SEO and Marketing Tools: Improve your store’s visibility and attract more customers with built-in search engine optimization and marketing features.
- Strong Community and Marketplace Support: Benefit from a vibrant community of developers and access a wide range of resources and extensions in the PrestaShop Marketplace.
Pricing Options for PrestaShop
PrestaShop is free to download and use, thanks to its open-source model. However, users should consider additional costs associated with operating an online store, such as web hosting, premium themes, and modules. While PrestaShop provides a cost-effective entry point into e-commerce, investing in quality hosting services and necessary customizations can add to operational expenses.
User Insights on PrestaShop
Pros:
- High Customization and Scalability: Tailor your store extensively to match your business requirements.
- Strong Community Support: Access a wealth of knowledge and assistance from the PrestaShop community.
- Cost-Effective Solution: Start your e-commerce venture without significant upfront software costs.
Cons:
- Learning Curve: New users may need time to become familiar with the platform’s features and customization options.
- Additional Costs for Add-Ons: Premium modules and themes, which may be necessary for certain functionalities, can increase expenses.
Overall, users appreciate PrestaShop for enabling a customized shopping experience at a reasonable cost, making it a popular choice for businesses looking to establish a strong online presence.
PrestaShop Reviews and Tutorials on YouTube
PrestaShop 2023 Review – Comprehensive Overview
A detailed examination of PrestaShop’s features and customization capabilities.Is PrestaShop Still Worth It in 2023?
An analysis of PrestaShop’s relevance and effectiveness for modern businesses.PrestaShop for Beginners – 2023 Edition
A step-by-step guide for newcomers on setting up an online store with PrestaShop.
Alternatives to PrestaShop
If you’re exploring other e-commerce platforms, consider these alternatives:
- Shopify: An easy-to-use, subscription-based hosted solution ideal for businesses seeking simplicity and quick setup.
- Magento (Adobe Commerce): Offers high customization suited for large enterprises but requires technical expertise to manage effectively.
- WooCommerce: A flexible e-commerce plugin for WordPress users looking to add online store functionality to their existing websites.
- BigCommerce: Designed for scalability, supporting complex and large-scale e-commerce needs with built-in features.
- OpenCart: A straightforward platform suitable for small businesses looking for simplicity and ease of customization without extensive technical requirements.
Frequently asked questions
- What is PrestaShop?
PrestaShop is an open-source e-commerce platform that allows businesses to create and manage online stores with extensive customization, multi-language support, and integrated SEO tools. It's ideal for small to medium-sized enterprises seeking flexible, cost-effective online store solutions.
- How do I integrate Post Affiliate Pro with PrestaShop?
The easiest way is to use the free integration module provided by Post Affiliate Pro. Download, install, and configure the module in your PrestaShop admin panel. The plugin will automatically add the necessary tracking codes.
- Is the PrestaShop integration with Post Affiliate Pro free?
Yes, the integration module is free to download and use. However, you may incur additional costs for web hosting, premium themes, or modules for your PrestaShop store.
- Does the integration support PayPal transactions?
Yes, the integration supports PayPal transactions. You need to make additional modifications to the PayPal module files and activate the PayPal IPN plugin in your Merchant panel for complete tracking.
- What versions of PrestaShop are supported?
The integration module is tested with PrestaShop version 1.7.6.7 but may work with newer versions as well. Always check the latest documentation for compatibility.
- What are the benefits of integrating PrestaShop with Post Affiliate Pro?
You gain seamless affiliate tracking, easy management of affiliate programs, accurate sales tracking, and the ability to expand your marketing reach to boost your online store's success.
Lucia is a talented content editor who ensures the seamless publication of content across multiple platforms.

Boost Your PrestaShop Store with Affiliate Tracking
Integrate Post Affiliate Pro with PrestaShop to optimize your affiliate program, track sales accurately, and grow your online business effortlessly.