该项目使用CakePHP,1.3不能升级项目的CakePHP-2.0
现在我想要升级到CakePHP的-2.0
我已经改名为所有控制器和模式CakePHP的开发-2.0公约。
现在,如果我重新载入我的错误是这样的页面:
Indirect modification of overloaded property PostsController::$Auth has no effect [APP/Controller/PostsController.php, line 11]
代码:
PostsController:
$this->Auth->allowedActions =
array('index','view','archive','listarchive','viewfromcategory','tags','aboutme','contact','polls');
的AppController:
class AppController extends Controller {
var $components = array('Acl', 'Session', 'Auth','RequestHandler');
//var $helpers = array('Html', 'Form','Js','Session','Cache');
var $helpers = array('Html', 'Form','Js','Session');
function beforeFilter() {
//Configure AuthComponent
$this->Auth->actionPath = 'controllers/';
$this->Auth->allowedActions = array('display');
//$this->Auth->authorize = 'actions';
$this->Auth->loginAction = array('controller' => 'users', 'action' => 'login');
$this->Auth->logoutRedirect = array('controller' => 'posts', 'action' => 'index');
$this->Auth->loginRedirect = array('controller' => 'posts', 'action' => 'index');
}
哪有我修复这个公关oblem?