* @version $Id:MVCLite.php 133 2007-08-26 08:19:13Z andre.moelle $ */ class Bootstrap extends MVCLite_Bootstrap { /** * Initializes the database. */ public function initDatabase () { switch ($this->getProfile()) { default: case 'development': $adapter = new MVCLite_Db_PDO('mysql:host=localhost;dbname=mvclite', 'root'); break; case 'test': break; case 'production': break; } if(isset($adapter)) { MVCLite_Db::getInstance()->setAdapter($adapter); } } /** * Initializes some options of error-handling. */ public function initError () { switch ($this->getProfile()) { case 'development': error_reporting(E_ALL); ini_set('display_errors', 'On'); MVCLite_Db::getInstance()->display(true); break; default: ini_set('display_errors', 'Off'); MVCLite_Db::getInstance()->display(false); break; } } } ?>