Create different menus on different pages
-
Hi,
I am trying to create a different main menu on my pages when members log in. (I have sorted the protection of these members pages) – i.e. I would like the main navigation bar to change, so that members logged in see different options.
I found a solution, but the theme I am using doesn’t have the code which was mentioned in the forum post in the header.php file. The post which is helping me is:
https://www.ads-software.com/support/topic/custom-menus-on-different-pages
<?php wp_nav_menu( array( 'container' => 'none', 'container_class' => 'menu-header', 'theme_location' => 'primary', 'menu' => get_post_meta( $post->ID, 'MenuName', true) ) ); ?>
This code works – but won’t replace the actual menu – instead it adds an additional non formatted unordered list. I don’t know where to add it to my themes code.
My site is teachwithtechnology.net and i’m using a wp-forge theme.
If anyone could help me out I would much appreciate it.
ant
- The topic ‘Create different menus on different pages’ is closed to new replies.