Foros de discusión
Navigation menu
Kim Capa, modificado hace 9 años.
Navigation menu
Junior Member Mensajes: 49 Fecha de incorporación: 31/07/14 Mensajes recientes
Hi..
is it possible in liferay to have a 2 navigation menu?
like
navigation_top and then
navigation_main
thanks!
kim
is it possible in liferay to have a 2 navigation menu?
like
navigation_top and then
navigation_main
thanks!
kim
Ravi Kumar Gupta, modificado hace 9 años.
RE: Navigation menu
Liferay Legend Mensajes: 1302 Fecha de incorporación: 24/06/09 Mensajes recientes
Why not?
You can develop your own theme. See in classic theme how navigation.vm is developed and how navigation.vm is included. You can create pages[from control panel] in liferay as they are but you can choose how they are displayed in theme.
You can develop your own theme. See in classic theme how navigation.vm is developed and how navigation.vm is included. You can create pages[from control panel] in liferay as they are but you can choose how they are displayed in theme.
#if ($has_navigation || $is_signed_in)
#parse ("$full_templates_path/navigation.vm")
#end
Kim Capa, modificado hace 9 años.
RE: Navigation menu
Junior Member Mensajes: 49 Fecha de incorporación: 31/07/14 Mensajes recientes
Hi ravi,
what i did is i put the code in HTML to the portal_normal.vm
and i just link it to hidden portlet. and it's working fine
kim
what i did is i put the code in HTML to the portal_normal.vm
and i just link it to hidden portlet. and it's working fine
kim
Mohd Danish, modificado hace 9 años.
RE: Navigation menu
Regular Member Mensajes: 187 Fecha de incorporación: 5/03/12 Mensajes recientes
Putting HTML code will not be dynamic. For that what you can do is below
Firstly you are to have two nav tags.
Then you are suppose to have a differentiation between the pages of the two bars.
For example in the below code we have used fn and sn to differentiate between the two pages.
If a page name starts with fn then it goes to 1st navigation bar else it goes to 2nd navigation bar.
Firstly you are to have two nav tags.
Then you are suppose to have a differentiation between the pages of the two bars.
For example in the below code we have used fn and sn to differentiate between the two pages.
If a page name starts with fn then it goes to 1st navigation bar else it goes to 2nd navigation bar.
<nav class="sort-pages modify-pages" id="navigation">
<ul>
#foreach ($nav_item in $nav_items)
#if($nav_item.getName().substring(0,2) == "fn")
#if ($nav_item.getName()=="fn-home")
<li class="selected" id="navBackground" style=" padding-top: 1px; height: 32px;">
#elseif ($nav_item.isSelected())
</li><li class="selected" id="nav1Button">
#else
</li><li id="nav1Button">
#end
#if ($nav_item.getName()=="fn-home")
<a href="/web/guest/home" style="color:#fff;padding-left: 42px;width: 68px;"><span style="margin-right: 15px; ">$nav_item.getName().substring(3)</span></a>
#else
<a href="$nav_item.getURL()" $nav_item.gettarget()><span>$nav_item.icon() $htmlUtil.escape($nav_item.getName().substring(3))</span></a>
#end
</li>
#end
#end
</ul>
</nav>
<nav class="sort-pages modify-pages" id="navigation">
<ul>
#foreach ($nav_item in $nav_items)
#if($nav_item.getName().substring(0,2) == "sn")
#if ($nav_item.getName()=="sn-home")
<li class="selected" id="navBackground" style=" padding-top: 1px; height: 32px;">
#elseif ($nav_item.isSelected())
</li><li class="selected" id="nav1Button">
#else
</li><li id="nav1Button">
#end
#if ($nav_item.getName()=="fn-home")
<a href="/web/guest/home" style="color:#fff;padding-left: 42px;width: 68px;"><span style="margin-right: 15px; ">$nav_item.getName().substring(3)</span></a>
#else
<a href="$nav_item.getURL()" $nav_item.gettarget()><span>$nav_item.icon() $htmlUtil.escape($nav_item.getName().substring(3))</span></a>
#end
</li>
#end
#end
</ul>
</nav>
Kim Capa, modificado hace 9 años.
RE: Navigation menu
Junior Member Mensajes: 49 Fecha de incorporación: 31/07/14 Mensajes recientes
Hi Mohd,
Thanks! i'll try that
kim
Thanks! i'll try that
kim