Daemonj Posted February 5, 2003 Share Posted February 5, 2003 In the administration section, I have enabled Credit Cards for payment. Is there a way to specify which credit cards are accepted? For example, my merchant account is only setup to process VISA, MC, and AMEX so I need a way to bounce customers back that try to use any other type of card (e.g. Discover). "Great spirits have always found violent opposition from mediocre minds. The latter cannot understand it when a man does not thoughtlessly submit to hereditary prejudices but honestly and courageously uses his intelligence." - A. Einstein Link to comment Share on other sites More sharing options...
jyt Posted February 12, 2003 Share Posted February 12, 2003 same thing for me, how to disable some credit card type? what about CC_CVV+UK Switch v1.0 from Barry McEwan ? Link to comment Share on other sites More sharing options...
philip.orourke Posted February 12, 2003 Share Posted February 12, 2003 I've installed Barry's UK+Switch CC module and it works well, you do need to read the "read me" file that accopanies that mod, it'll show you how to enable and disable paricular cards (sorry i haven't got it to hand). Link to comment Share on other sites More sharing options...
Guest Posted March 6, 2003 Share Posted March 6, 2003 having same problem. Need something for visa, mastercard and discover only. Having alot of customers using credit cards I do not accept. Link to comment Share on other sites More sharing options...
Ramesh Posted March 10, 2003 Share Posted March 10, 2003 *Please backup before trying any of the following* You have to modify this file: cc_validation.php found in this directory: catalog/includes/classes If you only want to accept certain cards you have to remove or comment out (far better so you can easily add enable cards at a later date) the lines which correspond to the cards. The card types have names next to the line (VISA , mastercard) The first line of my file reads: if (ereg('^30[0-5]{1}[0-9]{1}([0-9]{10})?$', $this->cc_number)) { $this->cc_type = 'Diners Club'; return -5; subsequent lines read: } elseif (ereg('^36[0-9]{2}([0-9]{10})?$', $this->cc_number)) { $this->cc_type = 'Diners Club'; return -5; } elseif (ereg('^38[0-8]{1}[0-9]{1}([0-9]{10})?$', $this->cc_number)) { $this->cc_type = 'Diners Club'; return -5; } elseif (ereg('^34[0-9]{2}([0-9]{11})?$', $this->cc_number)) { $this->cc_type = 'American Express'; return -5; } elseif (ereg('^37[0-9]{2}([0-9]{11})?$', $this->cc_number)) { $this->cc_type = 'American Express'; return -5; } elseif (ereg('^5610([0-9]{12})?$', $this->cc_number)) { $this->cc_type = 'Australian Bankcard'; return -5; the final lines are: } elseif (ereg('^4936[0-9]{2}([0-9]{10})?$', $this->cc_number)) { $this->cc_type = 'UK Switch'; return ($numSum % 10 == 0); } So what have we learnt: The first card type code is of the form: if ....; then subsequent card types begin with : elseif ... ; the last card type has to have a } at the end of the code. hope this was ok. Special Effects / 3d + Flash Link to comment Share on other sites More sharing options...
Ramesh Posted March 10, 2003 Share Posted March 10, 2003 I am using CC_CVV+UK Switch v1.0 from Barry McEwan (because in the UK SWITCH is a very popular card.) Also certain cards have multiple lines to cope with Credit Cards with different length numbers. So , say in the UK there are 3 lengths of numbers (12 digits , 16 digits and 19 digits) for a card called RAMESH. This means in the cc_validation.php file there would be 3 sections of code corresponding to the 3 different lengths of card. So check that your card(s) (ones you want to enable). are listed in the cc_validation.php and keep all lines which refer to them. Good Luck and reply in this forum for anything else ! Special Effects / 3d + Flash Link to comment Share on other sites More sharing options...
drochaid Posted September 29, 2003 Share Posted September 29, 2003 I've just installed Barry McEwan's CC_CVV+UK Switch v1.0 and now all the cards are recognised properly but NOTHING is acepted!! :( I've gone over the readme as carefully as possible and can't see any obvious problems. HELP! Calum Morrell Link to comment Share on other sites More sharing options...
drochaid Posted September 29, 2003 Share Posted September 29, 2003 *looks sheepish* however the one thing I hadn't tried was stopping and restarting the cc payment module. All seems well now, well with that anyway, there's an issue with the blacklist [admin module looking for fields that the readme doesn't tell me to create] but I'll get that sorted easily enough. Thanks for a great contrib Barry :D Calum Morrell Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.