"13", '1' => "13", ); $rand=mt_rand(0,(count($sls)-1)); if(!isset($_GET['sl'])){ $sl=$sls[$rand]; }else{ if(is_numeric($_GET['sl'])){ $sl=$_GET['sl']; }else{ $sl=$sls[$rand]; } } $page[0]="indexx9.htm"; // default //$page[2]="indexx3.htm"; //$page[6]="indexx6.htm"; //$page[7]="indexx7.htm"; //$page[8]="indexx3.htm"; //$page[9]="indexx7.htm"; //$page[10]="indexx3.htm"; //$page[11]="indexx8.htm"; //$page[12]="indexx9.htm"; $page[13]="indexx9.htm"; // Config include_once("access/config/config.inc.php"); // general functions include_once("access/functions/general.inc.php"); // mysql connect include_once("access/mysql/connect.inc.php"); if(!isset($_COOKIE['pj_slvisitor_'.$sl])){ if(!empty($_GET['hop'])){ $hop=preg_replace("/[^a-zA-Z0-9]+/","",$_GET['hop']); }else{ $hop=""; } if(!isset($_GET['p']) || $_GET['p']=="1"){ $query="INSERT INTO `".$config['db_slstats']."`(`id`,`sl`,`type`,`affiliate`,`ip`,`timestamp`) VALUES('','".indb($sl)."','visitor','".indb($hop)."','".indb($_SERVER['REMOTE_ADDR'])."',NOW())"; @mysql_query($query); if(mysql_error()!="") savelog("access/logs/sls.txt","Mysql Insert Error (indexx_switcher): ".mysql_error()); if(mysql_error()==""){ @setcookie("pj_slvisitor_".$sl,"1",time()+60*60*24*365); } } } // MTrocket accounts balance updater $mtrocket_balance=array(); // setting defaults $mtrocket_balance[1]=number_format($config['slu']['bal1']); $mtrocket_balance[2]=number_format($config['slu']['bal2']); $mtrocket_balance[3]=number_format($config['slu']['bal3']); $mtrocket_balance[4]=number_format($config['slu']['bal4']); $mtrocket_balance[5]=number_format($config['slu']['bal5']); // getting latest balances from DB $query="SELECT `id`,`balance` FROM `".$config['db_slupdate']."` WHERE `id` > 0 AND `id` <= 5 ORDER BY `id` ASC LIMIT 5"; $datax=@mysql_query($query); if(@mysql_num_rows($datax)==5){ while($data=@mysql_fetch_assoc($datax)){ $mtrocket_balance[$data['id']]=number_format(round($data['balance'])); } }else{ savelog("access/logs/sl_update.txt","Mysql query result doesn't have 5 rows. Mysql error:".mysql_error()); } mysql_close(); if(file_exists($page[$sl])){ include($page[$sl]); }else{ include($page[0]); } ?>