/** * instance construction * * @return void */ function __construct() { self::$_instance = $this; ini_set('date.timezone', 'Asia/Shanghai'); //ini_set('display_errors', 'no'); $this->__printemps['start'] = mktime(true); $_dbconfig = Printemps_Config::read('database'); if ($_dbconfig) { $this->db = Printemps_Db::getInstance(); } $this->view = Printemps_View::getInstance(); $this->request = Printemps_Request::getInstance(); }
/** * BaseModel construction */ function __construct() { $this->db = Printemps_Db::getInstance(); self::$_instance = $this; }