Re: a quick question..
| From: | Tauntz | Date: | Sun, 27 Jan 2002 19:31:55 +0000 |
| Subject: | Re: a quick question.. | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-82308@lists.php.net to get a copy of this message | ||
Thank you, it worked :)
----- Original Message -----
From: "Nick Wilson" <nick@explodingnet.com>
To: <php-general@lists.php.net>
Sent: Sunday, January 27, 2002 9:27 PM
Subject: Re: [PHP] a quick question..
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
>
> * and then Tauntz blurted....
> > If I have n variables:
> > $nr1 = "some text";
> > $nr2 = "some other text"
> > $nr3....
> > ....
> > and I want to print the text "randomly" (like if I enter the page.. it
displays $nr1... next time it displays $nr 5.. etc)
> > how can I achieve it ?
>
>
> Pop them all into an array and use array_rand()
> See manual for details.
>
> HTH
> - --
>
> Nick Wilson
>
> Tel: +45 3325 0688
> Fax: +45 3325 0677
> Web: www.explodingnet.com
>
>
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.0.6 (GNU/Linux)
>
> iD8DBQE8VFSFHpvrrTa6L5oRAg7iAKCAvzPSf8E5LGXOF5AjYEhwJXmqrQCfVWYE
> ycfLyu31AB+QDQmkcKaJKe0=
> =pkfe
> -----END PGP SIGNATURE-----
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
> For additional commands, e-mail: php-general-help@lists.php.net
> To contact the list administrators, e-mail: php-list-admin@lists.php.net
>