Example #1
0
 public function __construct()
 {
     parent::__construct();
     $this->ret = array();
     $this->ret['ret'] = array();
     $this->ret['ret']['portals'] = array();
     $this->ret['ret']['categories'] = array();
     $this->ret['count'] = 0;
 }
Example #2
0
function __autoload($class)
{
    global $config;
    if (in_array($class, $config['registered_modules']) && preg_grep('/^[a-zA-Z]+$/', array($class))) {
        $moduleFile = $config['libpath'] . $class . ".php";
        if (file_exists($moduleFile)) {
            require_once $config['libpath'] . $class . ".php";
            if (!class_exists($class)) {
                throw new arcException("Autoloader could not find class: '{$class}' in {$moduleFile}");
            }
        } else {
            throw new arcException("Autoloader could not find modulefile: {$moduleFile}");
        }
    } else {
        //not registered
        $text = $_SERVER['REDIRECT_STATUS'] == '403' ? e('403_forbidden') : e('404_not_found');
        $arc = new arcanum();
        $arc->view_fallback('', $text, '');
    }
}
Example #3
0
 public function __construct()
 {
     parent::__construct();
 }
Example #4
0
 public function __construct()
 {
     parent::__construct();
     $users = DB_DataObject::factory('users');
     define('REGISTERED_USERS', $users->find());
 }