Articles of menus

Minor css-change based on topmenu – how?

I want to make minor css-changes based on the choice of the top (root) menu. What’s the proper way to handle this in WP? //edit// It’s a website (pages), no blog, and basically, the colors of some links and some images should depend of the choosen top-menu-item. Example, page-structure: * Start * Products * Prod.categ. […]

Adding Additional Menus In Genesis Child Themes

I have a Genesis child theme that I bought, and it only supports two menus, a primary and a secondary. However, for what I would like to do with my site I need to have 6 menus all together. This is my website http://thenottypicalarmywife.com This is what I want the menus to look like http://livingwellspendingless.com […]

Menu styling for last menu item

okay so I’m using the following code to get my links… <?php wp_nav_menu( array(‘theme_location’ => ‘primary’, ‘container’ => ”, ‘menu_class’ => ‘mainnav’) ); ?> This is my CSS for the nav… .mainnav a { font-family: gooddog_plainregular, Arial, sans-serif; font-size: 30px; color: #ffea00; text-decoration:none; } .mainnav li:after { content: url(‘images/nav-divider.png’); } .mainnav li.last:after { content: none; […]

How to change the admin menu “Pages” to something else

When one creates a custom post type you have the ability to define various elements related to that post type which essentially allow you to define things such as the menu title, “add new post” text and stuff like that. What I am trying to figure out is what code I need to add to […]

How to remove div container in custom menu?

all As per my html theme structure i do not want to add my menu <ul><li> under <div>. I am using <?php wp_nav_menu( array( ‘menu_class’ => ‘tlm’, ‘theme_location’ => ‘primary-menu’ ) ); ?> By default this wrap my menu with div. like <div class=”menu-first-container”><ul class=”tlm” id=”menu-first”><li class=”menu-item menu-item-type-post_type menu-item-object-page menu-item-23″ id=”menu-item-23″><a href=”http://localhost/tmw_new/”>Dashboard</a></li> <li class=”hasul menu-item […]

current-menu-item class for custom post type parent

Im having a problem with my menu and custom post type. I have a custom post type of “services”. I have created new page for it called Services. On that page Im displaying a list of all the post from that custom post type. The current-menu-item class is working as itended. But the problem is […]

Remove the whole menu in the admin

How can i remove the whole menu in the admin? I have this code: function remove_menu_items() { global $menu; end( $menu ); while ( prev($menu) ) { $value = explode( ‘ ‘, $menu[ key($menu) ][0] ); if ( $value[0] != NULL ? $value[0] : “” ) { unset( $menu[ key($menu) ] ); } } } […]

How to add ul class on nav

I’ve been learning to convert HTML to WordPress and want to convert on to class like this: <div class=”mainmenu pull-left”> <ul class=”nav navbar-nav collapse navbar-collapse”> <li><a href=”index.html” class=”active”>Home</a></li> <li class=”dropdown”><a href=”#”>Shop<i class=”fa fa-angle-down”></i></a> <ul role=”menu” class=”sub-menu”> <li><a href=”shop.html”>Products</a></li> <li><a href=”product-details.html”>Product Details</a></li> <li><a href=”checkout.html”>Checkout</a></li> <li><a href=”cart.html”>Cart</a></li> <li><a href=”login.html”>Login</a></li> </ul> </li> <li class=”dropdown”><a href=”#”>Blog<i class=”fa fa-angle-down”></i></a> <ul […]

get menu id using its name

I have a menu name Social Network. I want to get the menus ID. I tried the following, but didn’t succeed. global $wpdb; $menu_slug = ‘social-network’; $menu_id = $wpdb->get_results( ” SELECT TERM_ID FROM $wpdb->wp_terms WHERE name = “.$menu_slug.” ” ); echo $menu_id;

How to modify navigation menu of the “My Account” page in WooCommerce

I want to modify the WooCommerce “My Account” left side navigation menu. For that, I have made changes in the woocommerce/templates/myaccount/navigation.php. The problems with this approach are: I can add the new items only at the first or last position in the menu. I’d need them at the 2nd and 3rd position instead…. If WC […]