I want to create a unique string for our users. our site in php.
right now I am using uniqid() for this but it returns a new value every time when I refresh a page. how could I can stop to generate this every time?
can anyone help me?
I want to create a unique string for our users. our site in php.
right now I am using uniqid() for this but it returns a new value every time when I refresh a page. how could I can stop to generate this every time?
can anyone help me?
You could take hash from user identificator (id or/and login) with hash function. For example you md5
echo md5('sectus'); // e60e49ef667707f291844f87abeaebe5