CodeIgniter Forums

Full Version: Dynamic menus for different kind of users
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

El Forum


I need to create different menus for different users based on their roles. For this, one approach I get is to make a separate view of header and add it in all views. Through this view will call a controller which will generate a menu through DB and return to this view. In this case each time the page is changed request will go to DB which will cause slow response of page.

Is there anyway to store HTML of menu (globally) when user logs in and just access this variable each time as page changed??