0

I've developed a plugin that adds a menu item to a navigation menu using the wp_nav_menu_items filter.

It works well, but unfortunately i'm having some problems with Elementor which seems to not use the 'display location' on menu admin page to assign a menu to a website section e.g. Header or Footer, but uses directly the menu names instead (hope it does make sense).

To make things easier, I create a new menu called "Main Menu" which I assign for example to "Header Navigation".

My custom menu item using the wp_nav_menu_items filter is then added to "Header Navigation" but I would like it's added to "Main Menu".

Is it possible?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.