ROTATING BANNERS
by Richard Cunningham

This script will read the elements from a file containing link and image information. It selects the next banner each time the script executes. This is done by updating the element number of the array in a separate file, which the script creates if it doesn't already exist. (Note: If you use this on a 'nix server, you'll have to create a blank file and set permissions before installing the script.) The information for each banner must have a "return" at the end and the next banner must start immediately on the next line. There must not be any extra spaces or returns after the last banner. In order to know which banner is which, I recommend using a tag like at the beginning of each -- it won't be interpreted by a browser.

The easiest way to make sure the banners work as expected is to remove the quote characters from the banner information. For example, this:

<A HREF="http://www.langa.com/newsletter.htm" TARGET="_blank"><IMG BORDER="0" SRC="http://www.langa.com/images/langa.gif" WIDTH="468" HEIGHT="60"></A>

can be made to look like this:

<A HREF=http://www.langa.com/newsletter.htm TARGET=_blank><IMG BORDER=0 SRC=http://www.langa.com/images/langa.gif WIDTH=468 HEIGHT=60></A>"

In the example, the "banners" file path and file name is the first line of code and the "bfile" variable with the path and file name is the second line of code.
