Showing posts with label Validations. Show all posts
Showing posts with label Validations. Show all posts

Credit Card Validation using Regular expression

1 comments

Visa: ^4[0-9]{12}(?:[0-9]{3})?$  - Visa card will have 16 digits. Always starts with 4.

MasterCard:  ^5[1-5][0-9]{14}$ -  Master Card will have 16 digits. Always starts with 51 through 55.

American Express: ^3[47][0-9]{13}$  -   American Express will have 15 digits. Always starts with 34 or 37.

Regular expression to accept decimal up-to two places

0 comments

Regular expression to accept decimal up-to two places

^-?[0-9]{0,2}(\.[0-9]{1,2})?$|^-?(100)(\.[0]{1,2})?$

Strong password validation using regular expression

0 comments

This Regular expression is used to create strong password.

       It will allows to enter at-least  1 upper case letter.
       It will allows to enter at-least  1 lower case letter.
       It will allows to enter at-least  1 number or special character.
       It will allows to enter at-least 8 characters length.

Vikram Chandra Theme by BloggerThemes & NewWPThemes Sponsored by iBlogtoBlog