hi, i need some help. im trying to create a script for my home page that will show random images, using the shuffle function. but im getting an error message. i get an output it its reading the aray in the order.
Warning: shuffle() expects parameter 1 to be array, resource given in c:\program files\apache group\Apache\htdocs\Prt1
i think this is the section of code which is not working corectly
$query = "select * From products" ;
$results = mysql_query($query)
or die(mysql_error());
shuffle($results);
for ($i=0; $i <4; $i++)
{
$row = mysql_fetch_array($results);
extract ($row);
$dvd_title=$row['product_name'];
}