diff options
author | Gitea <gitea@fake.local> | 2021-11-10 17:53:50 +0100 |
---|---|---|
committer | Gitea <gitea@fake.local> | 2021-11-10 17:53:50 +0100 |
commit | 8fabf77b2a7720a357c63817c07035a9908818a0 (patch) | |
tree | d689fcac1403e2473010fe80bc337599a78c21a4 /Neutron-trunk/api/setup/check.php | |
parent | 7b4af63a90a726b98a59b83e53f040a7a566a11d (diff) | |
download | electrode-8fabf77b2a7720a357c63817c07035a9908818a0.tar.gz electrode-8fabf77b2a7720a357c63817c07035a9908818a0.tar.bz2 electrode-8fabf77b2a7720a357c63817c07035a9908818a0.zip |
Update
Diffstat (limited to 'Neutron-trunk/api/setup/check.php')
-rw-r--r-- | Neutron-trunk/api/setup/check.php | 30 |
1 files changed, 0 insertions, 30 deletions
diff --git a/Neutron-trunk/api/setup/check.php b/Neutron-trunk/api/setup/check.php deleted file mode 100644 index d3eb831..0000000 --- a/Neutron-trunk/api/setup/check.php +++ /dev/null @@ -1,30 +0,0 @@ -<?php require_once "../../resources/private/relative.php"; getRelativeDetails("api"); ?> -<?php - -// require $_SERVER['DOCUMENT_ROOT'] . "/api/electrode/quit.php";quit("It works!"); - -if (substr($_SERVER['SERVER_PROTOCOL'], 0, 4) != "HTTP") { - require $_SERVER['DOCUMENT_ROOT'] . "/api/electrode/quit.php";quit("Unsupported protocol"); -} - -if ($_SERVER['REQUEST_METHOD'] != "GET") { - require $_SERVER['DOCUMENT_ROOT'] . "/api/electrode/quit.php";quit("Unsupported request method"); -} - -if (!file_exists($_SERVER['DOCUMENT_ROOT'] . "/resources/upload")) { - mkdir($_SERVER['DOCUMENT_ROOT'] . "/resources/upload"); -} - -ob_start(); -phpinfo(); -$data = ob_get_contents(); -ob_clean(); -if (strpos($data, '<tr><td class="e">GD Support </td><td class="v">enabled </td></tr>') !== false || strpos($data, 'GD Support => enabled') !== false) {} else { - require $_SERVER['DOCUMENT_ROOT'] . "/api/electrode/quit.php";quit("The GD2 library is not installed or enabled"); -} - -if (strpos($_SERVER['HTTP_USER_AGENT'], 'Chrome') !== false || strpos($_SERVER['HTTP_USER_AGENT'], 'Firefox') !== false) {} else { - require $_SERVER['DOCUMENT_ROOT'] . "/api/electrode/quit.php";quit("Unsupported browser, please use Chrome, Chrome-based or Firefox"); -} - -require $_SERVER['DOCUMENT_ROOT'] . "/api/electrode/quit.php";quit("ok"); |