I tried to use the information on how to add a "custom cards" validation but I must be missing something.
I am trying to add Bancontact support.
Cards number example:
6703 4444 4444 4449
6703 0000 0000 0000 003
CVC: none
Not sure about the length, I found 13 to 19 in some other validators.
Here is the code I am using to add the card declaration.
window.payform.cards.push({
// Card type, as returned by payform.parseCardType.
type: 'BCMC',
// Regex used to identify the card type. For the best experience, this should be
// the shortest pattern that can guarantee the card is of a particular type.
pattern: /^6703/,
// Array of valid card number lengths.
length: [13,14,15,16,17,18,19],
// Array of valid card CVC lengths.
cvcLength: [0],
// Boolean indicating whether a valid card number should satisfy the Luhn check.
luhn: true,
// Regex used to format the card number. Each match is joined with a space.
format: /(\d{1,4})/g
});
By default, Bancontact cards are matching Maestro cards, but that's not OK because of the CVC at the least.
Hello,
I tried to use the information on how to add a "custom cards" validation but I must be missing something.
I am trying to add Bancontact support.
Cards number example:
CVC: none Not sure about the length, I found 13 to 19 in some other validators.
Here is the code I am using to add the card declaration.
window.payform.cards.push({ // Card type, as returned by payform.parseCardType. type: 'BCMC', // Regex used to identify the card type. For the best experience, this should be // the shortest pattern that can guarantee the card is of a particular type. pattern: /^6703/, // Array of valid card number lengths. length: [13,14,15,16,17,18,19], // Array of valid card CVC lengths. cvcLength: [0], // Boolean indicating whether a valid card number should satisfy the Luhn check. luhn: true, // Regex used to format the card number. Each match is joined with a space. format: /(\d{1,4})/g });
By default, Bancontact cards are matching Maestro cards, but that's not OK because of the CVC at the least.