Adamskii
Newcomer
Hey guys,
Just a quick question, is it possible to create a script that changes a banner image every hour? I'm looking at something for my radio station, but can't get this script to work. What I've got at the moment is:
Bearing in mind my server is currently GMT-1 so its 21:45 now on there, its permenantly showing the offline image. The echo sections at the bottom are telling me it should be working, but its not.
Just wondering if anyone could guide me as to what to do about this script, its got to be able to handle a few DJs, and manage to keep updated with each hourly show.
Thanks.
Edit:
For the image to display, there is a <img> tag on the page, with a php echo of the $img, So it does actually show up on pages.
Just a quick question, is it possible to create a script that changes a banner image every hour? I'm looking at something for my radio station, but can't get this script to work. What I've got at the moment is:
PHP:
<?php
$time = date('H');
$imgtype = "png";
if($time = 21) {
$img = "adam";
}
else {
$img = "offline";
}
echo date('H:m s');
echo("$img");
?>
Just wondering if anyone could guide me as to what to do about this script, its got to be able to handle a few DJs, and manage to keep updated with each hourly show.
Thanks.
Edit:
For the image to display, there is a <img> tag on the page, with a php echo of the $img, So it does actually show up on pages.


