different menu order for register user - Joomla! Forum - community, help and support


hi all
can have different order of menu login user ?
i using vm and  have " online-shop" menu on top of main menu login user , if not log in main menu become on top.
thanks in advance~sam

this done modifying template's index.php

with use of 2 different module positions - 1 each menu. use php logic arrange them differently logged in users e.g.


code: select all

<?php
if ( $my->id ) {  // logged in
mosloadmodules ( 'user5', -2 );
mosloadmodules ( 'left', -2 );
}
else { // not logged in
mosloadmodules ( 'left', -2 );
mosloadmodules ( 'user5', -2 );
}
 ?>


so publish 1 menu module e.g. left , other user5

the position order switched around when logged in / not





Comments

Popular posts from this blog

invalid use of void expresion in FlexiTimer2 library

error: a function-definition is not allowed here before '{' token

LED Strip Code