• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

Putting Image icon in Secondary Navigation Menu(Top) in Metro Pro theme

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › Design Tips and Tricks › Putting Image icon in Secondary Navigation Menu(Top) in Metro Pro theme

This topic is: not resolved

Tagged: genesis, Metro Pro, Wordpress

  • This topic has 7 replies, 2 voices, and was last updated 8 years, 11 months ago by WisdmLabs.
Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • October 30, 2014 at 4:22 pm #129941
    solarpow
    Member

    hi,

    I am using Metro pro theme,is there any way I can put Image icon(rss or any other) in Secondary Navigation Menu(Top) in it

    http://www.chaldean-catholic.org/
    October 30, 2014 at 11:46 pm #129964
    WisdmLabs
    Member

    Hi,

    You may add content to the navigation menu using filters.
    Add this to your functions.php

    add_filter( 'wp_nav_menu_items', 'wdm_menu_extras', 10, 2 );
    function wdm_menu_extras( $menu, $args ) {
     
    	if ( 'secondary' !== $args->theme_location )
    		return $menu;
    		
    	$menu .= '<li class="menu-item wdm-image">Text</li>';
    	
     
    	return $menu;
     
    }

    Replace text with an img tag or any other content, it will get appended to the secondary menu


    http://wisdmlabs.com/

    October 31, 2014 at 5:41 am #129985
    solarpow
    Member

    I got this but when I try to move to the left ,whole items move ,I just want image to move

    October 31, 2014 at 6:38 am #129994
    WisdmLabs
    Member

    Hi,

    I Assume you want the li to align with the other menu items. If so, simply remove the class 'right' and add the class 'menu-item' to the li
    <li class="date menu-item">. date_i18n( get_option( 'date_format' ) ) . </li>


    http://wisdmlabs.com/

    October 31, 2014 at 7:27 am #130001
    solarpow
    Member

    Can't we do it via CSS by assigning id to img tag,I am using below

    $menu .= '<li class="menu-item wdm-image"><a href="#"><img src="#" /></a></li>';

    October 31, 2014 at 7:31 am #130003
    WisdmLabs
    Member

    Hi,

    If you need to align it with other menu items, ie to look like its a part of the nav menu you won't need to add css explicitly.
    The .menu-item class will handle it.
    In case you wish to add more css for the image you may assign a id to it.


    http://wisdmlabs.com/

    October 31, 2014 at 7:33 am #130004
    solarpow
    Member

    HI ,

    can you see the site hxxp://www.chaldean-catholic.org/ ,the rss feed icon is to the rightmost ,I want to position it just before "About Us"

    November 3, 2014 at 12:03 am #130246
    WisdmLabs
    Member

    Hi,

    In that case you could try this technique.
    In your dashboard, go to Appearance->Menus
    Select your menu.
    On the left side select links.
    In the 'Link text' field add this <img id="imagerss" src="http://www.chaldean-catholic.org/wp-content/uploads/2014/10/rss2.png">
    You can drag this link before About Us
    Save the menu.


    http://wisdmlabs.com/

  • Author
    Posts
Viewing 8 posts - 1 through 8 (of 8 total)
  • The forum ‘Design Tips and Tricks’ is closed to new topics and replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2023 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble