The code above starts a loop, reads folder contents and checks if the file is not a folder. Then a name of the file is stored in the array and folder is closed when the cycle is over.
$randval = mt_rand( 0, sizeof( $imgArray ) - 1 );
This line generates a random value not greater than number of files in the directory.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
Host your free forums with Invision Plus.net forum web hosting with your own subdomain.
alexisBlue v1.2 // Theme Created By: Andrew Charron // Icons in Part By: Travis Carden