Hi,
1. a.within our primary menu, we have mega menu for each tab, such as "prospective students".
1. b. when visit child level page under "prospective students", such as "what study suits me?", perent level "prospective students" is still hightlighted as red, which is perfect. and this comes from is_active_link function (i guess), which mean according to path structure. as parent level "prospective students" has path like "/prospectivestudents", and each child level page will have path like "/prospectivestudents/xxxxx". so with our primary menu system, everything works perfectly as needed.
2. a. but we have another level mega menu system such as school level, which will have it own mega menu system like below: the wrong parent level tab being hightlighted. "Home" is the school of education homepage which has path like "/education", and page "soe vision statement" is child page under "about us" which has path like "/education/vision-statement". parent level tab didn't get mm-active class applied correctly according to following parent - child, i guess tab gets hightlighted according to path.
so someone help me out with code, i know it should be some logic code like below, but i dont know how to do it: this should for mega menu, not dropdown tab. some code should be added in theme.inc for theme_megamenu_col_content function to apply mm-active class according to parent-child level.
if (child page is active){
parent level tab will apply mm-active class in <li> tag
}
also if only with dropdown menu instead of megamenu, parent level tab gets hightlighted, but also "home" tab will apply mm-active class as well, like below: so how to make "home" tab not apply mm-active class.
also i have question about parent-child level pages within megamenu. if one tab such as "about us" has been enabled as megamenu, is "about us" parent level. and page underneath will child level of "about us", is this correct?
i am really appreciate if someone can help this out.
thanks so much!
Ling
Hi,
Firstly, thanks for your concern in our product.
Please send us your site as well as admin account via [email protected] to check and fix your problem.
Regards,
Hi Cindy,the reason mm-active class doesnt apply to parent tab if mega menu is enabled on this tab, is because $path doesn't return any path of subitems if they are in mega menu.
within is_active_link($path, $current), $path only return values of each tabs and path of subitems if tabs are in drop down. but if tab is enabled as mega menu, and any subitem doenst got path value.
my question is how to return value of path of subitems if parent tab is enabled as mega menu.
looking forward to any suggestion!
appreciate for any help!
Ling