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

  • Home
  • SEARCH
  • 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 6350807
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T21:52:54+00:00 2026-05-24T21:52:54+00:00

hi I have written css code to display menu bar. faced so many issues

  • 0

hi I have written css code to display menu bar. faced so many issues googled them and found solution too. But this one I couldn’t find.
This is chrome output which has gaps in betweens menu boxes but if firefox theres no issue at all. its contact. how do I solve this?

CSS

#candymenu li {
    list-style-type: none;
    display: inline-block;
    width: 8.1em;
    float: center;
    text-align: center;
    font-family: "Lucida Grande", sans-serif;
    height: 3em;
}
#candymenu ul {
    width: 100%;
    margin:0 153px;

}   


#candymenu li a {
    display: inline-block;
    margin 150px;    
    padding: .5em .5em .5em .5em;
    text-decoration: none;
}

#candymenu li {
    list-style-type: none;
    display: inline-block;

    width: 8.1em;
    float: center;
    text-align: center;
    font-family: "Lucida Grande", sans-serif;
    height: 3em;
    border-right: 1px #818181 solid;
    -webkit-box-shadow: 1px 1px  #bbb;
    box-shadow: 1px 1px  1px #bbb;
}

#candymenu li a {
    display: inline-block;
    padding: .8em .5em .5em .5em;
    text-decoration: none;
    color: #292929;
    text-shadow: 1px 1px 1px #cccccc;
}

#candymenu li {
    background-color: #c9c9c9;
    background-image: -webkit-gradient(linear, left top, left bottom, from(#c9c9c9),    to(#848484), color-stop(0.6, #a1a1a1));
}

#candymenu li:hover {
    background-color: #dc3d73;
    background-image: -webkit-gradient(linear, left top, left bottom, from(#dc3d73), to(#4c4c4c), color-stop(0.6, #474747));
}

#candymenu li:hover a {
    color: #e8e8e8;
    text-shadow: 1px 1px 0px #353535;
}

HTML

<div id="candymenu">    
    <ul>
        <li id="home">
            <a href="">Home</a></li>
        <li id="Gaming">
            <a href="">Gaming</a></li>
        <li id="Reviews">
            <a href="">Reviews</a></li>
        <li id="News">
            <a href="">news</a></li>
        <li id="Interviews">
            <a href="">interviews</a></li>
        <li id="download">
            <a href="">Download</a> </li>
        <li id="support">
            <a href="">Support</a></li>
        <li id="candy">
            <a href="">Candy</a></li>
        <li id="events">
            <a href="">Events</a></li>
    </ul>
</div>

now how do i reduce that gap?

  • 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-24T21:52:55+00:00Added an answer on May 24, 2026 at 9:52 pm

    I think inline-block results in white-space dependent layout, which sucks.

    So you basically need to place all your li-tags back to back, on one single line. Like so:

    <div id="candymenu">    
        <ul>
            <li id="home"><a href="">Home</a></li><li id="Gaming"><a href="">Gaming</a></li>
    

    etc.

    Let me know if it works out!

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

Sidebar

Related Questions

I have written code that automatically creates CSS sprites based on the IMG tags
I have written a code to change the CSS (color font) of tr, but
I have written a CSS sprite auto-generator which takes selected images out of the
I have written some CSS which targets elements using the parent > child selector.
I have written some code in my VB.NET application to send an HTML e-mail
I have below code written in jQuery: var href = window.location.href; if (href.search('/welcome\\/') >
I am having a real headache. I have written a small and simple menu
I have a bunch of CSS written that makes my site target Mobile first,
I have written a bit of code that helps with versioning of js files.
I have written a function which fires when a particular menu item is clicked.

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.