25 error_reporting(E_ALL);
28 if ((php_sapi_name() ==
'cli')) {
29 if (isset($_SERVER[
'argv'][1])) $SYSTEM_ROOT = $_SERVER[
'argv'][1];
30 $err_msg =
"ERROR: You need to supply the path to the System Root as the first argument\n";
33 if (isset($_GET[
'SYSTEM_ROOT'])) $SYSTEM_ROOT = $_GET[
'SYSTEM_ROOT'];
35 <div style="background-color: red; color: white; font-weight: bold;">
36 You need to supply the path to the System Root as a query string variable called SYSTEM_ROOT
40 if (empty($SYSTEM_ROOT)) {
45 if (!is_dir($SYSTEM_ROOT) || !is_readable($SYSTEM_ROOT.
'/core/include/init.inc')) {
46 echo
"ERROR: Path provided doesn't point to a Matrix installation's System Root. Please provide correct path and try again.\n";
50 require_once $SYSTEM_ROOT.
'/core/include/init.inc';
53 require_once SQ_INCLUDE_PATH.
'/system_asset_config.inc';
54 $GLOBALS[
'SQ_SYSTEM']->setRunLevel(SQ_RUN_LEVEL_FORCED);
56 $sys_asset_cfg->save(Array(),
true);
57 $GLOBALS[
'SQ_SYSTEM']->restoreRunLevel(SQ_RUN_LEVEL_FORCED);