www.webdeveloper.com
Results 1 to 8 of 8

Thread: Change bg color of drop menu

Hybrid View

  1. #1
    Join Date
    Mar 2009
    Posts
    71

    Arrow Change bg color of drop menu

    Hello,
    Please reference this page: http://www.flagsexpress.com/delete_me.html

    This drop menu is a library item that will be on multiple pages of our website.
    The only issue I have is that I'd like to change the font and bg color of the list item that says "Buyer Comparison Chart"
    but I'd like the others to stay gray. Do you know how I'd go about doing that?
    Any help would be greatly appreciated.

    Also, the menu cuts off some of the words I've got on the drop down. Any solutions to that?

    Thank you for your time.

  2. #2
    Join Date
    Sep 2008
    Location
    Akron, OH
    Posts
    1,125
    Code:
    #navMenu ul li ul li:first-child {background: #f00;}
    I'm always up for networking with fellow web professionals. Connect with me on LinkedIn if you like!

  3. #3
    Join Date
    Mar 2009
    Posts
    71

    Arrow

    Thank you so much! I also need to change the color of the menu item that says "ECONOMY FLAG". But again I'm stumped!

  4. #4
    Join Date
    Sep 2008
    Location
    Akron, OH
    Posts
    1,125
    Code:
    #navMenu ul li ul li:nth-child(6) {background: #0f0;}
    I'm always up for networking with fellow web professionals. Connect with me on LinkedIn if you like!

  5. #5
    Join Date
    Mar 2009
    Posts
    71

    Arrow

    Thank you again! How do you know this stuff?? I tried to look it up on the internet after you gave me the first bit of code figuring that I'd be able to find how to highlight areas besides the first-child but to no avail

  6. #6
    Join Date
    Mar 2009
    Posts
    71
    I am really having issues now. I need the font color to be white on the red parts, and I am also trying to keep the red from changing when hovered over, I need it to stay red, but the other ones that are live links are perfect. I'm also trying to get a thin black border around the initial box labeled "U.S. Outdoor Flags"
    It seems that every time I adjust one thing, the next step is impossible because current code overrides what I need to do.
    I have updated the link: http://www.flagsexpress.com/delete_me.html

  7. #7
    Join Date
    Sep 2008
    Location
    Akron, OH
    Posts
    1,125
    It looks like your color is defined on the anchor and not the li. Try this:

    Code:
    #navMenu ul li:hover ul li:nth-child(2) a {color: #fff;}
    To get the thin black border, try this:

    Code:
    #navMenu > ul > li {border: solid 1px #000;}
    I know this stuff because practice makes perfect
    I'm always up for networking with fellow web professionals. Connect with me on LinkedIn if you like!

  8. #8
    Join Date
    Mar 2009
    Posts
    71

    Arrow

    Ok that worked. The last two things I need to do is make it so the red parts don't change color when rolled over and also I need to put more text in some of the menu items but it gets cut off instead of wrapping. Then I'm done and you are hired and I'm fired.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles