help me in random codes

Started on the old forum in November 2011 · view the original in the archive · old links redirect here

3 replies · 487 views · started 15 years ago · 1 min read

2 participants
Lue_chin Developer · 107 posts #1

hello friends please help me i wish you help me i want to create a random code for ex: my code is 23453 and after refresh its gone change to another 23456 and then 23546 then 23654 so i want last three digit changing randomly after refresh so please give me a ph code fo this

arnage Lead · 811 posts #2

If i understand correctly its something like this?

$num = '23'.substr(uniqid(rand(), true), 0, 3);
<!DOCTYPE html PUBLIC "-//***WAPFORUM**.**RS***
arnage Lead · 811 posts #4

You are welcome.

<!DOCTYPE html PUBLIC "-//***WAPFORUM**.**RS***

Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close