<?php require_once '../../etc/app.config.php'; require_once 'Hush/App.php'; $app = new Hush_App(); $app->setErrorPage('./404.php')->addMapFile(__MAP_INI_FILE)->addAppDir(__LIB_PATH_SERVER)->addAppDir(__LIB_PATH_WEBSITE); /** * skip 404 page and trace exception * TODO : should be commented in www environment */ $app->setDebug(true); $app->run(array('defaultClassSuffix' => 'Server'));
<?php require_once '../../etc/frontend.config.php'; require_once 'Hush/App.php'; $app = new Hush_App(); $app->setTplDir(__TPL_SMARTY_PATH)->setErrorPage('html/404.htm')->addMapFile(__MAP_INI_FILE)->addAppDir(__LIB_PATH_PAGE); /** * skip 404 page and trace exception * TODO : should be commented in www environment */ $app->setDebug(true); $app->run();
<?php /** * Hush Framework * * @category Hush * @package Hush_Service * @author James.Huang <*****@*****.**> * @license http://www.apache.org/licenses/LICENSE-2.0 * @version $Id$ */ /** * Service class do not need page view components * Default view engine is smarty */ Hush_App::setPageView(false); /** * @see Hush_Debug */ require_once 'Hush/Debug.php'; /** * @see Hush_Util */ require_once 'Hush/Util.php'; /** * @package Hush_Service */ class Hush_Service { /** * @var Hush_Debug
<?php require_once '../../etc/frontend.config.php'; require_once 'Hush/App.php'; $app = new Hush_App(); $app->setTplDir(__TPL_SMARTY_PATH)->setErrorPage('html/404.htm', 404)->setErrorPage('html/500.htm', 500)->addMapFile(__MAP_INI_FILE)->addAppDir(__LIB_PATH_PAGE); /** * skip 404 page and trace exception * TODO : should be commented in www environment */ $app->setDebug(true); /** * set page's debug level * Hush_Debug::DEBUG * TODO : should be changed to Hush_Debug::FATAL in www environment */ if ($_GET['debug']) { $app->setDebugLevel(Hush_Debug::DEBUG); } else { $app->setDebugLevel(Hush_Debug::FATAL); } $app->run();