This tutorial explains how to generated unique ID strings using the uniqid() function and how to generate random strings using the md5 function. Sample code: …
Original source
This tutorial explains how to generated unique ID strings using the uniqid() function and how to generate random strings using the md5 function. Sample code: …
Original source
11 responses to “PHP & MySQL Tutorial 44 – Generating unique IDs and random strings (uniqid and md5 functions)”
👌👌 way of explaining 🌟
how for only number?
not alfanumeric
This is also possible with php I found this https://bit.ly/2Lg3Gxq
How to make some numbers constant in random generation like in your video (i.e. 570db)????
Is there any code to make user-defined type?
It is very helpful. You can also refer this website for some useful information:
http://ahex.co/how-to-generate-uuid-in-laravel/
Will this uniq id show in the url when you try log in to a site?
Super helpful – thanks!
What does "it shouldn't be used for security purposes" means?? Can we use it to replace "id" autoincremented field on a MySQL table?
Hello Daniel,
i am not a coder, but in need help.
What should I do if I want to save the generated IDs? Is it possible that only one ID is generated and stored per IP address? I am looking for a solution when a user comes to a web page that this ID is automatically generated.
Thank you!
Stefan
thanks. It was helpful
thank you so much, this video really helped me.