From: alex <bin...@li...> - 2001-07-28 17:32:34
|
alex Sat Jul 28 10:32:28 2001 EDT Modified files: /r2/binarycloud/base/init Init.php Log: Added _load_cache method to Init, Cache class is coming. Index: r2/binarycloud/base/init/Init.php diff -u r2/binarycloud/base/init/Init.php:1.34 r2/binarycloud/base/init/Init.php:1.35 --- r2/binarycloud/base/init/Init.php:1.34 Wed Jul 25 13:58:58 2001 +++ r2/binarycloud/base/init/Init.php Sat Jul 28 10:32:28 2001 @@ -1,7 +1,7 @@ <?php // Header {{{ /******************************************************************************* - ** -File $Id: Init.php,v 1.34 2001/07/25 20:58:58 alex Exp $ + ** -File $Id: Init.php,v 1.35 2001/07/28 17:32:28 alex Exp $ ** -License LGPL (http://www.gnu.org/copyleft/lesser.html) ** -Copyright 2001, The Turing Studio, Inc. ** -Author alex black, en...@tu... @@ -70,6 +70,7 @@ $this->_load_pear(); $this->_load_auth(); $this->_load_perm(); +// $this->_load_cache(); $this->_load_page(); } @@ -305,6 +306,34 @@ global $Perm; $Perm = new Perm(); $Perm->Check_Permissions(); + return true; + } else { + return false; + } + } + + + // }}} + // {{{ _load_cache + + /** + * If $gPageDef['init']['cache'] is set, this method imports + * the Cache class, and passes the options contained in + * $gPageDef['init']['cache'] to it. + * + * @author alex black, en...@tu... + * @return true if Cache is loaded, false if it is not + * @access private + */ + + function _load_cache() { + global $gPageDef; + + if (isset($gPageDef['init']['cache'])) { + import('binarycloud.core.Cache'); + global $Cache; + $Cache = new Cache(); + $Cache->options=$gPageDef['init']['cache']; return true; } else { return false; |