Ejemplo n.º 1
0
 /**
  * Returns the status of all standard ZPanel hosting ports and the current server uptime.
  * @author Bobby Allen (ballen@bobbyallen.me)
  * @return type 
  */
 function GetServiceStatus()
 {
     $response_xml = ws_xmws::NewXMLContentSection('portstatus', array('web' => module_controller::getIsWebServerUp() == '' ? 0 : 1, 'ftp' => module_controller::getIsFTPUp() == '' ? 0 : 1, 'pop3' => module_controller::getIsPOP3Up() == '' ? 0 : 1, 'imap' => module_controller::getIsIMAPUp() == '' ? 0 : 1, 'smtp' => module_controller::getIsSMTPUp() == '' ? 0 : 1, 'mysql' => module_controller::getIsMySQLUp() == '' ? 0 : 1));
     $response_xml .= ws_xmws::NewXMLTag('serveruptime', sys_monitoring::ServerUptime());
     $dataobject = new runtime_dataobject();
     $dataobject->addItemValue('response', '');
     $dataobject->addItemValue('content', $response_xml);
     return $dataobject->getDataObject();
 }