jackrabbit Posted October 13, 2005 Share Posted October 13, 2005 I'm interested in finding out how to exclude American Express from being accepted through the OSC payment module. Is there a way to do that? Quote Link to comment Share on other sites More sharing options...
dynamoeffects Posted October 13, 2005 Share Posted October 13, 2005 Sure. Which payment module are you using? Quote Please use the forums for support! I am happy to help you here, but I am unable to offer free technical support over instant messenger or e-mail. Link to comment Share on other sites More sharing options...
jackrabbit Posted October 13, 2005 Author Share Posted October 13, 2005 Just the same one that comes out of the box. I'm processing the CC myself not going through a processor. Does that help? Quote Link to comment Share on other sites More sharing options...
dynamoeffects Posted October 13, 2005 Share Posted October 13, 2005 Oh wait a minute. Head up my butt. Just edit the file: /catalog/includes/classes/cc_validation.php Delete these two lines: } elseif (ereg('^3[47][0-9]{13}$', $this->cc_number)) { $this->cc_type = 'American Express'; Quote Please use the forums for support! I am happy to help you here, but I am unable to offer free technical support over instant messenger or e-mail. Link to comment Share on other sites More sharing options...
jackrabbit Posted October 15, 2005 Author Share Posted October 15, 2005 Thank you so much for the tip, I really appreciate it. I was wondering if you or anyone else could help me with a very urgent problem that I am having with the same CC module. Apparently, people with valid VISA cards are recieving errors when they try to submit their CC# and I don't know why. Do you know what the best thing to do about this is or why it is happening? Thanks again. Quote Link to comment Share on other sites More sharing options...
dynamoeffects Posted October 15, 2005 Share Posted October 15, 2005 I'd need to know what the error is. The generic cc_validation class is a few years old, so VISA could've updated their card number algorithm. Quote Please use the forums for support! I am happy to help you here, but I am unable to offer free technical support over instant messenger or e-mail. Link to comment Share on other sites More sharing options...
aragorn231 Posted October 15, 2005 Share Posted October 15, 2005 I'm currently also busy getting my payment modules to work, and yesterday came across the VISA validation code in this thread, where I commented on it. In short: the current VISA verification code thinks that a VISA card number consists of 13 digits + 3 optional ones. I assume that the 3 optional ones refer to the check number on the back of the card. If that's the case however, the code is not correct because as far as I know a VISA card number consists of 16 digits + 3 optional ones. See other thread for corrected code. Oh, and please let me know what you think about this, I'm also fairly new to osCommerce and PHP, so I might be overlooking something... Quote How to make a horrible shop (great sarcasm!) Link to comment Share on other sites More sharing options...
dynamoeffects Posted October 15, 2005 Share Posted October 15, 2005 (edited) I'm pretty sure the cc_validation script doesn't check CVV2 numbers in those regexps. All credit cards have a special number format to differentiate between the cards, so I think the three numbers you call optional just mean any three numbers will work in that space. I think what the OP's problem is is that VISA has come out with a new card and a new number format that isn't checked properly in the cc_validation script. Someone needs to dig up that information so that the cc_validation script can be updated. Edited October 15, 2005 by dynamoeffects Quote Please use the forums for support! I am happy to help you here, but I am unable to offer free technical support over instant messenger or e-mail. Link to comment Share on other sites More sharing options...
aragorn231 Posted October 15, 2005 Share Posted October 15, 2005 Are you really sure that the code doesn't take the CVV2 number into account? Because if that's the case, I don't really understand why the last 3 digits are optional, as far as I know a VISA card number is always 16 digits, not 13 or 16? Unless there's a special type of VISA card of which I'm not aware... BTW: I called it optional because that's how it's defined in the regex - see the ? sign in the expression. On the other hand, you're probably correct in saying that the code doesn't check those verification numbers, because the VISA regex is the only one with optional digits, hmm... Quote How to make a horrible shop (great sarcasm!) Link to comment Share on other sites More sharing options...
dynamoeffects Posted October 15, 2005 Share Posted October 15, 2005 Dunno. Maybe there are some special VISA cards, like AMEX's Black card, that only has 13 digits. It could also be back compatibility for really old VISA cards. Quote Please use the forums for support! I am happy to help you here, but I am unable to offer free technical support over instant messenger or e-mail. Link to comment Share on other sites More sharing options...
jackrabbit Posted October 16, 2005 Author Share Posted October 16, 2005 Thanks for the feedback guys, I really appreciate it. Actually thing is about the problem I'm having is that some Visa's are not working while it seems that most do work. Have you heard anything about this? If not do you think I should post another question that asks about it specifically? Since I don't have the problem CC numbers I can't compare them to the ones that do work. That is why I'm a little hesitant to use that modification you posted earlier. Quote Link to comment Share on other sites More sharing options...
dynamoeffects Posted October 16, 2005 Share Posted October 16, 2005 That might be the problem right there. You customers could have just mistyped one number and it'd throw back an error. I'd suggest you contact one of your problem customers and have them try it again. aragorn, I just did a quick google of credit card number algorithms and it turns out that VISA does have 13 digit card numbers, so the algorithm in cc_validation is correct. I'm willing to bet this is more user error than anything because I can't find any info on new algorithms put out by VISA. Quote Please use the forums for support! I am happy to help you here, but I am unable to offer free technical support over instant messenger or e-mail. Link to comment Share on other sites More sharing options...
aragorn231 Posted October 21, 2005 Share Posted October 21, 2005 Well found Brian, you're right. This means of course that the code modification that I suggested earlier is not valid and should be disregarded. Quote How to make a horrible shop (great sarcasm!) Link to comment Share on other sites More sharing options...
SteveDallas Posted October 28, 2005 Share Posted October 28, 2005 aragorn, I just did a quick google of credit card number algorithms and it turns out that VISA does have 13 digit card numbers, so the algorithm in cc_validation is correct. I'm willing to bet this is more user error than anything because I can't find any info on new algorithms put out by VISA. Back at the dawn of time (okay, in the 70's), both BankAmericard (now VISA) and MasterCharge (now MasterCard) used 13 digit account numbers. MasterCard made a wholesale change to 16 digit numbers, while Bank of America/VISA International allowed at least some of their member banks to retain the 13 digit format. Possibly interesting historical information: http://www.well.com/user/mp/mcmain.html (description and interviews on the origins of MasterCharge/MasterCard) http://www.npc.net/merchant/bankcard101.htm (A bit of history of the bank credit card, as well as an overview of the participants and payment flows in credit card processing) Back to the topic at hand... The code in cc_validation is used everywhere, it seems. Another version in PHP can be found as an example on http://www.sitepoint.com. I note that whoever originally wrote the MOD 10 validation code probably didn't really understand the math behind it, because it can be made a bit simpler. Since it's only being used to validate one card at a time, speed isn't an issue, so it's not really a problem. I'll elaborate if anyone is interested. --Glen Quote Link to comment Share on other sites More sharing options...
jgairguns Posted November 1, 2005 Share Posted November 1, 2005 Sure. Which payment module are you using? Hi, Saw this recent post and thought that someone on this string might be able to help me. We do not process cc on line, we only collect the numbers and process them on our machine in our office. We need to collect the ccv number (3 Digits) from the signature line on the rear of the customers card. Can anyone tell me how to create a box on the payment page to collect this info. Thanks for all your posts as I found then info valuable so far. jgairguns Quote Link to comment Share on other sites More sharing options...
bongo Posted November 6, 2005 Share Posted November 6, 2005 Hello, I also have problems with the credit card module. I norway we have 16 digits in our card number. + 3 safety digits. But when i enter the first numbers that usualy is 4925 i get an error that that number isn't an valid number. Does anybody now why? I use the basic credit card module since i use an external payment terminal. Hope you guys can help me. -Thomas- Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.