0

Password validation in PHP using regular expressions

Password validation in PHP using regular expressions

Password validation in PHP using regular expressions.

In php validating a password is necessary for a good web developers, so if you are web developer then you must define some password validation rules so that no one pick a easy password because easy password is easy to crack.
To create a strong password use long password with caps, numbers and symbols. We use regular expressions for force user to pick a strong password. Regular expressions provide us pattern-matching functionality. using regular expressions we can search a string inside a string, replace one string with another string and also define string validation pattern.
Like following i have used regular expressions for password validation.

Password Validation Code

Sandeep Kumar

Sandeep kumar is a web developer and a professinal blogger. He works for latest technologies and write articles what he learn. In ICodeHub he share web languages tutorials and other programming tips and tricks. if you need some help or have some suggestion then mail him at sandeep92pal@gmail.com without any hesitation. He believes in learning and sharing.