userdata["acclevel"] < 80) die ("Access denied!");
?>
title; ?>
Warning: You are connecting to a remote daemon and do not have a Proxy Key configured.
";
echo "Please visit the HLstatsX:CE Settings page and configure a Proxy Key. Once configured, manually restart your daemon.
";
die();
}
}
echo "\n";
echo "- Sending Command to HLstatsX: CE Daemon at $host:$port — ";
$host = gethostbyname($host);
$socket = socket_create(AF_INET, SOCK_DGRAM, SOL_UDP);
$packet = "";
if ($g_options['Proxy_Key'])
{
$packet = "PROXY Key={$g_options['Proxy_Key']} PROXY C;".$command.";";
}
else
{
$packet = "C;".$command.";";
}
$bytes_sent = socket_sendto($socket, $packet, strlen($packet), 0, $host, $port);
echo "".$bytes_sent." bytes OK
";
echo "- Waiting for Backend Answer...";
$recv_bytes = 0;
$buffer = "";
$timeout = 5;
$answer = "";
$packets = 0;
$read = array($socket);
while (socket_select($read, $write = NULL, $except = NULL, $timeout) > 0) {
$recv_bytes += socket_recvfrom($socket, $buffer, 2000, 0, $host, $port);
$answer .= $buffer;
$buffer = "";
$timeout = "1";
$packets++;
}
echo "recieving $recv_bytes bytes in $packets packets...OK
";
if ($packets>0) {
echo "- Backend Answer: ".$answer."
";
}
else
{
echo "- No packets received — check if backend dead or not listening on $host:$port
";
}
echo "- Closing connection to backend...";
socket_close($socket);
echo "OK
";
echo "
\n";
echo " Return to Administration Center";
}
else
{
?>
After every configuration change made in the Administration Center, you should reload the daemon configuration. To do so, enter the hostname or IP address of your HLXCE daemon and choose the reload option. You can also shut down your daemon from this panel. NOTE: The daemon can not be restarted through the web interface!