/** * This action will try to send a shutdown message to the device specified by $_GET['ip']. * * @return void */ public function shutdownAction() { if (isset($_GET['ip'], $_GET['user'], $_GET['password'])) { $output = Devices::shutdown($_GET['ip'], $_GET['user'], $_GET['password']); if (isset($output[1])) { die(strpos($output[1], 'succeeded') !== false ? "true" : "false"); } } die("false"); }