X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Fconfig.php;h=02302f23bdaac3ac818ccc4243a7bb7edda66cc2;hb=c9beed8839a04b5a170f2aca90b86623d097c5ad;hp=142093ba2955c64cb7a193a8736b871fa9268e1a;hpb=65d72098d3ec6a0ef7782668264fc6f33f9ebeb6;p=shipsimu.git diff --git a/inc/config.php b/inc/config.php index 142093b..02302f2 100644 --- a/inc/config.php +++ b/inc/config.php @@ -8,7 +8,7 @@ * @version 0.0.0 * @copyright Copyright(c) 2007, 2008 Roland Haeder, this is free software * @license GNU GPL 3.0 or any newer version - * @link http://www.ship-simu.org + * @link http://www.ship-simu.org * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -25,6 +25,8 @@ */ // Load the class from inc/config direktory +@require_once(dirname(__FILE__) . '/classes/interfaces/class_FrameworkInterface.php'); +@require_once(dirname(__FILE__) . '/classes/interfaces/registry/class_Registerable.php'); @require_once(dirname(__FILE__) . '/config/class_FrameworkConfiguration.php'); // Get a new configuration instance @@ -33,6 +35,9 @@ $cfg = FrameworkConfiguration::createFrameworkConfiguration(); // CFG: SERVER-PATH $cfg->definePath(dirname(dirname(__FILE__)) . '/'); // DON'T MISS THE TRAILING SLASH!!! +// CFG: BASE-URL +$cfg->setConfigEntry('base_url', $cfg->detectBaseUrl()); + // CFG: DATABASE-TYPE $cfg->defineDatabaseType('local'); @@ -213,5 +218,20 @@ $cfg->setConfigEntry('is_single_server', "Y"); // CFG: POST-REGISTRATION-ACTION $cfg->setConfigEntry('post_registration_action', "LoginAfterRegistrationAction"); +// CFG: USER-CLASS +$cfg->setConfigEntry('user_class', "User"); + +// CFG: COOKIE-EXPIRE +$cfg->setConfigEntry('cookie_expire', 60*60*2); // Two hours! + +// CFG: COOKIE-PATH +$cfg->setConfigEntry('cookie_path', dirname($_SERVER['SCRIPT_NAME']) . "/"); + +// CFG: COOKIE-DOMAIN +$cfg->setConfigEntry('cookie_domain', $cfg->detectDomain()); // Is mostly the same... + +// CFG: COOKIE-SSL +$cfg->setConfigEntry('cookie_ssl', (isset($_SERVER['HTTPS']))); + // [EOF] ?>