Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7591031
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T20:33:20+00:00 2026-05-30T20:33:20+00:00

Hi I had to create a horizontal submenu for a website using wordpress. I

  • 0

Hi I had to create a horizontal submenu for a website using wordpress. I played around with the CSS and am almost there I just need to align my links in the submenu to the centre. I tried:

text-align: center;

In the #access ul ul, But that didn’t seem to work :S

The website is: http://dev.timson.me (Submenus on “Upcoming” & “Past Productions”)

And the CSS is:

#access {
clear: both;
display: block;
float: left;
margin: 0 auto 6px;
padding-top: 8px;
width: 100%;
font-family: Stag;
display:block;
text-align:center;
}

#access ul {
    font-size: 13px;
    list-style: none;
    margin: 0 0 0 -0.8125em;
    padding-left: 0;

    display:inline-block;
}
#access li {
    float: left;
    position: relative;
}

#access a {
    color: #eee;
    display: block;
    line-height: 25px;
    margin-top: -4px;
    margin-bottom: -4px;
    padding: 0 1.2125em;
    text-decoration: none;
}

#access ul ul {

    display: none;
    float: left;
    margin-top: 0;
    position: fixed;
    top: 264px;
    left: 50%;
    width: 1000px;
    z-index: 99999;
    margin-left:-500px;
    text-align:center;
    padding-top:5px;
    padding-bottom:10px;

    background: red;
}

#access ul ul a {

    margin-top: 0px;
    margin-right: auto;
    margin-bottom: 0px;
    margin-left: auto;
    padding-bottom:10px;

}

#access ul li:hover > ul {
    display: block;
}

Any help is greatly appreciated cheers.

Peter

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T20:33:21+00:00Added an answer on May 30, 2026 at 8:33 pm

    First, add this rule

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

    Second, change

    #access li {
        float: left;
        position: relative;
    }
    

    to

    #menu-default > li {
        float: left;
        position: relative;
    }
    

    And third, add this rule

    .sub-menu > li {
        display: inline-block;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

OK, here is how to re-create the problem had: Create a new project, using
If I had to create a content inventory for a website that doesn't have
I've had a need to create an encrypted volume on my mac for the
I recently had an idea to create my own String class to make using
i am using eclipse indigo version.i had to create a project in android 2.2
is it possible to create a horizontal flyout menu without using float ? I
I've had to create a custom membership provider for my current ASP .Net project
So I had to create this splash page in a very short amount of
For this assignment I had to create my own string class. I initially wrote
So basically the assignment was we had to create a doubly linked list that's

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.