= 1 AND status = 1"); if (mysql_num_rows($chk1) != 0) { include("sections/sct_1.php"); } else { include("sections/sct_2.php"); } while ($rand_rows = mysql_fetch_array($avail)) { $id_array[] = $rand_rows[id]; } srand((double)microtime()*1000000); shuffle($id_array); srand((double)microtime()*1000000); shuffle($id_array); $pick = $id_array[0]; $gb = mysql_query("select * from $table where id = '$pick'"); while($rand_ban = mysql_fetch_array($gb)) { $ban_array[] = $rand_ban[num]; } srand((double)microtime()*1000000); shuffle($ban_array); srand((double)microtime()*1000000); shuffle($ban_array); $bannernum=$ban_array[0]; $igb= mysql_query("select * from $table where num = '$bannernum'"); $bandet = mysql_fetch_array($igb); $number = $bandet[num]; $banner = $bandet[url]; $uip = getenv ("REMOTE_ADDR"); $eip = mysql_query("select ip from idevban_accounts where id = $id and ip = '$uip'"); if (mysql_num_rows($eip)) { $ipe = 1; } $ckcreds = mysql_query("select credits from idevban_accounts where id = '$pick'"); $un = mysql_fetch_array($ckcreds); $unlim = $un[credits]; if (($_COOKIE['idevbanx'] != $id) && (!$ipe)) { setcookie ("idevbanx",$id, time()+$expire); if ($stats == 1) { if ($ratio == 1) { include("sections/sct_3.php"); } elseif ($ratio != 1) { include("sections/sct_4.php"); } mysql_query("update idevban_banners set views=views+1 where num = $number"); } elseif ($stats == 0) { include("sections/sct_5.php"); } } else { include("sections/sct_6.php"); } mysql_query("update idevban_accounts set ip = '$uip' where id = $id"); print ""; ?>