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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T11:07:18+00:00 2026-06-17T11:07:18+00:00

For my website that I am making, I have this code: .menu{ } .menu

  • 0

For my website that I am making, I have this code:

.menu{      
}

.menu a{
    text-shadow: 0 2px 2px rgba(0, 0, 0, 0.3);
    color: #d7d7d7;
    font: bold 16px Arial,Helvetica,Sans-serif;
    text-decoration: none;
    border-radius: 10px;
    background-color: #444;
    padding: 5px 10px;
    text-align: center;
    -webkit-transition: all 0.3s ease 0s;
    -moz-transition: all 0.3s ease 0s;
    -o-transition: all 0.3s ease 0s;
    transition: all 0.3s ease 0s;
}

.menu a:hover{
    border: double 6px #00F;
    color: #00F;
    background-color: #FFF;
    font: bold 20px Arial,Helvetica,Sans-serif;
    text-decoration: underline;
    text-align: center;
}

.sidebar{
    width:220px;
    margin-top:8px;
    margin-left:3px;
    background-color:#CCC;
    border-radius:10px;
    padding:10px;
    clear:left;
    -moz-box-shadow: inset 0 0 5px 5px #888;
    -webkit-box-shadow: inset 0 0 5px 5px #888;
    box-shadow: inset 0 0 5px 5px #888;
}

.sidebar p{
    text-align: center;
}

HTML code:

<div class="sidebar">
    <b style="color:#666;">Menu</b>
    <div class="menu">
        <p><a href="#">Profile</a></p>
        <p><a href="#">Friends</a></p>
        <p><a href="#">Community Service</a></p>
        <p><a href="#">Messages</a></p>
    </div>
</div>

For some reason the only way I can position the anchors on top of each other like this is by putting them in paragraph tags, but I don’t want that. Here is a picture of how all that code looks:

Code Overview

I want the menu to look like the Log In and Create an Account button, but there is no difference between the CSS, the only thing that could be differentiated between them is that the div containing them is positioned in a table. So I was wondering how I could achieve that same-width-and-height-as-the-ones-above-and-bellow-it kind of div. Also I tried putting it into a table and that only squashed it together and took out the round edges (CSS display: table in the .menu and display: table-cell in the anchor also does not work because it squashes it). Here is the rest of my code: http://pastebin.com/ZLS94ZvQ thanks for your help!

  • 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-17T11:07:19+00:00Added an answer on June 17, 2026 at 11:07 am

    You should change your HTML in:

    <div class="sidebar">
      <b style="color:#666;">Menu</b>
      <ul class="menu">
        <li><a href="#">Profile</a></li>
        <li><a href="#">Friends</a></li>
        <li><a href="#">Community Service</a></li>
        <li><a href="#">Messages</a></li>
      </ul>
    </div>
    

    and your CSS in:

    .menu{      
      list-style:none; /* remove style from <ul> but leave a 40px margin on the left */
      margin-left:-40px; /* this remove the 40px margin on the left */
    }
    .menu li{
      text-align: center;
      margin: 10px 0; /* this adds 10px top and bottom of each <LI> element */
    }
    .menu a{
        display: block;
        text-shadow: 0 2px 2px rgba(0, 0, 0, 0.3);
        color:  #d7d7d7; 
        font: bold 16px Arial,Helvetica,Sans-serif;
        text-decoration: none;
        border-radius: 10px;
        background-color: #444;
        padding: 5px 10px;
        -webkit-transition: all 0.3s ease 0s;
        -moz-transition: all 0.3s ease 0s;
        -o-transition: all 0.3s ease 0s;
        transition: all 0.3s ease 0s;
    }
    
    .menu a:hover{
        border: double 6px #00F;
        color: #00F;
        background-color:  #FFF; 
        font: bold 20px Arial,Helvetica,Sans-serif;
        text-decoration: underline;
        text-align: center;
    }
    
    .sidebar{
        width:220px;
        margin-top:8px;
        margin-left:3px;
        background-color:#CCC;
        border-radius:10px;
        padding:10px;
        clear:left;
        -moz-box-shadow: inset 0 0 5px 5px #888;
        -webkit-box-shadow: inset 0 0 5px 5px #888;
        box-shadow: inset 0 0 5px 5px #888;
    }
    

    Using <ul> is better and semantically correct. For search engines it should be even better to wrap the <ul> with <nav>

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm making website that have notification 'button'. When user click this button, notification div
I was making navigation menu for my website that works like this: there is
I have a website that I'm making that needs a background resizer. Currently, I
I have a website that uses the AjaxControlToolkit. I'm making some parallel iPhone-friendly pages
i'm making a music website. i have this button image for adding a song
This is the problem I have: I am making a CSS editor for website
I have a page on my website that I am making a call to
Here i have some code from my website I'm making. I'm having trouble styling
I have an Asp.net MVC website and for that I will making a lighter
I'm making a website that tend to handle all the request in one page

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.