WordPress.org

Ready to get started?Download WordPress

Forums

Align half of my nav buttons to the right (5 posts)

  1. Eckstein
    Member
    Posted 2 years ago #

    I am using a variation of the twenty eleven theme and there is an image that overlaps the center portion of my navigation bar (this is intentional). I would like to align half of my navigation links to the right of the page and leave the other half to the left.

    Can this be done with CSS or do I need to split the nav-bar into two elements somehow?

    Does anyone know how I can accomplish this?

  2. Pioneer Valley Web Design
    Member
    Posted 2 years ago #

    site link?

  3. Eckstein
    Member
    Posted 2 years ago #

    My site isn't live yet and is in preview mode, but I will make it live for a couple hours here so you can see it.

    link: http://silverlakepictureshow.com/

    There is barely anything there, I'm just beginning to build. I have a temporary solution in place that puts a negative left margin on the 4th nav element, but this seems janky and like too much of a workaround.

    Thanks!

  4. tg1
    Member
    Posted 2 years ago #

    Did you ever figure this out? I can't find any information anywhere - which surprises me for wordpress - about an issue like this.

    I want to do the same exact thing. But it doesn't seem to be easy.

    (I thought it would be more common of a request truthfully)

  5. Eckstein
    Member
    Posted 2 years ago #

    Well, I figured out how to make it look right using a left margin on the nav element after the middle (you can see it in action at the link up there). But if I ever edit the menu or anything I have to re-align the CSS to make it work right again.

    The only way I can think to do this in a "clean" way would be to create two extra widget areas in place of the navbar and then create two custom navbars that can be called using PHP functions to each widget area. Float 1 to the left and 1 to the right and it seems like that may work.

    I haven't tried it yet since my site looks OK right now, but I may experiment and see what happens.

    Not sure how well-versed you are in css/php. If you need help with coding anything, let me know. I may be able to help.

Topic Closed

This topic has been closed to new replies.

About this Topic