Whats the way to use Zend_Acl in View to show/hide parts of view
问题 I am wondering whats the way to use Zend_Acl to show/hide parts of view? I am thinking I will Create a Controller Plugin that passes the logged in user + acl to view $this->view->loggedInUser = Zend_Auth::getIdentity(); $this->view->acl = Zend_Registry::get('acl'); Then in view scripts do something like $this->acl->isAllowed($this->view->loggedInUser, 'resource', 'privilege'); Or is there a better way? Or should I use a View Helper? That returns a boolean whether the logged in user is allowed