1
I'm testing this module for a site based on xoops 2.5 and I've had some problem using the menu (main menu basic skin) because links were not highlighted when using friendly url or in general htaccess redirect.
This was a limit due to the $menu.selected/$menu.topselected variable which is builded php side and need to be equal to the exact server request.. so if you have yoursite/module/news redirected to yoursite/articles the link won't be highlighted when your are in the page linked by menu
A working solution to me is using smarty to do the trick.. because that way even if the server request is redirected by htaccess you can have highlighted links:
in mymenus\skins\mainmenu\templates\template.html
changed in line 4
<a class="menuMain <{if $menu.topselected}>maincurrent<{/if}>"
to
<a class="menuMain <{if stristr($menu.link,$smarty.server.REQUEST_URI)}>maincurrent<{/if}>"
and in line 11 from
<a class="menuSub <{if $sub.selected}>maincurrent<{/if}>"
to
<a class="menuSub <{if stristr($sub.link,$smarty.server.REQUEST_URI)}>maincurrent<{/if}>"
I know I could use $xoops_requesturi instead of $smarty.server.REQUEST_URI.. but in xoops 2.5 does not print anything to me, even if shown in smarty debug
May be it not 'clean' but that way I'm having current link highlighted always and without issues
probably this method can be used with all skin of the module (and may be in all templates generating menus..)
let me know your opinion
Ian