Need help? Check out our Support site, then


Center text in custom menu for 2011 theme

  1. Could someone please help me with code for centering text in the navigation menu for 2011 theme?

    The blog I need help with is navnihal.com.

  2. When I click on your username this is what I get:

    isthatwhoiam.wordpress.com is no longer available.
    The authors have deleted this blog.

    We need a link to the site you are talking about please.

  3. Working off the demo site, give this a try.

    .menu-top-navigation-container {
    text-align: center;
    }
    
    ul.menu {
    display: inline-block;
    }
  4. Sorry. The blog is navnihal.com

    I'll give that first suggestion a try.

  5. That first suggestion didn't seem to work.

  6. You have to use both rules I gave above. It works on the demo site and it works on my test site set with 2011.

  7. Well, now that is weird. It isn't working on your site with Firebug. Let me play with it a little.

  8. The code above does work. You have to include ALL of it, and put it at the end of your current CSS customizations.

  9. Gaaaahhhhh!

    I'm sorry, I messed up on the first selector name. Use the following.

    .menu-menu-container {
        text-align: center;
    }
    
    ul.menu {
        display: inline-block;
    }
  10. I'm not sure if you can see all my CSS customizations. So, I posted them below. It still isn't centering for me. Maybe it has to do with the code already in there about deleting the search form? I got that from another forum post.

    #access {
    background:none repeat scroll 0 0 #137C87;
    }

    .page .entry-title {
    color:#7A8D39;
    }

    #page {
    margin-top:0;
    }

    #branding #searchform {
    display:none;
    }

    #branding .only-search + #access div {
    padding-right:0;
    }

    .singular.page .hentry {
    padding:.1em 0 0;
    }

    .menu-menu-container {
    text-align:center;
    }

    ul.menu {
    display:inline-block;
    }

  11. This is so screwy. The "corrected" selector I last mentioned shows up in the twenty eleven demo site, but it is different from what is in YOUR site. I guess I can no longer use the wordpress theme demos to figure out CSS for people when I can't see their site.

    Change the first bit back to this.

    .menu-navigation-menu-container {
    text-align: center;
    }
  12. Victory is ours! Thank you for all your help. I greatly appreciate people with your skills and patience.

  13. Thread moved to CSS forum section

  14. You are welcome, thanks and sorry for the runaround. I didn't realize there was a difference in the CSS between what we are all using and the demo site.

Topic Closed

This topic has been closed to new replies.

About this Topic