I am working on a wp theme for a site which is already built on wp, and having very large menu which is divided into two menu in wp admin.
I want to merge this two menu in theme in single UL. Currently it generates two menu in different div container and ul li, and is breaking the styles & js applied on it.
How can i merge this two menu into single ul li in single container?
Is it possible to combine / merge more then 2 WordPress themes and make change look so it feels like one single website and users can still access all the features and functions seamlessly? Show activity on this post. Yes, It's possible but it will cost you a lot of time and effort.
Click on Duplicate Menu button and you are done. Now you can visit Appearance » Menus, and you can select your duplicate menu from the drop down menus. We hope this article helped you add a duplicate menu in WordPress with just one click.
No single WordPress theme is offering all 3 features in one theme. We thought to buy one theme for listing, one for events and one for articles and somehow make one website.
Flatsome is a multipurpose WordPress theme with over 38,000 sales on ThemeForest. This theme uses a top-bar menu on top of a traditional navigation menu. The demo uses the main navigation menu to link to the site’s most important pages, such as the Shop and Blog pages.
You can combine them with this method. It keeps some of the menu classes generated by WP.
// two WordPress menus combined into one.
// first menu.
$menu = wp_nav_menu( array(
'theme_location'=> 'secondary', // or whatever location
'fallback_cb' => false,
'container' => '',
'items_wrap' => '%3$s',
'echo' => false
) );
// include all of the menu items from the first inside the second menu.
wp_nav_menu( array(
'theme_location' => 'primary', // or whatever location
'items_wrap' => '<ul id="%1$s" class="%2$s">%3$s ' . $menu . '</ul>',
) );
The problem is that each wp_nav_menu is still being wrapped in individual div's. You need to turn off those div's as well, by adding "'container' => false" to each one, like so:
<ul id="MyMenu">
<?php wp_nav_menu( array('menu' => 'FirstMenu', 'items_wrap' => '%3$s', 'container' => false ) ); ?>
<?php wp_nav_menu( array('menu' => 'SecondMenu', 'items_wrap' => '%3$s', 'container' => false ) ); ?>
</ul>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With