A Better Mouse-Trap
22 October 2003 · 3 Comments · No tags
Note: See also the article on doing this in Rails.
It is the Narrator’s pleasure to announce the publication of his latest article, entitled Random Image Rotation. It is one of the features in the premier issue of the newly redesigned A List Apart magazine.
The article details the long-awaited new version of the Image Rotator, an easy-to-use PHP script to display random images on a website. The update is, as usual, a ground-up rewrite of the original version, with many improvements including:
- Easier to specify/change the rotation-folder
- Easier to specify/change supported image types
- Better in-script instructions and info
- More error checking (thanks, Milo)
- Cleaner code (albeit more PHP-specific)
- Better/faster random number generation and file-type parsing
- Added a feature where the image to display can be specified
- Added a cool feature where, if an error occurs (such as no images being found in the specified folder) and you’re lucky enough to have the GD libraries compiled into PHP on your webserver, the script will generate a replacement “error image” on the fly
Just a day in the life at Hivelogic Heavy Industries.
Comments
Roar · 16 January 2008 at 07:01 PM
Oh, where did it go... where did it go?
Dan Benjamin · 16 January 2008 at 07:01 PM
@Roar - well, try A List Apart, http://alistapart.com/articles/randomizer/
deliciousframes · 11 February 2008 at 12:02 PM
Is 2.2 the last version?

Sorry, comments have been closed.