本文整理汇总了PHP中Server::getInfo方法的典型用法代码示例。如果您正苦于以下问题:PHP Server::getInfo方法的具体用法?PHP Server::getInfo怎么用?PHP Server::getInfo使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Server
的用法示例。
在下文中一共展示了Server::getInfo方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: list
display:inline;
}
.error {
font-weight:bold;
color:#FF3300;
display:inline;
}
</style>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head>
<?php
}
if ($action == 1) {
// server info
list($server_version, $server_releaseDate, $server_opMode, $server_isMasterServer, $server_admin_email, $php_version, $mysql_server_info, $mysql_client_info) = $server->getInfo();
echo "Leonardo version: {$server_version}<br>\n\t\tversion releaseDate:\t{$server_releaseDate}<br>\n\t\topMode: {$server_opMode}<br>\n\t\tisMasterServer: {$server_isMasterServer}<br>\n\t\tadmin_email: {$server_admin_email}<br>\n\t\tphp_version: {$php_version}<br>\n\t\tmysql_server_info: {$mysql_server_info}<BR>\n\t\tmysql_client_info: {$mysql_client_info}<BR>";
} else {
if ($action == 2) {
$takeoffsList = $server->getTakeoffs(0);
// takeoffs from time 0
echo "<HR>Takeoff list<hr>";
//print_r($takeoffsList);
foreach ($takeoffsList as $takeoff) {
$takeoff = (object) $takeoff;
echo "#" . urldecode($takeoff->intName) . "#" . urldecode($takeoff->name) . "#<BR>";
}
} else {
if ($action == 3) {
//flights
} else {
示例2: lng
$info .= lng('SERVER_DELETED');
} else {
$info .= lng('SERVER_NOT_EXIST');
}
$id = false;
}
/* Output */
if ($id) {
$server = new Server($id, $st_subdir . 'server/');
$server->UpdateState(true);
$server_info = $server->ShowHolder('mon', 'adm');
if (!$server->Exist()) {
$info .= lng('SERVER_NOT_EXIST');
break;
}
$serv_sysinfo = $server->getInfo();
$serv_name = TextBase::HTMLDestruct($serv_sysinfo['name']);
$serv_method = $serv_sysinfo['method'];
$serv_ref = $serv_sysinfo['refresh'];
$serv_address = $serv_sysinfo['address'];
$serv_port = $serv_sysinfo['port'];
$serv_s_user = $serv_sysinfo['s_user'] ? $serv_sysinfo['s_user'] : '';
$serv_info = TextBase::HTMLDestruct($serv_sysinfo['info']);
$serv_priority = $server->GetPriority();
$serv_side = $server->GetVisible('side');
$serv_game = $server->GetVisible('game');
$serv_mon = $server->GetVisible('mon');
include View::Get('server_edit.html', $st_subdir . 'server/');
} else {
include View::Get('server_add.html', $st_subdir . 'server/');
}
示例3: server
/**
* Server info endpoint
*/
protected function server()
{
if (count($this->args) === 0) {
return Server::getInfo();
}
}