Navigation Menu is a theme feature introduced with Version 3.0. WordPress includes an easy to use mechanism for introducing customised navigation menus into a theme. In order to incorporate menu support into your theme, you need to add a few code segments to your theme files.

learn more… | top users | synonyms (4)

1
vote
2answers
3k views

wordpress custom walker for thumbnails with custom menu

I'm still very novice at PHP so any help is greatly appreciated. Typically I have found the codex to be very helpful but it appears custom walkers may be outside its scope. I'd like to have ...
1
vote
2answers
471 views

Directing a page to a default subpage

I would like to introduce page-hierarchy navigation in my WordPress blog using subpages. So each page may have sub-pages, but I'd like that when a visitor clicks on a page header he will be redirected ...
1
vote
2answers
1k views

Custom CSS class or ID on menu items that have a Submenu

If I want to apply a style to only an item in a menu that has a submenu, how can I select that with CSS?
1
vote
1answer
213 views

Can I add pages to my custom menu via script?

My theme has a custom menu assignment... function my_register_my_menus() { register_nav_menus( array('header-menu' => __( 'Custom Header Menu' ) ) ); } ...and I'm creating an "installer" ...
1
vote
1answer
680 views

wp_nav_menu google analytics event tracking

I've got a WP3 custom menu, with a custom link in the menu, How can I add google analytics event tracking to that custom link. Thanks Alex
1
vote
1answer
2k views

Find out if a page has no parent

Hay, have a basic menu looking like this Item 1 Item 1.1 Item 1.1.1 Item 1.1.2 Item 1.2 Item 2 Item 2.1 I'm outputting this as a list using WordPresses "wp_list_pages()" ...
1
vote
2answers
2k views

Manage custom menu for an Editor?

I've a problem with permission. Is there a specific permission to let an user with Editor Role, manage the custom menu of a theme, and only this options? The item that is under Appereance -> Menu, to ...
1
vote
3answers
316 views

How to remove some specfic navigation links only from selected page/pages?

For example: In the client site I have 5 page 1) Home 2) product 3) Services 4) Contact us 5) Blog Only from the blog page I want to remove 2) product and 3) Services but not from other pages. Is ...
1
vote
1answer
253 views

add JS to multiple plugin admin pages

For a WP Theme with multiple admin screen (got its own main menu and some submenus), I want to add a common Js script to load on (only) all these pages. I know how to acheive this using the pagehooks ...
1
vote
2answers
2k views

Set menu active state for custom posttype and category, given custom taxonomy term

How to set the menu active state for a custom posttype and category, given a custom taxonomy term? I have a custom taxonomy: region, a custom posttype: business, and use the categories taxonomy. My ...
1
vote
1answer
2k views

Image as a link using wp_nav_menu()

In creating a custom navigation menu in TwentyTen ( WP3.01), is it possible to make an image a link to a page on the same site, using wp_nav_menu() ? Is it the case that wp_nav_menu() echos or returns ...
1
vote
1answer
172 views

Menu API not switching menus?

