Right now I need to integrate Paypal with codeigniter and follow the tutorial here:
https://www.youtube.com/watch?v=-zMVf88XKCA
The workflow there is :
use hidden form to post the item details , return url to
https://www.sandbox.paypal.com/cgi-bin/webscr
then verify the paypal by using CURL:
https://www.sandbox.paypal.com/cgi-bin/webscr?cmd=_notify-synch&tx=$_REQUEST['tx']&at=token;
The problem is ,
1) is the tutorial standard and secure?
2 ) And I also found something like https://github.com/toolani/paypal-ipn-verifier-php? Is that means using IPN checker then no longer need CURL part. Only have to generate the Paypal website. And set the IPN script url in Paypal.
3) When generate Paypal page if I use the hidden field form , the visitor can easily change the amount. How can I (is it necessary) to prevent or check that?
<input type="hidden" name="item_name_1" value="product_1">
<input type="hidden" name="item_number_1" value="p1">
<input type="hidden" name="amount_1" value="2">
<input type="hidden" name="quantity_1" value="1">
fsockopen
but that's a preference only. Verifying IPN is critical or someone could spoof an IPN call to you.