On Tue, 21 Sep 2004 16:18:06 -0500, Ongkiko, Richard M
<[EMAIL PROTECTED]> wrote:
> I am trying to implement some sort of a shuffle.  What I am trying to do is a random 
> shuffling of an array whose contents were records from a database.  I am basically 
> trying to shuffle/randomize, questions, so that different users will have different 
> versions of questions in an exam, whose questions were extracted from a pool in a 
> database, and shuffled.  Can anybody out there help me out?  Coding needed in PHP... 
>  thanks.

I'd do it in the SQL:

select * from table order by rand();

Otherwise PHP's shuffle() function may help you.


-- 
Greg Donald
http://gdconsultants.com/
http://destiney.com/

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to