Put a wp_nav_menu inside another one

You could perhaps accomplish this via a custom walker, but I suggest you try a single menu containing submenus and display the submenus in other contexts by outputting just that branch of the main menu. see Display a portion/ branch of the menu tree using wp_nav_menu(), specifically this answer.

Creating new dynamic menu including BP links [closed]

Though I don’t have specific code to suggest, it seems like it would be possible to create something along the lines you mentioned by using a custom Nav Walker and generating buddypress-specific links with the $bp global (which you can learn more about here → http://codex.buddypress.org/developer/the-bp-global/). You could alter $output in the custom Nav Walker … Read more

Add section to custom menu panel

I have made a custom menu for the nav menu page to add post type archives just like posts/pages etc. I don’t think it’s possible to make it change the url on siteurl change. You could add the url as /slug/ instead of http://url.com/slug/, but that won’t work with WordPress in a folder. function add_post_types_nav_menu() … Read more

Customize the menu by adding items

To achieve this, you have to extend the Walker_Nav_Menu class. First, create a class that extends the Walker_Nav_Menu /** * Custom nav menu. * Code copy-pasted from /wp-includes/nav-menu-template.php * * @package WordPress * @since 3.0.0 * @uses Walker_Nav_Menu */ class User16975_Custom_Menu_Walker extends Walker_Nav_Menu { /** * @see Walker_Nav_Menu::start_lvl() * @since 3.0.0 * * @param string … Read more

Move admin menu at the end

The global variable $menu can be manipulated. Here, we are moving the Pages menu item to the end: Maybe there’s a simpler method to do the recursive array search, I’ve grabbed an example from PHP Manual. The value to be searched has to be inspected inside the $menu var, enable the debug lines to brute … Read more

Change menu with language?

Solved it with add_meta_box in functions.php. Here is my code: add_action( ‘add_meta_boxes’, ‘my_custom_box’ ); function my_custom_box(){ if ( function_exists(‘add_meta_box’) ) { add_meta_box( ‘page_custom_menu’,’page-menu’, ‘page_custom_menu_box’, ‘page’, ‘side’,’high’); add_meta_box(‘page_custom_menu’,’page-menu’, ‘page_custom_menu_box’, ‘post’, ‘side’, ‘high’); } } function page_custom_menu_box(){ global $post; if ( metadata_exists( ‘post’, $post->ID, ‘page_menu’ ) ) { $menu_id = get_post_meta( $post->ID, ‘page_menu’, true ); } $entries … Read more

Show top-level parent with submenu menu walker

You can try to skip the following if-condition in the start_el() method in your child_menu_walker class: if ($item->menu_item_parent != $parent_item_id ) { //… } which is equal to: if ($item->menu_item_parent != 0 ) { //… } since you have $parent_item_id = 0. So it looks like this condition is filtering out your top-level parent. You … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)