diff --git a/config/environment.php b/config/environment.php index f0e917b..8002d57 100644 --- a/config/environment.php +++ b/config/environment.php @@ -2,7 +2,7 @@ /* Zynapse Environment - - configure server environments and display modes + - configure server environment */ diff --git a/vendor/zynapse/action_base.php b/vendor/zynapse/action_base.php index cd57561..b26a65f 100644 --- a/vendor/zynapse/action_base.php +++ b/vendor/zynapse/action_base.php @@ -56,26 +56,10 @@ class ActionBase { public function __construct () { - - } - - public function __sleep () { - $blacklist = array_flip(array("env", "view", "log", "locale")); - $save = array(); - foreach( $this as $key => $value ) { - if ( !array_key_exists($key, $blacklist) ) { - $save[] = $key; - } - } - return $save; - } - - public function __wakeup () { - + $this->set_paths(); } public function init () { - $this->set_paths(); $this->started = true; } diff --git a/vendor/zynapse/action_environment.php b/vendor/zynapse/action_environment.php index 3347288..07f99e2 100644 --- a/vendor/zynapse/action_environment.php +++ b/vendor/zynapse/action_environment.php @@ -52,7 +52,7 @@ class ActionEnvironment { function __construct () { - + $this->set_include_paths(); } function init () { @@ -61,11 +61,6 @@ class ActionEnvironment { $this->started = true; } - function __wakeup () { - $this->set_include_paths(); - $this->define_constants(); - } - function load_environment_file () { require_once(ZNAP_CONFIG."/environment.php"); if ( !empty($enable_host_specific_configuration) ) { diff --git a/vendor/zynapse/action_view.php b/vendor/zynapse/action_view.php index 9acfb57..bd739a0 100644 --- a/vendor/zynapse/action_view.php +++ b/vendor/zynapse/action_view.php @@ -51,7 +51,6 @@ class ActionView { } function init () { - $this->started = true; } diff --git a/vendor/zynapse/active_log.php b/vendor/zynapse/active_log.php new file mode 100644 index 0000000..ba7595a --- /dev/null +++ b/vendor/zynapse/active_log.php @@ -0,0 +1,59 @@ +started = true; + } + +} + +?> \ No newline at end of file diff --git a/vendor/zynapse/zynapse.php b/vendor/zynapse/zynapse.php index 9c7cc7a..8b382f9 100644 --- a/vendor/zynapse/zynapse.php +++ b/vendor/zynapse/zynapse.php @@ -46,31 +46,40 @@ class Zynapse { function init () { require_once(ZNAP_LIB_ROOT."/action_environment.php"); + require_once(ZNAP_LIB_ROOT."/active_session.php"); require_once(ZNAP_LIB_ROOT."/action_base.php"); require_once(ZNAP_LIB_ROOT."/action_view.php"); - require_once(ZNAP_LIB_ROOT."/active_session.php"); + require_once(ZNAP_LIB_ROOT."/active_log.php"); # Create component objects - self::$session = new ActiveSession(); self::$env = new ActionEnvironment(); + self::$session = new ActiveSession(); self::$base = new ActionBase(); self::$view = new ActionView(); + self::$log = new ActiveLog(); # Assign internal component references self::$env->session =& self::$session; + self::$env->base =& self::$base; self::$base->env =& self::$env; self::$base->view =& self::$view; - // self::$base->log =& self::$log; //TODO Create ActionLog class + self::$base->log =& self::$log; self::$base->locale =& self::$locale; self::$base->session =& self::$session; self::$view->env =& self::$env; self::$view->base =& self::$base; - // self::$view->log =& self::$log; //TODO Create ActionLog class + self::$view->log =& self::$log; self::$view->locale =& self::$locale; self::$view->session =& self::$session; + self::$log->env =& self::$env; + self::$log->base =& self::$base; + self::$log->view =& self::$view; + self::$log->locale =& self::$locale; + self::$log->session =& self::$session; + # Init the environment system (ActionEnvironment) self::$env->init(); @@ -81,6 +90,9 @@ class Zynapse { # Init the core controller system (ActionBase) self::$base->init(); + # Init the logging system (ActiveLog) + self::$log->init(); + # Init the output and page rendering system (ActionView) self::$view->init();