BMLT Root Server
get-config.php
Go to the documentation of this file.
1 <?php
2 if (file_exists(dirname(__FILE__).'/../../../auto-config.inc.php')) {
3  if ((fileperms(dirname(__FILE__).'/../../../auto-config.inc.php') & 0x0002) == 0x0002) {
4  die('The auto-config.inc.php file is still writeable! Security requires that it be set to read-only!');
5  }
6 
7  require(dirname(__FILE__).'/../../../auto-config.inc.php');
8 } elseif (file_exists(dirname(__FILE__).'/../../../test_auto.inc.php')) {
9  if ((fileperms(dirname(__FILE__).'/../../../test_auto.inc.php') & 0x0002) == 0x0002) {
10  die('The test_auto.inc.php file is still writeable! Security requires that it be set to read-only!');
11  }
12 
13  require(dirname(__FILE__).'/../../../test_auto.inc.php');
14 } elseif (file_exists(dirname(__FILE__).'/auto-config.inc.php')) {
15  $realpath = realpath(dirname(__FILE__).'/../../../');
16  $basename = basename(realpath(dirname(__FILE__).'/../../'));
17  die(sprintf('The auto-config.inc.php file is in the wrong location! You need to move it out of this directory, and into the %s directory (the same directory as the %s directory)!', $realpath, $basename));
18 }
19 
20 if (isset($gKey) && !isset($gkey)) {
21  $gkey = $gKey;
22 }
function sprintf()
Definition: installer.js:873
$realpath
$basename