Parašė kesiukas· 2011 Lap. 1 10:11:15
#1
Turiu random reklamos panele. Ten padaryta, kad reklama rodytu per center, bet vistiek nerodo. Va kodas:
openside("Reklama");
$arr = array("cs.dievas.xz.lt","nba-live.com","fssb.lt","modai.tk");
$bnr = array
("<img src='http://cs.dievas.xz.lt/2/Baneris468x60.gif' style='margin:5px;' align='left'>",
"<img src='http://img83.imageshack.us/img83/5784/nlscbannercw9.png' style='margin:5px;",
"<img src='http://img12.imageshack.us/img12/7931/ne1j.gif' style='margin:5px;",
"<img src='http://www.nba-live.lt/images/reklama/468x60.gif' style='margin:5px;");
$cc = count($arr);
$cl = $cc-1;
$rand = rand(0,$cl);
echo"<center><a href=\"http://$arr[$rand]\">$bnr[$rand]</a></center>";
closeside();