yaf设置命名空间

修改yaf配置文件

文件是:yaf.ini

extension=yaf.so
yaf.use_namespace=1

index文件.

目录是application/controllers/Index.php

class IndexController extends Yaf\Controller_Abstract {
public function init() {
Yaf\Dispatcher::getInstance()->disableView();
}
/**
* 默认控制器
*/
public function indexAction() {
$site = Yaf\Application::app()->getConfig();
$re = $site->application->ext;
$this->getView()->assign('content','welcome,The yaf is works!');
$this->getView()->display('./index/index.html');
exit;
}
}
上一篇:pod》error:The dependency `` is not used in any concrete target


下一篇:js 得到当前季度