I am using the menus API, and I want to switch to a different menu, but it is holding the first one for some reason Here is my code in functions.php add_action( 'init', 'register_my_menus',10 ...
1
vote
4answers
4k views

How do I get my wp_nav_menu single category page to highlight the parent?

With the new wp_nav_menu system, it is possible to add a category as a menu item, so in my example I have a 'news' category, which is a submenu item of 'About'. About (page) --news (category) ...
1
vote
2answers
422 views

How to generate a list of child pages, and use some of their custom fields?

I have a page structure like this: -Home -Cars -Volvo 640 - Pics - Info -Porsche 911 - Pics - Info I'd like to generate a list of cars on the Cars page of all the cars (which are ...
1
vote
1answer
17 views

How to change menu URLs to hashes?

I'm building a fullpage Wordpress site. Meaning the pages are not separate URLs, they are accessed through the same URL. Something like deuxhuithuit.com. So I have a menu that the admin creates by ...
1
vote
1answer
31 views

How to add custom classes to more than one separate menu's a link in wordpress?

Here is a link to my website: website I have placed the following code to this document in /wp-includes/nav-menu-template.php Towards the end of the code are several lines that start with ...
1
vote
1answer
20 views

Custom Menu url is Empty

I added a new menu using this code: wp_update_nav_menu_item($menu->term_id, 0, array( 'menu-item-title' => 'Custom menu', 'menu-item-url' => 'http://mylink.com', ...
1
vote
1answer
122 views

how to put the logo in the center of other items in the navigation bar

I'm developing a website in wordpress and I have to create a navigation bar in which the logo of the website has to be put between items like this: item1 item2 LOGO item3 item4 I'm thinking to use ...
1
vote
1answer
45 views

wp_nav_menu add some element to container

I've tried to hook wp_nav_menu_args to get an ID for the nav menu. I tried to add an element using javascript to container menu. But I never get the ID for the menu. How can I add an element to a nav ...
1
vote
3answers
200 views

multisite: global menu containing network site links?

Can I create one single menu that appears on every page within the network and contains every site and page that exists within the network? I'm talking about the following structure: Main Site ...
1
vote
1answer
36 views

Make parent page only link to first subpage

I'd like to automatically make any parent page link to it's first subpage if it has one. Like so: Parent 1 (/#subpage-1) Subpage 1 (/#subpage-1) Subpage 2 (/#subpage-2) Subpage 3 (/#subpage-3) ...
1
vote
1answer
116 views

Debugging - trying to add search box to menus

I have already asked a similar question at stackoverflow (http://stackoverflow.com/questions/22492292/add-filter-in-wordpress-how-do-i-know-if-it-is-run), but maybe that was the wrong place? As you ...
1
vote
1answer
134 views

Add class active to static menu

I have a static main menu, but I'd like to add the class 'active' to the menu item in the nav if it is the page, or a child of that page. I imagine it to be a series of something like: if ( ...
1
vote
1answer
53 views

Remove all nav menu classes ( but keep useful ones… )

I'm trying to remove all menu-item classes (except for .current-menu-{item/parent/ancestor} and .menu-item-has-children) function custom_nav_menu_css_class($classes) { $classes = ...
1
vote
2answers
3k views

How to add active class on current menu item page?

I have two links: Products and News. When i click on Products or News, it returns me an archive page that contains some posts, when i click on a post it returns me a single page of this post. In the ...
1
vote
1answer
397 views

Customizing the a tag with Semantic UI

I'd like to use Semantic UI to aid development of a Wordpress template for a project. For a submenu I intend to use one of the Secondary sub menus found just at the bottom of the Pointing section. ...
1
vote
1answer
233 views

How to show only one category in breadcrumb navigation

I added breadcrumb navigation to WordPress & I'm facing one problem. Here's the function.php code of the breadcrumb: function ux_breadcrumbs() { if (!is_home()) { echo '<a href="'; ...
1
vote
1answer
81 views

Use menu class in walker function

Is there anyway, using the custom menu css classes that are turned on in the option, to apply those via a walker function to the span instead of the li's? My custom walker: class ik_walker extends ...
1
vote
1answer
270 views

Custom walker nav - Add sequential number as class

I'm getting to grips with the walker at the moment, but i need some assistance in getting my desired effect. My walker function looks like: class ik_walker extends Walker_Nav_Menu{ //start of ...
1
vote
1answer
162 views

Can't include Language switch in Nav Menu

I am trying to add to my menu bar some language elements. I'm using the qTranslate plugin and I would like to add the language switch to the menu bar. My them is calling in the header.php <?php ...
1
vote
1answer
1k views

WordPress Settings API, Implementing Tabs On Custom Menu Page

I've been following the WordPress Settings API tutorial series of this guy: http://wp.tutsplus.com/tutorials/theme-development/the-complete-guide-to-the-wordpress-settings-api-part-1/ So far, I've ...
1
vote
1answer
80 views

Setting a Default 'Theme Location' When Creating a Menu

I'm trying to create a theme which when activated, sets up a primary navigation, adds the homepage to it and then enables it in the correct location. Here's what I've got so far: ...
1
vote
1answer
92 views

Home Custom Menu Link not Working

I'm trying to have the menu link per default when using my custom menus, and in my functions.php document I have this: function home_page_menu_args( $args ) { $args['show_home'] = true; ...
1
vote
1answer
239 views

How to make this menu drop down or like accordion

I am using sitesmile auction theme. Here is my working site. In home page there is a sidebar saying "Browse by Categories". I want to make this menu as drop down or like accordion. Whenever the user ...
1
vote
1answer
491 views

How to add fixed position in menu class for Twenty Twelve theme?

I have already looked at many jquery examples on how to make the menu sticky. I have applied these tutorials on clean html pages and they have worked perfectly. However, when I try to apply it on the ...
1
vote
2answers
38 views

Menu Limitations

I am coming here for advice mainly, because I am stuck on what to do next. Within my latest project, I am using Wordpress at the backbone, as a fully fledged CMS system. I have styled every single ...
1
vote
1answer
3k views

adding some custom html code to the wp_nav_menu function

I would like to implement some custom html code to the wp_nav_menu function in WordPress so that I can add a bootstrap modal box to a navigation menu link but I am unsure how to go about it. The post ...
1
vote
1answer
822 views

How to put a Menu on the left side of a particular page in Wordpress 3.5

I am creating a website. The website already has a main menu which appears on the top. But in one of the pages I want a side menu to appear on the left side of that page. I have gone through many ...
1
vote
1answer
1k views

Renaming a WordPress Admin Menu

I am trying to change the Admin Menu name for "WooCommerce" to "Store Settings". I tried the other code rename posts to articles, etc. but it did not work for WooCommerce. WooCommerce's Admin Menu ...
1
vote
1answer
140 views

Hide pages depending on role

I've been trying to find a way to limit the user from seeing some pages in the "pages" menu in the admin panel. I looked in the edit.php file and noticed: } elseif ( 'page' == $post_type ) { ...
1
vote
1answer
172 views

Add CSS to head depending on nav menu walker

I have a custom walker for a navigation menu on my website, and within it I have some custom CSS that I want to apply to each menu, however, I cannot simply echo it there because even though it works ...
1
vote
1answer
306 views

Custom dashboard menu does not stay open for the custom Taxonomy within it

Short Version: Custom menu with a custom post type that supports a custom taxonomy. The custom post type works, the menu for it works and stays open. The custom taxonomy works, but the sidebar menu ...
1
vote
1answer
105 views

SlideDeck 2, make back-end visible for admins only

I'd like to make the back-end of the SlideDeck 2 plugin visible for admin users only. Also, I'd like to remove that "Insert SlideDeck" button from the editor. How can I do this?
1
vote
1answer
37 views

Possible Menu Hack?

This is the craziest WP issues I've ever had...so my homepage main navigation reads like so...."home" "official artwork" "my artwork" "about" "links" "contact" but when I click on any other page my ...
1
vote
1answer
1k views

How do I hide one menu item link for logged in and logged out users [closed]

Using bbPress and s2Member, I need to hide the registration link in the menu for logged in users and the members directory link for non logged in users.
1
vote
1answer
589 views

Primary navigation menu & footer not showing in category / tag page

I tried to find a solution for primary navigation not showing in some pages, ie. archive.php. I found one from here but it's still giving me notices. I'm using Reverie Theme in WordPress ...
1
vote
1answer
78 views

do_action appearing outside of menu?

I'm using Bill Erickson's "Add Extra Code to Any Menu" function: <?php /** * Add Extra Code to Any Menu * @author Bill Erickson * @link http://www.billerickson.net/customizing-wordpress-menus/ ...
1
vote
1answer
1k views

How to change theme header to support multiple nav menus?

I'll try to be brief.... I have a theme that only supports one navigation menu. At this point I'd like to add 2 or 3 more menus. I have successfully registered my menus in functions.php with ...
1
vote
2answers
1k views

How can I Add a variable PHP in the Menu Nav

I want to add a variable in the Menu, for passing a value in all my page. The purpose is to retrieve a value for transport to another web site (from my website links) to the tracking, this value ...
1
vote
1answer
67 views

two menus show different menu based on what menuitem is selected on menu1

Iv got two menus: menu1 with three menuitems. menu2 which is based on which menuitem I selected in menu1 Like this: menu1 menu2 menu3 Home Tax Company Aboutus menu1 menu2 menu3 Home Posts News et ...