-
ViorelParticipant
The recommended solution for a menu was to create a custom one.
I added a new Primary Menu from Menus with 5 items: Home, Contact and 3 items based on categories. For Home, I added a link to my installation folder.
But: Home item and the other four items had different behaviour: Home, when is active the link in the menu is highlighted; the other four items, when a page is active, for example, the contact, the link is not marked as active in Menu.
Therefore: the Home item has a class “current-menu-item” and “current_page_item”. Other items in Menu own a class like “menu-item-type-custom menu-item-object-custom”.
Only the Home item is marked as active, when this page is accessed. Other pages are not marked as active, when it dispayed.I need to have a similar behaviour for al items in the menu.
This might be not a major issue, but when add an icon next to the link, the behaviour is different for display the icon.The icon was added in CSS, like:
#menu-item-50 a {
text-indent: 30px;
width: 60px;
background: url(‘/theme_folder/images/one_icon.png’) 15% 50% no-repeat;
}
#menu-item-50 a:hover {
background: url(‘/theme_folder/images/one_icon_hover.png) 15% 50% no-repeat !important;
}All items fom menu displayed the icon, but Home, when Home page is active.
I was trying to change this:
#access a:hover,
#access li.current_page_item > a {
background: none;
color:#fff;
text-decoration:none;
}#access li.current_page_item > a {
background:none;
}A color is not displayed anymore in Home link, but this not solve the display of the Home icon, when is active, the icon is still hidden.
So, I need that Home not to have anymore a behaviour for active link, when the page is accessed, because the icon is hidden.
You must be logged in to reply to this topic.