Virtue Mart 3

Integrate Virtue Mart 3 with Post Affiliate Pro for both offline and online payments by adding specific code snippets to designated files. Enhance your affiliate software with additional integrations like PayPal, AlertPay, and Internet Secure.

Virtue Mart 3

Virtue Mart 3 integration

A free e-commerce solution.

This integration method is for Virtue Mart version 3. If you have a lower version, please navigate to the integration method named “Virtue Mart 2”.

Integrate offline payments (cash)

Open file plugins/vmpayment/standard/standard.php and find function plgVmConfirmedOrder.

At the end of it, there is a line $cart- >emptyCart – place the following code above it:

/* [Post Affiliate Pro](https://www.postaffiliatepro.com/ "Post Affiliate Pro offers a comprehensive affiliate software platform to manage multiple affiliate programs with ease. Enjoy no setup fees, 24/7 customer support, and a free 1-month trial. Ideal for small and large businesses, it features precise tracking, automated workflows, and customizable tools to boost your affiliate marketing success. Try it now and streamline your affiliate operations effortlessly!") integration snippet */
$html .= '<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('".$order['details']['BT']->order_subtotal."');
sale.setOrderID('".$order['details']['BT']->order_number."');
sale.setData1('".$order['details']['BT']->email."');
PostAffTracker.register();
</script>";
/* [Post Affiliate](https://www.postaffiliatepro.com/ "Post Affiliate Pro offers a comprehensive affiliate software platform to manage multiple affiliate programs with ease. Enjoy no setup fees, 24/7 customer support, and a free 1-month trial. Ideal for small and large businesses, it features precise tracking, automated workflows, and customizable tools to boost your affiliate marketing success. Try it now and streamline your affiliate operations effortlessly!") Pro integration snippet */

Save your work.

Integrate online payments

Open file administrator/components/com_virtuemart/plugins/vmpsplugin.php and find function processConfirmedOrderPaymentResponse.

Add the following code to it’s beginning:

/* Post [Affiliate](https://www.postaffiliatepro.com/ "Post Affiliate Pro offers a comprehensive affiliate software platform to manage multiple affiliate programs with ease. Enjoy no setup fees, 24/7 customer support, and a free 1-month trial. Ideal for small and large businesses, it features precise tracking, automated workflows, and customizable tools to boost your affiliate marketing success. Try it now and streamline your affiliate operations effortlessly!") Pro integration snippet */
$html .= '<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('".$order['details']['BT']->order_subtotal."');
sale.setOrderID('".$order['details']['BT']->order_number."');
sale.setData1('".$order['details']['BT']->email."');
PostAffTracker.register();
</script>";
/* Post Affiliate Pro integration snippet */

That’s it, it’s integrated.

Do not forget to integrate the click tracking code, to make the sale tracking work correctly.

Frequently asked questions

What is Virtue Mart 3 integration with Post Affiliate Pro?

Virtue Mart 3 integration lets you connect your Virtue Mart e-commerce store with Post Affiliate Pro, enabling seamless affiliate tracking and management for your online shop.

How do I integrate Virtue Mart 3 with Post Affiliate Pro?

You can integrate Virtue Mart 3 by adding provided tracking code snippets to the appropriate PHP files handling offline and online payments as described in the integration guide.

Is this integration suitable for all versions of Virtue Mart?

This integration method is specifically for Virtue Mart version 3. For earlier versions, refer to the 'Virtue Mart 2' integration method.

Do I need to add click tracking code as well?

Yes, it is important to integrate the click tracking code to ensure the sale tracking works correctly with Post Affiliate Pro.

Schedule a one-on-one call

Discover how Post Affiliate Pro can benefit your business. Get personalized guidance on integrating Virtue Mart 3 and maximizing your affiliate marketing potential.

You will be in Good Hands!

Join our community of happy clients and provide excellent customer support with Post Affiliate Pro.

Capterra
G2 Crowd
GetApp
Post Affiliate Pro Dashboard - Campaign Manager Interface