The Arcive of vBulletin Modifications Site. |
|
|
#1
|
||||
|
||||
|
PHP Code:
|
|
#2
|
||||
|
||||
|
Only limit the rand to 5.
rand(1,5) |
|
#3
|
||||
|
||||
|
ok, so cos it's for my site, it will display 5 of my requests at a time randomly not repeating any of em?
|
|
#4
|
||||
|
||||
|
If you're lucky, it wont repeat.
But after properly reading what you want, it would be easier (and probably the only way) is to use the DB at the backend |
|
#5
|
||||
|
||||
|
Tut tut
:PHP Code:
|
|
#6
|
||||
|
||||
|
Quote:
|
|
#7
|
||||
|
||||
|
count function counts the number of items in an array
|
|
#8
|
||||
|
||||
|
Quote:
|
|
#9
|
||||
|
||||
|
An arguement to a a function can be a function you know
|
|
#10
|
||||
|
||||
|
I once saw somewhere [I think on php.net] a way to prevent a rand() function from showing the same thing twice...Took a lot of code though.
|
![]() |
|
|