This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// below are the indept explanation of some of the signs i use:- | |
// (/) sign inside bracket alert the js engine that am about to declare a regular expression | |
// (^) is telling the JS engine again that what i need as the first digit is (5 if its master card, 4 if its Visa card as i declare it differently ) | |
// ($) This sign tells the JS engine that am done with the parttern i want to use and validate any kind of input i need in my application | |
//============================================================== ====================================================== | |
// MASTER CARD VALIDATION | |
// Its known very well that every payment cards has there specifi numbers of digits | |
// Master Card has a Total 16 digits | |
// Valid Master card digits always start with five (5) digit |