Hiiii, when we make some user registration system in our project or code then we always want to keep the user details like password etc very secure which is not easy to detect and which is random for each and every user. You can try to make random password by applying some logic but here in this demo I’ll be providing you with a very simple and short code to generate a random password.
This random passwords are also necessary when you have to send a confirmation mail to users with some password different from their identities. Users have to change their random passwords to their own password on first login.
Don’t interpret the meaning of these random password with passwords generated by some encryption techniques like md5 hash, etc. The random passwords here are generated in php by making a string with some logic by adding a digit to that password string.
In this technique which I’ll be showing here, you can generate the password of your desired length.