Hello, How would i make a random image be chosen from a directory of images, and is there a way to show all of the images, Like a thumbnail, But it shows all the images in a certain directory? thanks
first use php.net/glob for reading all files in the current directory and add them into an php.net/array, after creating this array do a php.net/rand(0, php.net/count(array)) and get a random number. Now you can fetch the image file and display it to the user See this example http://www.phpjunkyard.com/random-image.php