OptimizePress (WordPress module) is the new way to create high converting landing pages, sales pages and membership portals.

If you use the the Pricing Table feature of OptmizePress and in those pricing tables you use payment links leading to PayPal (direct links leading to PayPal including the id of your hosted PayPal button), then follow the integration steps below.


In wp-content/plugins/optimizePressPlugin/lib/assets/tpls/pricing_table/style_X.php  (X can be 1, 2 or 3)



right above the line of:
foreach($tabs as $tab){

And into 

<a href="<?php echo $tab['order_button_url']; ?>" class="css-button"><?php echo $tab['order_button_text']; ?></a>

right before the href  tag add:

id="ptPayPalLink<?php echo $i++;?>" name="ptPayPalLink"

 so that the code becomes like:

<a id="ptPayPalLink<?php echo $i++;?>" name="ptPayPalLink" href="<?php echo $tab['order_button_url']; ?>" class="css-button"><?php echo $tab['order_button_text']; ?></a>


Now, into "WP ADMIN > Optmizepress > Dashboard > Analytics and Tracking > Analytics and Tracking > Other tracking codes" add the following kod which is  your Click tracking code along with the script that will append the cookie to all the payment links of the pricing table

<script type="text/javascript"><!--
	document.write(unescape("%3Cscript id=%27pap_x2s6df8d%27 src=%27" + (("https:" == document.location.protocol) ? "https://" : "http://") + "URL_TO_PostAffiliatePro/scripts/trackjs.js%27 type=%27text/javascript%27%3E%3C/script%3E"));//-->
<script type="text/javascript"><!--
	try {
	} catch (err) { }
<script type="text/javascript">
	var PayPalLinkCount = document.getElementsByName('ptPayPalLink').length;
	for (var i=0; i < PayPalLinkCount;i  ) {
		PostAffTracker.writeCookieToLink('ptPayPalLink' i, 'custom');