wp_nav_menu including Skype URL

I believe the esc_url function is what ultimately filters the url you enter in that field. Unfortunately, I don’t see how you could allow the skype protocol without manually editing that function in the core file wp-includes/formatting.php, which is always a bad idea. if ( !is_array($protocols) ) $protocols = array (‘http’, ‘https’, ‘ftp’, ‘ftps’, ‘mailto’, … Read more

Problems Displaying Multiple WP Menus

You need to define the theme location when displaying with wp_nav_menu, i.e.: <?php wp_nav_menu( array( ‘theme_location’ => ‘left-menu’, ‘menu’ => ‘Left Menu’ ) ); ?>

How to add div to top menu item

When using wp_nav_menu you can pass arguments to it which help you style the output, look at: $container Whether to wrap the ul, and what to wrap it with. Allowed tags are div and nav. Use false for no container e.g. container => false . $container_class the class that is applied to the container. $container_id … Read more

how do I add “home” menu item conditionally to custom menus?

So, based on your comment: wp_nav_menu is what I’m using now. But now I have to add ‘home’ menu item depending on certain criteria I’m going to propose a solution that will allow you to add a “Home” menu item to any menu, based on arbitrary conditions, using the wp_nav_menu_items filter (see tutorial here): <?php … Read more

Show menu based on parent & ancestor

Work around. if (is_page( ‘pagename’ ) || in_array(“5”, $post->ancestors)) { wp_nav_menu( array( ‘container_class’ => ‘subnav’, ‘menu’ => ‘visit’ )); } 5 being the ID of the page in question. So while this is a bit more work, needing and if / if:else statement for each page, it will scale to allow as many child / … Read more