howdy do,
My first post but I don't really have anything to say other than chodadog, this sucker below works for me.
PHP Code:
<?php
$banners_dat = "./banners.txt";
function PrintBanner() {
global $banners_dat;
$arry = @file($banners_dat);
if( !isset($arry) || !$arry || !is_array($arry) )
return false;
list($img, $url, $alt, $status) = explode("|", $arry[rand(0,sizeof($arry)-1)]);
$focus=$mouseover="\"window.status='$status'; return true;\"";
$mouseout="\"window.status='Done'; return true;\"";
return "<a
href=\"$url\"
target=_blank
OnMouseOver=$mouseover
OnFocus=$focus
OnMouseOut=$mouseout><img
src=\"$img\"
width=\"468\"
height=\"60\"
border=\"0\"
alt=\"[$alt]\"></a>\n";
}
print PrintBanner();
?>
cheers