I have been interested in using the random banner rotation PHP code from my Dew-NewPHPLinks script for use on other PHP scripts on my website - fattymattybrewing.com... these other sections of my site that I have used the banner code for include...BrewBlogger (for PHP/MySQL), Wordpress, PHP Dictionary and Coppermine photo gallery.
I looked into the directory file and found...
| Code: |
<?
if ($showbanners == "1"){
include("include/banners.php");
}
?>
|
then I found that I could not use the include reference to banners.php because the base path was different to my banners folder. I just copied and pasted the code from banners.php, changed the number of banners code to be the # of .html files I have in the banner folder and removed if ($showbanners == "1"

.
All I was left with is:
| Code: |
include("include/banners.php");
|
and it works great!
Thanks again for the well written script.