| 1 |
<?php
|
| 2 |
// $Id: settings.inc,v 1.2 2008/10/03 15:47:55 agentken Exp $
|
| 3 |
/**
|
| 4 |
*
|
| 5 |
* @file
|
| 6 |
* settings.inc
|
| 7 |
*
|
| 8 |
* This file should be included at the bottom of your settings.php file:
|
| 9 |
* <?php
|
| 10 |
* include '/sites/all/modules/domain/settings.inc';
|
| 11 |
* ?>
|
| 12 |
* If you have installed the domain module into a different folder than
|
| 13 |
* /sites/all/modules/domain please adjust the path approriately.
|
| 14 |
*
|
| 15 |
* @ingroup domain
|
| 16 |
*/
|
| 17 |
|
| 18 |
/**
|
| 19 |
* Include bootstrap file, setup checker function and start bootstrap phases.
|
| 20 |
*/
|
| 21 |
include 'domain.bootstrap.inc';
|
| 22 |
domain_settings_setup_ok();
|
| 23 |
domain_bootstrap();
|
| 24 |
|
| 25 |
/**
|
| 26 |
* Small helper function to determine whether this file was included correctly in
|
| 27 |
* the user's settings.php
|
| 28 |
*
|
| 29 |
* If it was included at the right time then cache.inc shouldn't be included
|
| 30 |
* yet and the function 'cache_get' not be defined.
|
| 31 |
*
|
| 32 |
* When the function is called first (from within this file) the state is saved
|
| 33 |
* in a static variable, every later call will return that boolean value.
|
| 34 |
*
|
| 35 |
* @return
|
| 36 |
* TRUE if settings.inc was included correctly in settings.php, else FALSE
|
| 37 |
*/
|
| 38 |
function domain_settings_setup_ok() {
|
| 39 |
static $state = NULL;
|
| 40 |
if ($state === NULL) {
|
| 41 |
$state = !function_exists('cache_get');
|
| 42 |
}
|
| 43 |
return $state;
|
| 44 |
}
|