Ejemplo n.º 1
0
 /**
  * Function to get the instance of the class
  *
  * @return object instance of this class
  */
 public static function getInstance()
 {
     if (self::$instance === NULL) {
         self::$instance = new self();
     }
     return self::$instance;
 }
Ejemplo n.º 2
0
                (if you do not wish to automatically start DB connection, you can as well deactivate it).
            <br /><br />
            If you do not wish CLE to terminate script execution on DB connection error,<br />
                you can set that in configuration file as well.
            <br /><br />
        ');
    }
}
/* Autoload of classes */
function __autoload($class)
{
    global $_autoloadArray;
    if (in_array($class, array_keys($_autoloadArray))) {
        require_once $_autoloadArray[$class];
    }
}
/* Let's find out, what we will include and get some $_id stuff, if available */
$_fileToInclude = CL_SEO::getInstance()->getFileToInclude() . '.php';
/* Let's fire up modules */
$_CLE_Modules = CLE_Modules::getInstance();
/* Let's load some page! */
require_once $_fileToInclude;
/*
 * If "normal page" is requested
 * (not just some file-sending page)
 * It sets some variables and echoes the whole HTML code
 * (viz that file)
 */
if (@(!defined(CLE_DONT_LOAD_LAYOUT))) {
    require_once './sys/page.php';
}