I have been using joomla for a while now. I come across JRequest::setVar('hidemainmenu', 1) everyday but I couldn’t figure out what it is. Even though I comment that line nothing changes. What I want to know is does my code require JRequest::setVar('hidemainmenu', 1) ? Is it a standard to import that line ? Thanks
I have been using joomla for a while now. I come across JRequest::setVar(‘hidemainmenu’, 1)
Share
is used when we want to disable main menu in Joomla admin.
It is generally used in Editing sections of our component. It prevents users from leaving unsaved records open. Since user will not be able to use Joomla menu options at that time so the only option remains is component specific toolbar.
For example when you are viewing Userlist in Joomla admin user manager, you can access he main admin menu options but when you are editing a specific user , joomla admin menu is disabled.
This feature can be achieved by using
JRequest::setVar('hidemainmenu', 1)