diff options
Diffstat (limited to 'admin/WebConsole/includes/restfunctions.php')
-rw-r--r-- | admin/WebConsole/includes/restfunctions.php | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/admin/WebConsole/includes/restfunctions.php b/admin/WebConsole/includes/restfunctions.php index 59f9bb98..ea4ad8bd 100644 --- a/admin/WebConsole/includes/restfunctions.php +++ b/admin/WebConsole/includes/restfunctions.php @@ -11,6 +11,7 @@ define('OG_REST_CMD_WOL', 'wol'); define('OG_REST_CMD_SESSION', 'session'); define('OG_REST_CMD_RUN', 'shell/run'); define('OG_REST_CMD_OUTPUT', 'shell/output'); +define('OG_REST_CMD_POWEROFF', 'poweroff'); define('OG_REST_PARAM_CLIENTS', 'clients'); define('OG_REST_PARAM_ADDR', 'addr'); @@ -135,6 +136,15 @@ function session($string_ips, $params) { common_request(OG_REST_CMD_SESSION, POST, $data); } +function poweroff($string_ips) { + + $ips = explode(';',$string_ips); + + $data = array(OG_REST_PARAM_CLIENTS => $ips); + + common_request(OG_REST_CMD_POWEROFF, POST, $data); +} + /* * @function multiRequest. * @param URLs array (may include header and POST data), cURL options array. |