Title |
Test
Find
Visa Credit Card
|
Expression |
(^4\d{12}$)|(^4[0-8]\d{14}$)|(^(49)[^013]\d{13}$)|(^(49030)[0-1]\d{10}$)|(^(49033)[0-4]\d{10}$)|(^(49110)[^12]\d{10}$)|(^(49117)[0-3]\d{10}$)|(^(49118)[^0-2]\d{10}$)|(^(493)[^6]\d{12}$) |
Description |
Matches Visa CC types 13 or 16 digits starting with 4 including Visa CC, Visa ATM only, Visa Electron and Visa Delta. Safe for international and will NOT match "^(49)" Switch debit cards. |
Matches |
4111111111111111 |
Non-Matches |
4903020000000008 |
Author |
Rating:
Not yet rated.
brad
|
Source |
|
Your Rating |
|
Title: Rejects 4919
Name: Mark Davison
Date: 11/7/2011 4:34:21 AM
Comment:
We had a Visa card starting with 4919 rejected by this regex. http://en.wikipedia.org/wiki/List_of_Bank_Identification_Numbers lists this number prefix as "Charles Schwab Bank VISA Check Card". Looks like there's an extra caret in the group [^013]
Title: Rejects 4919
Name: Mark Davison
Date: 11/7/2011 4:32:27 AM
Comment:
We had a Visa card starting with 4919 rejected by this regex. http://en.wikipedia.org/wiki/List_of_Bank_Identification_Numbers lists this number prefix as "Charles Schwab Bank VISA Check Card". Looks like there's an extra caret in the group [^013]
Title: Rejects 4919
Name: Mark Davison
Date: 11/7/2011 4:29:38 AM
Comment:
We had a Visa card starting with 4919 rejected by this regex. http://en.wikipedia.org/wiki/List_of_Bank_Identification_Numbers lists this number prefix as "Charles Schwab Bank VISA Check Card". Looks like there's an extra caret in the group [^013]
Title: Rejects 4919
Name: Mark Davison
Date: 11/7/2011 4:28:52 AM
Comment:
We had a Visa card starting with 4919 rejected by this regex. http://en.wikipedia.org/wiki/List_of_Bank_Identification_Numbers lists this number prefix as "Charles Schwab Bank VISA Check Card". Looks like there's an extra caret in the group [^013]
Title: Issue resolved
Name: Goodguy
Date: 10/12/2009 5:49:31 PM
Comment:
Added basic ^4[0-9]{12}(?:[0-9]{3})$ to end of regex above. Resolved Visa test Card 4917610000000000 issue.
^(^4\d{12}$)|(^4[0-8]\d{14}$)|(^(49)[^013]\d{13}$)|(^(49030)[0-1]\d{10}$)|(^(49033)[0-4]\d{10}$)|(^(49110)[^12]\d{10}$)|(^(49117)[0-3]\d{10}$)|(^(49118)[^0-2]\d{10}$)|(^(493)[^6]\d{12}$)|^4[0-9]{12}(?:[0-9]{3})$