I have worked with Paypal in two ways. The first way is the traiditional form submit method. I make a screen that says nothing, but sending order to process. It has hidden variables and then onLoad uses document.form[''].submit. That works well. You could just as easily make the same form and show the order and have the submit button actually show up and it say "Accept Order" or something similiar.
The second method I am using now is IPN. This way I can verify payments in my app. You still submit the same form except this time you can pass invoice, and the IPN postback address as part of the form. So, once they successfully pay, Paypal posts to your postback and you capture the post variables. Then, you post back to them with fputs or curl and they post back again with VERIFIED and all the post variables. That way you know the post is good. There are other things to check to make sure people aren't faking it, but that is the gist of it. This way your app knows not only did they go to Paypal, but they paid and here is how much and details. I downloaded a sample PHP script that posts to a database from the Paypal Developer Network. Email me at support at thephotoedge dot com and I will email you that script. Basically I am just working that into an action. Nothing real fancy. The controller is based on the model of the database they wanted created. The biggest problem I have had is with tax. In that sometimes the tax_cart value wouldn't override the Paypal default settings and would either double tax or not tax at all. If you have any specific questions once you look at the intergration PDF that Paypal puts out and getting the script I will email you later you can email me questions and I can try and help out. Once I get my IPN script working I will try and do a wiki on it. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php -~----------~----~----~----~------~----~------~--~---
