<?php
/**
 * 基本控制器
 *
 */
class TopAction extends FuncAction{
    protected function _initialize() {
        //消除所有的magic_quotes_gpc转义
        Input::noGPC();
        //初始化网站配置
        if (false === $setting = F('setting')) {
            $setting = D('setting')->setting_cache();
        }
        C($setting);
        
    }
     
    public function _empty() {
        $this->_404();
    }
    
    protected function _404($url = '') {
        if ($url) {
            redirect($url);
        } else {			
            send_http_status(404);
            $this->display(APP_NAME . '/Tpl/404.html');
            exit;
        }
    }
		


}
?>