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)

0
votes
0answers
50 views

Custom menu walker: Repeating a menu item when it has children

I am trying to repeat a menu item when it has children. To better understand, maybe take a look at this example markup: <ul id="main-nav"> <li>Item 1</li> <li ...
0
votes
1answer
27 views

Admin menu post type

Is it possible to get a container post type menu item with all custom post types inside of it?! 1.All post types 1.1 post type 1 1.2 post type 2 1.3 post type 3 1.4 ect....
0
votes
0answers
50 views

Best practice for blank top level menu item?

I create a LOT of WP sites and therefore tons of menus. A lot of times there is no sensible page for a top level menu item. For instance I was creating a site with internal learning. The top level ...
0
votes
1answer
63 views

menu item active class for author.php

I am building a custom theme. For the author.php file that displays an author profile with their posts, I would like my 'About' menu item to turn active (get active class). I have tried: ...
0
votes
2answers
34 views

Extend Individual Menu on Page Function to individual Submenue on Page Function?

It seems that WordPress Development is building a knowledge-base about the best functions out there. Thanks a bunch this helped already a lot! I found a function (find it down here) that offers a ...
1
vote
1answer
43 views

Check what “type” a menu item is

The question I would like to check what type of menu item each item in my menu is i.e. is it a Page, Category, or Custom link. What I want to achieve I want to create a menu made up of categories ...
1
vote
2answers
135 views

Anchor only wp_nav_menu

I am trying to create a list less wp_nav_menu. Below is the desired output: <nav class="nav header-nav"> <a href="#" class="nav-link nav-active">Home</a> <a href="#" ...
0
votes
0answers
27 views

Top level menu items different container than sub menu items

Is there a way to split the menu into two containers. The top level items would be in a separate container than the sub menu items. Here is the default structure <ul> <li> <a ...
0
votes
1answer
26 views

Showing the same menu in multiple location

