10

Each time I install new extension, and open the admin - system - configuration - module options I get 404 error.

Logging out and in helps, but how to avoid this? The issue has something to do with the admin permissions cache, but how to refresh it programmatically, say, from the install script?

Any ideas?

9

This behavior occurs because Magento caches the ACL in the admin user's session. Here's the relevant line from Mage_Admin_Model_Session::login():

$this->setAcl(Mage::getResourceModel('admin/acl')->loadAcl());

You can have the ACL cache reloaded ("refreshed") by using the following code:

$session = Mage::getSingleton('admin/session');
$session->setReloadAclFlag(true);
$session->refreshAcl();

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.