I upload a folder full of images to create a jQuery image gallery.
Currently 100 images are being uploaded to create the gallery. I have everything to download without problems.
All I want to do is make uploaded images, upload in random order.
How do I achieve this?
My code is:
<?php
$folder = "images/";
$handle = opendir($folder);
while(($file = readdir($handle)) !== false) {
if($file != "." && $file != "..")
{
echo ("<img src=\"".$folder.$file."\">");
}
}
?>
Thanks in advance.
source
share