Tagged Questions

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)

2
votes
1answer
2k views

Show top-level parent with submenu menu walker

I've used the menu walker below to display dynamic submenus with great effect in the past. It displays 2nd- or lower-level menu items IF the current page is a parent, sibling, or descendant of the ...
0
votes
0answers
106 views

Link to Author archive from Navigation Menus in dashboard?

I'd like to display a grid of authors on my site showing the name of the author and their avatar. The tricky part is, I'd like to be able to control this from the Menus page in the dashboard so I have ...
0
votes
1answer
1k views

wp_nav_menu in 3.7 add name class nav navbar-nav

i work with bootstrap3 and wordpress 3.6 but upgrade to 3.7 function wp_nav_menu not work correctly. i use 3.6 <nav class="navbar navbar-inverse"> <?php wp_nav_menu( array( ...
2
votes
2answers
367 views

How to create different navigation for registered users in WooThemes Canvas?

I'm building a website with wordpress and the Canvas Theme (from WooThemes). I'm using the Top navigation for displaying items when a user is logged in. When the user is not logged in, you can see ...
1
vote
0answers
246 views

wordpress register nav menu not showing in admin

I am using the following code to register a menu for my theme. In functions.php I have written the following: register_nav_menu( 'header-menu', __( 'Header Menu' ) ); When going into wp-admin ...
1
vote
2answers
79 views

Create subpages in default Wordpress menu

I've got this code below working to create a default menu. I was wondering how I would create sub-items/subpages... // Check if the menu exists $menu_exists = wp_get_nav_menu_object('Main Menu'); ...
0
votes
1answer
577 views

Overriding wp_nav_menu default arguments

I'm trying to override WordPress' default arguments for the wp_nav_menu function, while still allowing programmers the ability to pass their own arguments. The wp_nav_menu_args filter seems like the ...
0
votes
1answer
56 views

Adding two submenus to a menu

I have a menu(ads) that contains 2 submenus(view and manage). I want that both menu item redirect to different pages, but my 1st submenu(view) is directing to the main menu page.
6
votes
1answer
292 views

Check if add_menu_page exists or not

I'm working on a plugin that I have to release in parts. The problem is, if there is a menu in the page then add the new plugin to the 2nd or next submenu else add a new menu and then add the plugin ...
0
votes
1answer
85 views

Menu link to all posts (all categories included)

In WordPress how can I add a menu link to an archive for Posts? I can see that I can add category archive links but what if I want to have an archive of all the posts (therefore including all ...
1
vote
2answers
85 views

Multiple languages menus problem

I'm trying to add language option to my website. I've coded my theme and I need to show the web in three different languages. I've got the little flags and I've managed to pass a php variable with the ...
0
votes
1answer
131 views

How to create a complete mulilanguage site using xili language plugin?

I am using xili language plugin for create a multi language site. Using this i can create posts and pages on different languages. But when i switch to other language the menus doesn't converted to ...
0
votes
0answers
157 views

How do i keep my current page menu highlighted on pagination?

I have a navigation menu in a page that highlights the current menu you’re on based on the URL by adding a class. My problem is that my page is paginated, so sometimes the user will end up at: ...
2
votes
1answer
1k views

Custom wp_nav_menu output (displaying all child elements of top menu element in current branch)

I would like to create a walker function, or modify somehow current wp_nav_menus so it can produce a custom output. Let's imagine this structure: menu item 1 menu item 2 submenu item a submenu item ...
0
votes
1answer
2k views

Active class to current link

How do I add the active class to the current link that the user is viewing? I have a mixture of pages and custom post types in my main nav menu and I know that wordpress has .current_page_item that ...
0
votes
1answer
33 views

Making pages in a menu appear conditionally

How do I make a page (dis)appear conditionally in a menu? I had something like this in mind: if(condition) //show_page_in_menu I would prefer an answer that doesn't incorporate an external ...
0
votes
2answers
160 views

Set menu item class into body

I set css class for menu items. I want to get css class of current menu item and set it to body tag. What should i do ?
0
votes
0answers
26 views

How to create a menu super voice in WP?

I am pretty new in WP (I came from Joomla) and I am finding some difficulties to do the following operation in WP Main Menu. If you go on this site you can easy understand what I need: ...
0
votes
2answers
334 views

How to use wp_nav_menu with hashtag links?

I am developing a custom theme and the navigation part uses hashtags (yes, all content is on one page). So when i use wp_nav_menu( array( 'theme_location' etc the menu items links to the pages. Can ...
0
votes
1answer
516 views

How do I check if a menu exists?

I'm currently retrieving a nav menu based on the parent page's title, and if the page doesn't have a parent then it's own title. global $post; $page_title; if ($post->post_parent) { ...
0
votes
1answer
151 views

Update nav menu item position programmatically

I've tried adding a new programmatically on wordpress with the function: wp_update_nav_menu_item($menu, 0, array('menu-item-title' => $title, 'menu-item-object' => 'page', ...
0
votes
0answers
15 views

Limit the amount of menus someone can make

Working on a site of mine I was wondering if it would be possible to set/limit the amount of menus someone can make to '1' (and thereby disabling the current menu location features)? I've been ...
0
votes
1answer
730 views

Custom menus created but does not show up in admin panel

I am developing a theme of my own. In functions.php I added - add_action( 'init', 'register_my_menus' ); function register_my_menus() { register_nav_menus( array( 'front_login_menu' ...
-3
votes
1answer
702 views

creating a left-side sidebar in word press [closed]

I would like to know how to create a side bar on the left-side.I have a site containing a sidebar in the right side.I need a sidebar in the left side too. Please help me.
1
vote
1answer
473 views

Menu fallback “menu_class” rendering a “div” instead of a “ul”

I'm working on a fallback menu for a WordPress theme I'm working on. The main menu's menu_class renders a ul which is what I want. However, if I use the menu fallback, the menu_class renders a div ...
0
votes
1answer
357 views

Splitting up a submenu into columns, or putting existing menus in another menu as submenu item

I have a menu with a long list of submenu items. I'd like to split that up into columns and the easiest way in my mind would be to have them split up into multiple . Is there a way to do this? ...
0
votes
2answers
219 views

Why wp_nav_menu() doesnt show the proper meny when invoked two consecutive times?

I just noticed something weird I never saw before. I'm working on a project using WP 3.6.1. This project that has two different menus (actually, three, but that's not important). I'm calling them ...
1
vote
1answer
111 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; ...
0
votes
1answer
19 views

Creating custom menu with custom themes

I have created my own custom WordPress theme and am now trying to implement the custom menu. I noticed with the default theme that when I went to Appearance > Menus, I was able to create my menu ...
0
votes
1answer
1k views

How to add class to anchor using wp_nav_menu

Sorry if my post duplicate but i can't find best solution for my problem. I'm newbie on develop WP theme. Now i'd like to add class to current li and last li, but i don't know how to do? Hope someone ...
0
votes
1answer
62 views

how to change/remove/hide menu under installed plugins

Recently I install one plugin. After installing the "bookingwizz" plugin, the menu added in menu. Under bookingwizz I now have some submenu as well. Now I don't need all those menu items, but want to ...
0
votes
1answer
582 views

Modify the output of wp_nav_menu in a very specific way?

I am trying to get wp_nav_menu to output something like this: <div id="topMenu" class="spanningMenu noPrint"> <ul> <li class="topMenuDivider"></li> ...
0
votes
0answers
26 views

Plugins for putting Custom Post Types into the Menu

I have been building a website that has numerous custom post types, and I have found one called WordPress Post Type Archive Links. This would allow me to add a link to the an archive of registered ...
1
vote
2answers
763 views

Display posts from Custom Post Type in category page on front-end

I created my Custom Post Type (bizdirectory), created a new post (Test Business) and created a new category (Business Directory). But if I add the Business Directory category (slug = business) to my ...
0
votes
0answers
18 views

Inserting another menu from inside an existing menu

I ran into the dreaded php input limit but for some reason my host doesn't respect the php.ini or other settings. My only alternative is adding another custom menu from within a menu. Don't ask why ...
1
vote
0answers
170 views

Wordpress menu performance is slow when lot of items

I have a menu with more than 100 items in total and it is very slow to manage all those, slow respond and slow saving. Is there any plugin to somehow improve performance and make my life easier in a ...
0
votes
0answers
54 views

Change archive link to single post

i do menu with this code but links redirect me too archive.php <ul id="nav"> <?php $all_posts = get_posts(array( 'posts_per_page' => -1 // to show all posts )); // ...
0
votes
1answer
26 views

Navigational error

Basically I have an image for a header and I changed the link behind that to go to the main website and was planning on making a news option in the menu to link to the blogs main page, after changing ...
0
votes
1answer
85 views

Category archive in menu

I am looking for a solution to show the archives for a specific category in my main menu. The first level menu entry would show the label of the category, say "News Digest", without linking to ...
0
votes
2answers
297 views

wp_nav_menu does not take arguments?

I am sorry for this nooby question, but I just don't get it : I was working with the function reference for wp_nav_menu and this is my line of code: <?php wp_nav_menu( array('theme_location' ...
0
votes
3answers
531 views

How to customize navigation menu?

I'm new to Wordpress and I've tried wp_nav_menu function. If i get it right it is a standard way to show you navigation menu created with help of the Menu Manager. What is bothering me is the fact ...
0
votes
0answers
28 views

Strict Standards: Declaration of … should be compatible with [duplicate]

I try this answer, and i changed the function start_el(&$output, $item, $depth = 0, $args = array() ) { but it did not work. The problem is, I have this theme, link here. and I'm getting this ...
1
vote
0answers
138 views

Bootstrap Dropdown Menu unresponsive in mobile [closed]

I have built a responsive website using Bootstrap Theme the menu is working fine in desktop, but if I tap the menu button in mobile devices, more often unresponsive and the transition is delay. Any ...
0
votes
2answers
2k views

How to display the title for each menu item in a span attribute

I'm trying to add a CSS hover effect to my theme's main menu and the effect is based on an attribute passed in a <span> element. The problem is that I am unable to produce this dynamically with ...
0
votes
1answer
226 views

“Widgets” menu doesn't appear

I'm developing a WordPress theme, which works great on my localhost and one of my live servers, but on my other live server the Widgets menu (from Appearance) doesn't appear. And yes, all 3 servers ...
0
votes
2answers
547 views

how to add Custom menu item like User name in Header Menu only

I am new to Wordpress I am setting up wordpress Site which has 3 Menus Top menu Header Menu Footer Menu My issue is I need to add the User name to My Top menu Only when User is Logged in But ...
2
votes
1answer
35 views

WordPress – site with 2 stylesheets and more…

I’m building a site that is broken up into two views (or sections): College and Corporate. » See it here When the College tab is active, the site will use college-styles.css (orange background) ...
0
votes
1answer
139 views

Switching to child theme breaks menu names

When I switch to the child theme I am working on, the main menu uses the page names instead of the names that I gave it in the Appearance > Menu options. Happened to anyone else?
0
votes
1answer
22 views

Right way for setting categories

My site follows this hierarchy HTML5 + Themes Resources Books Tools Wordpress + Plugins Themes Tools Books jQuery + Plugins Tools books and the same combinations for CSS3, SEO and others, ...
0
votes
0answers
263 views

Remove <ul> from wp_nav_menu() wordpress

I am using the theme Twenty Thirteen and am using wp_nav_menu() to display menu items. I need to remove the container <div> and <ul> from wp_nav_menu(). I tried this: wp_nav_menu( array( ...