Grow your CSS skills. Land your dream job.

How do you remove Menu Nav last line divide?

  • # February 28, 2010 at 8:34 am

    Hi
    Would someone be kind enough to help

    I have line divides in my nav menu between each button

    remove the last button line divide on the right side by writing a specific rule for the last menu item adding the the class tp the code below

    Quote:
    #menu a.level1 span.bg, #menu span.level1 span.bg {
    background:url("../images/menu_level1_item.png") no-repeat scroll 100% 0 transparent;
    color:#FFFFFF;
    float:left;
    font-size:18px;
    height:47px;
    line-height:47px;
    padding:3px 20px 0 18px;
    text-shadow:0 0 2px #646464;
    }

    Many Thanks for your help and Kind Regards

    Charles

    # February 28, 2010 at 2:21 pm

    Could you not use the :last-child pseudo-class for that?

    # February 28, 2010 at 11:17 pm

    I don’t know what your image looks like so I can’t be sure, but can you use border-right and style it the way you want and then use a class on the last child to remove the border? The :last-child pseudo class doesn’t work in IE7 I think.

    Rob
    # March 1, 2010 at 5:21 am

    Actually I think :last-child works if you use:

    http://code.google.com/p/ie7-js/

    at the top of your IE docs :)

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".