Re: RFC: Credit card processing

From: Date: Sun, 14 Dec 2003 10:38:29 +0000
Subject: Re: RFC: Credit card processing
References: 1  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-24403@lists.php.net to get a copy of this message
Should definitely go into package "Validate". Things like this have already been discussed before. As long as just Validating is concerned we agreed to better place it in "Validate". If you can also do payment-handling we agreed that it is "Payment". On 12 Dec 2003 at 19:11, Joe Stump wrote: > This should probably go in the Payment group: > > http://pear.php.net/packages.php?catpid=18&catname=Payment > > Also, about your dataset - why not create an all encompassing dataset > and then allow factories to gracefully handle them (ie. transaction > support for the mysql DB driver). > > Ie. > > function isCvvValid() > { > return true; // my processing gateway ignores this so don't barf > } > > --Joe > > > > I'm currently working on some code to process credit cards. It's > > pretty rough at the moment, but I'd like to see it become something > > roughly equivalent to CPAN's Business::OnlinePayment. I know of no > > equivalent of this for PHP. If I've missed one, let me know so I can > > stop wasting my time. :^) > > > > Something like this could be quite big, so I'd like to know what you > > thought, and if you had any suggestions. > > > > It's designed with the factory pattern, which allows for the code > > for a single processor to be encapsulated in a single file, and > > allows it to support many different processors. > > > > There are a couple issues I'm aware of: > > > > 1. Should I let the processors have an arbitrary data format, or > > should I define a common subset which everything supports? > > Business::OnlinePayment chose the latter arrangement, and it allows > > one to change the payment processor quite easily. On the other hand, > > it makes it harder to support diverse features among the processors, > > for example if one processor supports CVV2[1]. At the moment, I'm > > using the freeform method, which is much simpler. > > > > 2. Should I try to support Business::OnlinePayment modules? It seems > > like this would be fairly easy to do with a glue processor which > > calls a perl script. > > > > So, any interest? I'm at least going to finish the base and one > > processor (DPILink), as I intend to use the code in my current > > project. > > > > [1]: http://1callhosting.com/cvv2/

« previous php.pear.dev (#24403) next »