hide mainmenu

Responsive Joomla template for Entertainment and Music purpose with clean and lightweight design.
GK User
Wed Jun 06, 2012 8:27 pm
Hi
I was wondering if it is possible to hide the mainmenu as soon as a user logsin in jomsocial.
And then when he logs out the mainmenu shows up again...
like that the user will see the mainmenu of the template or the JS menu but never both together....

is that possible with some rule?


thx
Oliver
User avatar
Junior Boarder

Konrad M
Thu Jun 07, 2012 11:52 am
Hi,
you can try do it using css and js. Probably you need to check using js if js menu is in DOM. If exisit you have to add to 'div' element which contains main menu 'display:none' css rule. Something like this:
Code: Select all
window.addEvent('domready', function(){
var jsMenu = getElementById('jsMenu');
if(jsMenu) {
  // here use jquery or mootols to add class to mainmenu div or add display:none rule
}
});

User avatar


cron