Example #1
0
// We don't want this to be called directly.
$compile = explode("/", $_SERVER["SCRIPT_FILENAME"]);
if ($compile[count($compile) - 1] == "compiler.php") {
    die("Please do not call \"compiler.php\" directly.");
}
#Page generated
$starttime = explode(' ', microtime());
$starttime = $starttime[1] + $starttime[0];
#Start us up
if (CRON != 1) {
    session_start();
}
#Stop the output
ob_start();
#Check for Dependencies
$d = checkForDependencies();
if ($d !== true) {
    die((string) $d);
}
#Check PHP Version
$version = explode(".", phpversion());
//Grab DB First
require LINK . "/class_db.php";
# Get the file
if (file_exists(LINK . "/conf.inc.php")) {
    include LINK . "/conf.inc.php";
    # Get the config
    define("NOCONFIG", false);
} else {
    define("NOCONFIG", true);
    define("PASSWORD_COST", 11);
Example #2
0
$compile = explode("/", $_SERVER["SCRIPT_FILENAME"]);
if ($compile[count($compile) - 1] == "compiler.php") {
    die("Please do not call \"compiler.php\" directly.");
}
//Page generated
$starttime = explode(' ', microtime());
$starttime = $starttime[1] + $starttime[0];
//Start us up
if (CRON != 1) {
    session_start();
    header("Cache-control: private");
}
//Stop the output
ob_start();
//Check for Dependencies
$deps = checkForDependencies();
if ($deps !== true) {
    die((string) $deps);
}
//Check PHP Version
$version = explode(".", phpversion());
//Grab DB First
require INC . "/instances/class_db.php";
if (file_exists(INC . "/conf.inc.php")) {
    include INC . "/conf.inc.php";
}
//Is THT installed?
if ($sql['install']) {
    define("INSTALL", 1);
}
$dbh = new dbh();