|
Hi!
I think the best way to incorperate the use of cod
or credit is by making a new entry in payment metod table and ad some code to
/modules/include/validateCard .
Now if I were a programmer, and not a newbe, I
could just do it. But, I need a litle help.
I have done it the way if guess it shuld be, but
PLEASE, will someone tell me if it is right???
Here is the code, and thanks:
/* ** Function: validateCard ** Input: STRING card ** Ouput: STRING/BOOLEAN ** Description: a card is tested for being a recognized type ** and for passing the MOD 10 algorithm. */ function validateCard($card) /* **To get an non creditcard transaktion validated I just say that ** "Credit or COD" is a valid creditcard. Before any creditcard-validation we need to ** simply state it is ok and can be turned over. ** In SQL table, the entry is card "Credit or COD" and type "CODC". */ if ($card = "Credit or COD") { $type = 'CODC'; //everything checks out return($type); } else { //remove non-numbers $card = ereg_replace('[^0-9]','', $card); Thanks!
Bjarne Hansen
|
- Re: [FreeTrade] COD option in validation Bjarne Hansen
- Re: [FreeTrade] COD option in validation Jon Griffin
- [FreeTrade] Final word on COD - today Bjarne Hansen
- Re: [FreeTrade] Final word on COD - today Jon Griffin
- [FreeTrade] COD again! Bjarne Hansen
- RE: [FreeTrade] Final word on COD - today Leon Atkinson
- RE: [FreeTrade] Final word on COD - today Leon Atkinson

