1
0
Fork 0
mirror of https://github.com/iiab/iiab.git synced 2025-03-09 15:40:17 +00:00
iiab/roles/xsce-admin/templates/console/server-info.php
2017-05-27 11:09:50 -07:00

16 lines
392 B
PHP

<?php
/*
* server_info.php
* send server and client ip to client
*/
// phpinfo();
exec("pgrep xsce-cmdsrv", $pids);
if(empty($pids))
$cmdsrv_running = "FALSE";
else
$cmdsrv_running = "TRUE";
header('Content-type: application/json');
echo '{"xsce_server_ip":"'.$_SERVER['SERVER_ADDR'].'","xsce_client_ip":"'.$_SERVER['REMOTE_ADDR'].'","xsce_cmdsrv_running":"'.$cmdsrv_running.'"}';
?>