-
Notifications
You must be signed in to change notification settings - Fork 230
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
19 digit credit card numbers? #155
Comments
Yeah I am seeing the need to expand to handle 19 digit card number. In my testing I have been able to make adjustments to the skeuocard.js and the skeuocard.css in this manner. Using Visa as a test, 1 realcard.prototype.CardProduct.create({ 2 pattern: /^4/, 3 companyName: "Visa", 4 companyShortname: "visa", 5 cardNumberGrouping: [4, 4, 4, 4], 6 cardNumberLength: [13, 14, 15, 16], 7 expirationFormat: "MM/YY", 8 validateLuhn: true, 9 cvcLength: 3, 10 layout: { 11 number: 'front', 12 exp: 'front', 13 name: 'front', 14 cvc: 'back' 15 } 16 }); If you know the 19 character patter I changed lines 5 & 6 to the following just to try it out. 5 cardNumberGrouping: [4, 4, 4, 7], 6 cardNumberLength: [13, 14, 15, 16, 19], On the CSS I changed the font size from 1.5em to 1.25em .skeuocard.js .cc-number input { color:#333; font-family:"ocraregular", "OCR A Std", "OCR A", Courier, "Courier New", monospace; font-size:1.5em; } While it was not the best looking it did let me enter 16 and 19 length cards. I am not sure if that I am doing is correct or not, as I am a hobbiest kind of coder and I still have not figured out how to make the expiration date output be MM YY i.e 01 18 and not 1 2018 so I would check with someone that knows more than me to get it 100%. |
I was trying to see if there was some simple way to dynamically handle lengths and groupings for all 12-19 credit card number. Unless someone knows any better, I think the only fool proof way would be to have a comprehensive database all known IINs so probably not. While doing some google image searches for 'maestro', I found a few examples of uncommon groupings, and even multiple groupings for the rarest lengths. By the way, this page has a 19 digit maestro example where the grouping is [5,11,3]. |
Building a database could be a nightmare. I have put out some requests regarding the 19 digits. I do internal PCI auditing for a card processor. I should be able to get layouts, patterns, and types from some of the engineers that I deal with. WIll post back here when I have something. |
hi @tangoNine did you ever get more information around layouts and patterns of 19 digit numbers? I saw somewhere else that it was thought to be 4 4 4 7 |
@custa1200 Yeah, the pattern that you have is what is going to be expected by what we have from Visa, Mastercard. Discover will use the same pattern when and if they choose to go that route and American Express, at this time, has no plans to change their pattern scheme. Also, just as an aid on what card to display, here is a very basic IIN Range table that I can offer. It's just for card type i.e. Visa, Mastercard etc and not for specific branded cards.
For any that want to get really deep in displaying cards I have attached the most current BIN list by card brand/issuer/variant i.e. BIN Numbers for Chase Saphire, Subway, BestBuy, Canada Trust etc that I have might help but good to have none the less. _EDIT_ |
I've tried the demo and I can't seem to get a 19 digit number like I found on this site to work. It appears that
cardNumberGrouping
defines the max length. Using Firefox 38.The text was updated successfully, but these errors were encountered: