include "../../../cli/startup.php"; chdir($workingDirectory); // only for logged in users $user = \Pimcore\Tool\Authentication::authenticateSession(); if (!$user instanceof User) { die("Authentication failed!"); } if (!$user->isAdmin()) { die("Permission denied"); } @ini_set("display_errors", "Off"); /*######### /PIMCORE MODIFICATION #########*/ // Load libs require_once dirname(__FILE__) . '/init.php'; // Begin try { // Load settings and language $linfo = new Linfo(); // Run through /proc or wherever and build our list of settings $linfo->scan(); // Give it off in html/json/whatever $linfo->output(); } catch (LinfoFatalException $e) { echo $e->getMessage() . "\n"; exit(1); } // Developers: // if you include init.php as above and instantiate a $linfo // object, you can get an associative array of all of the // system info with $linfo->getInfo() after running $linfo->scan(); // Just catch the LinfoFatalException for fatal errors
public static function setUpBeforeClass() { $linfo = new Linfo(); $linfo->scan(); self::$output = new LinfoOutput($linfo); }