Today I have faced an weird problem regarding WordPress menus. Here is the register function of my menus - function register_adaptive_menus() { register_nav_menus(array( 'top-menu' => __( 'Top ...
0
votes
2answers
74 views

Hide a Menu Item on Login

I am using the following code to hide a menu item when a customer is not logged and show it when a customer is logged in. .hide-item-not-login{ display: none !important; } .logged-in ...
0
votes
0answers
44 views

There is a code that I don't understand - menu customize with walker

Here is a code I got from internet: (of couse I do not own it) class description_walker extends Walker_Nav_Menu { function start_el(&$output, $item, $depth, $args) { global ...
0
votes
1answer
23 views

Sub Menu content is being duplicated

In the plugin I am developing I am using the following code to build my menu - add_menu_page('BCRM Plugin Settings', 'BCRM', 'administrator', __FILE__, 'bcrm_settings_page', BOOGIE__PLUGIN_URL . ...
0
votes
1answer
29 views

Displaying menu based on login status

I'm trying to show one menu based on whether or not the user is logged in. It's straight forward enough but when I change to my code I have no styles or icons like the original - see code below ...
1
vote
0answers
17 views

using plugin to add menu item to external page [closed]

I have a wordpress plugin that is working well so far. The last step for me is to have it create a menu item on the main navigation menu to an external page when you activate the plugin. Not sure how ...
0
votes
0answers
21 views

Adding Class and div id to wp_list_categories

I am trying to create a dropdown menu for wp header with categories and children as dropdown but cant find a solution, trying to get somethink like this <li class="Main-Cat"> <a href="Link ...
0
votes
0answers
15 views

Auto-build First Instance of Menu from Page Structure

I am wondering if there is a way to build a custom menu that is initially populated by the current page structure. I am working on a site that was initially build pre-custom menus, but now we want to ...
1
vote
1answer
32 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 ...
0
votes
1answer
30 views

Next page link via the custom menu

I would like to display a "next link" at the bottom of several page templates, using the actual custom menu in which they sit in. I built a function that mostly works except for an edge case ...
0
votes
3answers
84 views

Wordpress Login/Logout Single Menu Only

I've written this login/logout for my functions.php in my wordpress theme. The problem is, it's showing a login/logout link in all menus both primary and secondary. Is there a way to get it to ...
0
votes
0answers
21 views

Display the nav menu for a particular page id

Say that I have the id of a page that is in the wp_nav_menu() I would like to show the wp_nav_menu() for that particular page. Is that possible? I can use wp_get_nav_menu_items() to get all items for ...
0
votes
0answers
19 views

How to leverage hefty memory actions from programmatically creating nav menus

I'm working on a plugin right now and hitting a wall. Long story short, part of the plugin process is to construct a dynamic nav menu. This nav menu can get rather large, and I'm finding that it seems ...
0
votes
1answer
71 views

Is there any way to recover deleted menu from database sql backup

i accidently deleted my main menu but i have a .sql database backup file and i want to recover my menu from this file. Is it possible? Thanks.
0
votes
1answer
112 views

Menu is not visible in appearance

I have added following code to my function.php function register_my_menu() { register_nav_menu('header-menu',__( 'Menu' )); } add_action( 'init', 'register_my_menu' ); And here is my code where ...
0
votes
0answers
18 views

current_page_item not being added in menu output

I've created a menu that I call on using following code. <?php wp_nav_menu( array( 'menu' => 'Primary Nav', 'container' => '', 'items_wrap' => ...
0
votes
1answer
37 views

Add menu headings to Wordpress sub menus

I'm using the native Wordpress menu. I have two top-level links with sub menus - I'd like for those sub menus to display the name of the parent menu item. So if I have a parent menu item named ...
0
votes
1answer
30 views

wp_nav_menu not displaying the right way

I'm creating a theme using bootstrap and now I want to display the menu adapting it to bootstrap... so I'm using the Upbootwp_Walker_Nav_Menu to achieve this, and also sending some args to the ...
0
votes
1answer
33 views

Mobile Menu Not Working

The mobile menu stopped working after I updated WP to the latest version, I assume it has to do with a customization of the theme. http://kvintage.com/ Wondering if anyone could please take a quick ...
0
votes
0answers
204 views

Why does has_nav_menu return false when get_registered_nav_menus shows the opposite?

I'm working on a new theme to replace an old one. The existing theme has custom menus and I can't figure out why in my new theme a call to has_nav_menu is always coming back false. In my ...
0
votes
0answers
21 views

Fixed top-level menu

I'm developing a site which has around 10 top-level pages in the menu and each have 4-5 child pages in the sub-menus. I am giving the site users the "Editor" role which I have customised using a ...
-1
votes
1answer
33 views

Customizing Responsive Themes Menu [closed]

I use the popular theme: https://wordpress.org/themes/responsive I would like to change the color of one of the menu items and if possible also have a jquery popup from one of the menu items. How can ...
0
votes
1answer
62 views

Wrap description and sub menu in a wrapper

I am trying to add a wrapper to description and sub-menu in wordpress using walker class, Description will only be shown for the first menu so the structure will look like this EDIT I have been ...
0
votes
1answer
164 views

How to add custom field option with menu?

Please take a look at below image. Here we can see URL, Navigation Label & Title Attribute under Menu Structure >> Home. I need there a more option called "Data Description". I have a task to ...
0
votes
1answer
84 views

Remove all nav menu classes except those which begin with certain letters

I'm currently using a function which strips out all the unwanted classes from my nav menus, leaving only the classes I want to keep (the ones listed in the array inside the function). It looks like ...
0
votes
0answers
43 views

wp_nav_menu use #<slug> instead of permalinks

I need help modifying the wp_nav_menu arguments so that it can generate a menu which has # instead of permalinks.. I know I can add custom link menu items, but I want the menu to be more dynamic .. ...
1
vote
1answer
80 views

How to drag multiple menu items at once in WordPress?

Say, I added 8 items to a menu. Now I want to bring all the 8 items under another item. Dragging them one by one can take ages. How do I drag them all at once?
0
votes
1answer
22 views

Menu Structure with Links failure to update

Sorry if this sounds like a newbie question but this is driving me crazy and I can't seem to figure it out. I want to add a link called "About Me" to my Menu that redirects to another website. It ...
1
vote
1answer
33 views

Change hyphen/dash for vertical line in menu [closed]

I have the theme Blaskan installed. I have a child theme installed also, but I cannot seem to change the hyphens/dashes to vertical lines | in my menu for this theme. Any suggestion would be ...
0
votes
2answers
27 views

How can I make this custom design menu work in wordpress?

I can make wordpress custom menu,but I got a problem with this type of menu. Can anybody give me any suggestion how to make this menu dynamic? screenshot: http://awesomescreenshot.com/0ab3d6an94 ...
1
vote
0answers
32 views

Appearance Menus Screen - menu item drop down menu not functioning

According to WP, there should be options to remove/edit each menu item on a menu under appearance, but this option isn't showing up for me in Chrome or Firefox. I have administrator control of the ...
0
votes
0answers
16 views

Getting Wordpress Permalinks to match menu navigation

I am trying to get my permalinks to match the location of where the page/posts lie in the navigation menu at the top of my page. For example, my travel site has has a post about Torres del Paine ...
1
vote
1answer
44 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 ...
0
votes
1answer
83 views

How to programmatically add elements in a custom menu

In my WP custom menu, one item has a dropdown list below it that lists all instances of some CPT. The only way I know to do that is by creating the list somewhere else in the DOM with PHP and then ...
0
votes
1answer
89 views

Active menu item / category

I was wondering if there's any way to discover which categories are "active" on a category archive page. This is for the purpose of menu highlighting. To demonstrate, compare these: (1) Parent ...
-2
votes
1answer
37 views

wp_nav_menu doesn't add current-menu-item when there is an url parameter [closed]

wp_nav_menu doesn't add the current-menu-item CSS class when there is an url parameter in the url. Is there a way to ignore the url parameter?
0
votes
0answers
19 views

strip_tag not working in header.php

Used code I found on css tricks to remove the li tags from wp_nav_menu. $menu_parameters = array( 'container' => false, 'echo' => false, 'items_wrap' => '%3$s', 'depth' ...
0
votes
0answers
15 views

How to increase menu size limit? [duplicate]

After searching for answers, I am still stumped. I am not very savvy but tried creating a php.ini file, editing .htaccess file, nothing lets me go above the 85 menu item mark. It seems to be a ...
0
votes
0answers
61 views

Superfish Menu is incompatible with the latest jQuery version (1.11.0)

I tried to convert an HTML template into a WordPress theme, and it seems like the Superfish Menu v1.7.4 is not compatible with the WordPress' default jQuery version (which is v1.11.0). I've tried to ...
0
votes
1answer
45 views

2 wordpress site same database

I have twoo websites on worpdress platform: http://fian.ro/ http://nuovafattoria.ro/ On the server there are 2 different folders with same files, same config but one of them has: ...
0
votes
1answer
62 views

Add different span class to wp nav menu

Here is my html for the menu: <div id="main-menu-container"> <ul id="main-menu"> <li><a href="#"><span aria-hidden="true" ...
1
vote
0answers
92 views

How to open modal window when clicking a WP menu link?

I'm making my first site with WP, I'm a Joomla Developper. I'm using wisten theme, and WP 3.9.2 I want to create a link in my the navigation that opens a modal window (not a new page) on click. ...