Not work with Mega Menu
-
Hi. I love this plugin, I’ve used it mostly with links on pages and it works wonderfully. I’m trying to use it with Max Mega Menu plugin and I’m placing “m_PageScroll2id” in the Link Relationship (XFN) on the menu item but its not working. It works great though when I use it on a link within the page.
-
Hi,
I think you need to enable “Scroll to location hash” option in plugin settings and probably also check “Enable for all targets” below it. This option enables scrolling to location hash (
#) on page load. For detailed info on these options see “Plugin settings” in contextual help menu at the top of the page.That was it!!! Thanks!
You’re welcome 🙂
Marking this as resolved.
Hello Malihu! I am still trying to fix my menu problem on http://candyqueen.org
I swapped the theme menu with max mega menu, and now there is no errors. But scrolling doesn’t work as it should. I found this topic, and I wonder should I add something in xfn links? The folowing settings in the plugin are enabled:Enable on WordPress Menu links (Automatically enable the plugin on custom links (containing # in their URL))
Scroll from/to different pages (i.e. scroll to target when page loads)Scrolling works when you go from ‘ask me’ to the rest on the menu items. but if you switch between first three, it only jumps without scrolling.
Hello,
It seems that mega menu prevents “Enable on WordPress Menu links” from working (not sure if mega menu is indeed a WordPress menu or a completely different custom menu).The quickest way to enable the plugin on the mega menu links is to go to “Page scroll to id” settings and change the “Selector(s)” field value to:
a[rel='m_PageScroll2id'], a.mega-menu-link[href*=#]:not([href=#])Save changes and test 😉
Another way would be to add the value
m_PageScroll2idon the XFN field on each of your mega menu items or theps2idvalue in the class field (if those fields exist in mega menu builder page).Great! Selectors work.
Max mega Menu is a plugin which takes existing menu and makes it more manageable.
Thank you so much, Malihu!@savinichsasha Great 🙂
It seems then that since mega menu overwrites WordPress menu walker function, the “Enable on WordPress Menu links” option cannot work. The other 2 ways (XFN and class field values) should normally work (unless mega menu does not include these attributes in its output).
The “Selector(s)” value will of course always work (as it’s applied on the client-side).
Thanks a lot for your review 🙂
You are welcome 🙂
The topic ‘Not work with Mega Menu’ is closed to new replies.