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 7809287
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T03:23:14+00:00 2026-06-02T03:23:14+00:00

Everytime when I open html, menu position and size is different. Could you help

  • 0

Everytime when I open html, menu position and size is different. Could you help me to fix it? It is supposed to be at the center. Thanks for any help.

div.menu { 
    list-style:none; 
    margin:0; 
    padding:0; 
    width:100%;
    text-align:center;} 
div.menu ul{ 
    font-family: Verdana; 
    font-size:14px; 
    margin:20px; 
    padding:0;
    display:inline-block;} 
div.menu li{ 
    display:inline; } 
div.menu li a{ 
    text-decoration:none; 
    padding:5px 0; 
    width:100px; 
    background:#FBB117; 
    color:#4C4646; 
    float:left; 
    text-align:center; 
    border-left:1px solid #fff; }  
div.menu li a:hover{ 
    background:#a2b3a1; 
    color:#000 } 
  • 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-06-02T03:23:16+00:00Added an answer on June 2, 2026 at 3:23 am

    You can centre an element by using the margin tag. For this work to though, you’ll have to declare the width of div.menu ul otherwise it’ll inherit the width of it’s parent element, div.menu. Therefore:

    div.menu ul{ 
        font-family: Verdana; 
        font-size:14px; 
        margin-left: auto;
        margin-right: auto;
        margin-top: 20px;
        margin-bottom: 20px;
        width: 100px; <!-- SPECIFY WIDTH -->
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Today, everytime I try to open any .Net application I get: CLR error: 80004005
My problem is everytime i open the website; first time the map doesn't show
When I open my SharePoint site collection everytime I am getting the pop up
I am trying to open a Socket on Android but everytime I try I
I'm using Sandcastle Help File Builder to build the documentation for an open source
I have a php form but everytime I open up the php document it
Every time I open a page I want to get the currently active project
Every time I open my Terminal application at work it starts from a clean
I am fed up having to turn them on every time I open the
As per the Emacs docs , every time you open a file, Emacs changes

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.