FATAL [$errno] $errstr
\n"; echo " Fatal error in line $errline of file $errfile"; echo ", PHP " . PHP_VERSION . " (" . PHP_OS . ")
\n"; echo ""; die(); break; case ERROR: echo "ERROR [$errno] $errstr
\n"; echo " Error in line $errline of file $errfile"; echo ", PHP " . PHP_VERSION . " (" . PHP_OS . ")
\n"; break; case WARNING: echo "WARNING [$errno] $errstr
\n"; echo " Non-Fatal error in line $errline of file $errfile"; echo ", PHP " . PHP_VERSION . " (" . PHP_OS . ")
\n"; break; case OTHER: echo "PARSE [$errno] $errstr
\n"; echo " Parse error in line $errline of file $errfile"; echo ", PHP " . PHP_VERSION . " (" . PHP_OS . ")
\n"; break; default: echo $errno; break; } echo "-->"; } // set to the user defined error handler $old_error_handler = set_error_handler("myErrorHandler"); function showFavorites() { global $favorites; $cnt = count($favorites); if ($cnt > 0) echo "("; for ($i=0;$i<$cnt;$i++) { $z = explode(",", $favorites[$i]); echo " $z[0] "; if ($i+1 < $cnt) echo checkmark(); } if ($cnt > 0) echo ")"; } $blockmode=0; $ip = $_GET['ip']; $port = $_GET['port'];$qgame = $_GET['game']; $blockmode = $_GET['block']; $libpath="./lib/"; // require our main library =) require($libpath.'main.lib.php'); ////////////////////////////////////////////////////////// function queryServer($address, $port, $protocol) { global $libpath; include_once($libpath."gsQuery.php"); if(!$address && !$port && !$protocol) { echo "No parameters given\n"; return FALSE; } $gameserver=gsQuery::createInstance($protocol, $address, $port); if(!$gameserver) { echo "Could not instantiate gsQuery class. Does the protocol you've specified exist?\n"; return FALSE; } if(!$gameserver->query_server(TRUE, TRUE)) { // fetch everything // query was not succesful, dumping some debug info echo "
Error ".$gameserver->errstr."
\n"; return FALSE; } return $gameserver; } ?>