Home
Integration Methods
PayPal
PayPal integrates using IPN callback.
Note! This is description of
integration with PayPal if you use PayPal buttons on your web pages. If
you use PayPal as a processing system in your shopping cart, use the
method for integrating with shopping cart, not these steps.
Also,
make sure you don't already use PayPal IPN for another purpose, such as
some kind of digital delivery or membership registration.
To integrate with PayPal, you need PayPal IPN handling plugin which is distributed with Post Affiliate Pro by default.
1
Integration code
Now add the following code into EVERY PayPal button form
This will tell PayPal that it should silently call http://www.yoursite.com/affiliate/plugins/PayPal/paypal.php script upon every sale, and it will pass all sale variables including the custom field to this script.
2
Example
|
Example of updated PayPal form:
<!-- Begin PayPal Button --> <form action="https://www.paypal.com/cgi-bin/webscr" method="post"> <input type="hidden" name="cmd" value="_xclick"> <input type="hidden" name="business" value="paypalemail@yoursite.com"> <input type="hidden" name="undefined_quantity" value="1"> <input type="hidden" name="item_number" value="Product Name"> <input type="hidden" name="amount" value="19.95"> <input type="hidden" name="image_url" value="https://yoursite.com/images/paypaltitle.gif"> <input type="hidden" name="no_shipping" value="1"> <input type="hidden" name="return" value="http://www.yoursite.com/paypalthanks.html"> <input type="hidden" name="cancel_return" value="http://www.yoursite.com"> <input type="hidden" name="notify_url" value="http://www.yoursite.com/affiliate/plugins/PayPal/paypal.php"> <input type="hidden" name="custom" value="" id="pap_dx8vc2s5"> <script id="pap_x2s6df8d" src="http://www.yoursite.com/affiliate/scripts/notifysale.php" type="text/javascript"> </script> <input type="image" src="http://images.paypal.com/images/x-click-but5.gif" border="0" name="submit"> </form> <!-- End PayPal Button -->
In notify_url is possible to use additional parameters: data1-data5, coupon code, channel Id, in this case notify_url will look so:
http://www.yoursite.com/affiliate/plugins/PayPal/paypal.php?data1=value1&data2=value2&data3=value3&data4=value4&data5=value5&coupon_code=coupon1&channelId=mychannel
Notice, that if recurring commission is created, into data1 field will be inserted transactionId.
|
This is all that is required. Now whenever there's sale, PayPal will
use its IPN notification to inform our sale tracking script about new transaction, and system will
generate commission for the affiliate.
Note: If you have more
buttons at one page, you should use only the custom field code in each button. The
script tag should be inserted only once per page.It even
doesn't need to be in the button form, it can be somewhere in the body
of the page. (click tracking is per page (have to be above all buttons),
"custom"
field is per button, "notify_url" is per button too ... PAP4 script
calling notifysale.php is per page - have to be below all buttons)
What if you use PayPal IPN for another purpose like secure delilvery?
3 years ago
Tim Bratton
Does that mean you can't use PAP? Or does it mean there's another recommended approach?
There is an integration method when IPN is used by other script.
3 years ago
Miso Bebjak
Please take a look here: http://addons.qualityunit.com/integration-methods/integration-methods/_ipaypalipnother/
Paypal sale tracking
3 years ago
Bhushan
Does the paypal sales tracking working when the paypal is in test mode?
test mode
3 years ago
Viktor Zeman
I'm not sure what you mean by test mode, but it you mean testing in Sendbox, than it should work.
We have in our knowledgebase also description how to debug sales in Paypal:
http://support.qualityunit.com/knowledgebase/post-affiliate-pro/troubleshooting/how-to-debug-tracking/paypal-button.html
Intigration with 68 Classifieds
3 years ago
Jerry Gearhart
I'm a real estate broker, and looking to intigrate your affiliate system with 68 classifieds. Located at 68classified.com It already has a intigrated shopping cart. My goal is to process the payment within 68 classifed, move to the affiliate software, have it assign an affiliate ID, self replicate the site for the affilate, then allow input of the product or service sold. Can this be done?
Does this also handle refunds and chargebacks?
3 years ago
John
Does this also handle refunds and chargebacks?
It support also refunds and chargebacks
2 years ago
Martin Pullmann, Q.U.
Yes, it is also possible to handle refunds and charge-back too.
integrating Paypal
2 years ago
Gary Kidd
If I use this code, will the affiliate get commission for the total billing sale. I have VAT and shipping in my code with Paypal?
also, If I use the "General Code" on my thank you page, will the system pick that up and override the Paypal script?
click tracking code
2 years ago
david
Where do I get the CLICK TRACKING CODE to add to my banner?
click tracking code
2 years ago
Tomas Vasso
On the link below you can find the manual how to integrate your click tracking.
http://support.qualityunit.com/knowledgebase/post-affiliate-pro/configuration/integration/clicks-referrals-tracking.html
How to adjust code to calculate commission on product sale only, and NOT on the shipping charge as well
2 years ago
Laura
How do I adjust the paypal integration code so it calculates commission only on the sale of products and NOT on the shipping charge also?
I have set up commission to 25%
The way it's working now is if the sale of products is $100 and the shipping cost is $20, the program calculates affiliate commission on the total of $120, and I want it to calculate commission only on $100 - and to exclude the shipping.
RE: How to adjust code to calculate commission on product sale only, and NOT on the shipping charge as well
2 years ago
Stefan Wimmer
Laura: The shipping can be discounted by 2 ways. Either you go to Plugins and click Configure next to PayPal IPN handling and check 'Discount shipping', or you define fixed cost in Commission settings so it would be removed from the total cost before commission is calculated. I recommend to use the first option.
how do we know that our website has been integrated with the PAP?
6 months ago
BUDDY
Hello PAP,
how do we know that our website has been integrated with the PAP?
[without doing a test payment, because not everyone has two accounts]
is there any easy steps for setting standards affiliate?
regards