Forum Moderators: coopster

Message Too Old, No Replies

randomizing between two images and links

         

lindajames

2:09 pm on Jul 12, 2003 (gmt 0)

10+ Year Member



Hi, i have two banners that are linked to two different places i.e:

<a href="link1.html"><img src="image1.gif"></a>
<a href="link2.html"><img src="image2.gif"></a>

At the moment i have randomised it with perl but i want to randomize it with php, can anyone tell me how this can be done?

cheers
linda

vincevincevince

2:24 pm on Jul 12, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



look at array_rand

(array_rand. (PHP 4 ) array_rand -- Pick one or more random entries out of an array)