Пример #1
0
 public static function run($bootstrap)
 {
     $includePaths = dirname(__FILE__);
     set_include_path($includePaths);
     spl_autoload_register(array(__CLASS__, 'autoload'));
     Core_Session_Object::setSessionId();
     self::$applicationPath = $includePaths;
     self::$includePath = dirname(__FILE__);
     if (!isset($bootstrap)) {
         throw new Core_Exceptions("Bootstrap is not implemented");
     }
     self::runBootstrap($bootstrap);
     self::displayContent();
 }
Пример #2
0
 public static function setSessionId($value = null)
 {
     if (isset($_SESSION)) {
         return false;
     }
     if ($value !== null) {
         session_id($value);
         return;
     }
     if (session_id() == '') {
         $sessionId = '';
         if (isset($_GET['session'])) {
             session_id($_GET['session']);
         } else {
             if (isset($_COOKIE['PHPSESSID'])) {
                 session_id($_COOKIE['PHPSESSID']);
             } else {
                 session_id(Core_Session_Object::generateSessionId());
             }
         }
     }
 }
Пример #3
0
 public function __construct($sessionId = null)
 {
     parent::__construct();
 }