ThemeShaper Forums » Thematic

Adding ID selectors to menu items?

(3 posts)
  • Started 10 years ago by aftershock
  • Latest reply from budgrif
  • This topic is resolved

Tags:

  1. aftershock
    Member

    Disclaimer: I'm kind of new to customizing Wordpress themes (but not to HTML/CSS), so bear with me, please!

    What I'm looking to do, is customize my menu with a different colored background or image for each menu item (so, for example, the "Illustration" button would be blue; "Photography", purple ... and so on.)

    I've tried changing the background color through the class selectors, but to no avail.
    For example, I tried to change my "About" link background color by using the following code:

    #menu li.page_item-2 a { background:  #333; }

    But that didn't work. It seems like the solution would be to add "id=___" to each list item, so I could style them individually, but I'm not sure how to go about this.

    Thanks for anyone who can offer help, it's much appreciated!

    Posted 10 years ago #
  2. aftershock
    Member

    Ahh, nevermind.
    I found this topic and it resolved my problem!

    Posted 10 years ago #
  3. budgrif
    Member

    I did this in my child theme's style.css and it worked great.

    .sf-menu li.page-item-170 {
    	background:#2163D7;
    }
    .sf-menu li.page-item-178 {
    	background:#2163D7;
    }
    Posted 10 years ago #

RSS feed for this topic

Reply

You must log in to post.