D
Dom
Hi,
does anyone know what the business rules are behind struts credit card validation?
Thanks,
Dom
does anyone know what the business rules are behind struts credit card validation?
Thanks,
Dom
Dom said:Hi,
does anyone know what the business rules are behind struts credit card validation?
Thanks,
Dom
Dom said:Hi,
does anyone know what the business rules are behind struts credit card validation?
Sudsy said:Still, it might be adequate for North American applications,
unless you don't accept all those card types...
Steven said:Sudsy <[email protected]> wrote:
nah, it's still simple, you just check the first couple digits of the
account number first.
--Visa starts with 4
correct
--Mastercard starts with 5
--Discover starts with 6
--American Express starts with, I believe, either 32 or 37 - be careful
with this because there are some other non-AMEX cards that have 3 as the
first digit. You MUST check the second digit if the first is 3.
Sudsy said:wrong...it starts with either 51, 52, 53, 54 or 55
wrong...it starts with 6011
wrong...either 34 or 37
Still thinking it's so simple? And we haven't event touched on Diner's
Club, JCB and different number lengths for some cards...
Yes, I am still "thinking it's so simple." I was referring to doing a simple
check BEFORE calling any mod10/LUHN verification libraries, and I was
specifically posting in response to the post immediately upthread from mine
that only talked about accepting the Big Four. I am aware that once you
introduce other types of cards it gets a little more complex, but even then,
there's still a system.
WRT lengths: Mastercard is always 16, Visa is 16 or 13, Discover is
always 16, Amex is always 15.
I stand corrected
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.