| | |
| | | |
| | | try { |
| | | # Init ILIAS |
| | | chdir(".."); |
| | | require_once("Services/Init/classes/class.ilInitialisation.php"); |
| | | ilInitialisation::initILIAS(); |
| | | |
| | |
| | | die(); // this ends here |
| | | } |
| | | |
| | | |
| | | |
| | | try { |
| | | switch ($command) { |
| | | case "ping": |
| | | if($method == "GET") { |
| | | $res["msg"] = "pong"; |
| | | $res["status"] = "ok"; |
| | | break; |
| | | } |
| | | case "deleteUser": |
| | | if ($method == "DELETE") { |
| | | $res["msg"] = deleteUser($obj_id, $dry); |
| | |
| | | } |
| | | default: |
| | | http_response_code(500); |
| | | $res = array("status" => "error", "msg" => "unknown command or method"); |
| | | $res["status"] = "error"; |
| | | $res["msg"] = "unknown command or method"; |
| | | } |
| | | } catch (Exception $err) { |
| | | http_response_code(500); |