How to go about managing payments in a web app?
September 10, 2007 11:27 AM Subscribe
PHP/TransactionFilter: Designing a web application where users will have actual monetary accounts. What is the best way to approach this?
I'm currently drafting a spec for a web application. One aspect of this application is that users can buy 'credit' for using certain parts of the service. The user will be able to purchase this credit (using paypal) in chunks of 5, 10, 20 dollars. Each time they use the service, a fraction of their credit (say 40 cents) will be used up, until they run out, whereby they will be able to purchase more credit.
My question is, what would be the best way to go about implementing this programatically? I don't have much experience with transaction based applications, but from what I've read, a transaction/rollback system might be the way to go (correct me if I'm wrong)?
The application will be running on LAMP, using the CakePHP framework. Payments to the site will be made using PayPal, for the moment. I'm pretty knowledgeable with Cake and I have some experience with the PayPal API.
Any advice as to how to approach this would be great. Thanks in advance!