http://www.alistapart.com/articles/randomizer/
That's the one written by Dan Benjiman that's in the public domain. I have been using it for several years and it works as advertised. The simple instructions for adding a pic type are in the file. Otherwise don't change anything.
Pics in folder along with that file. FTP them up. Remember the path to them. From body or doc back ground, where ever you're going to use it, put in the path to the rotate.php file.
Code:
url(path/to/your/images/rotate.php)