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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T16:07:46+00:00 2026-06-13T16:07:46+00:00

Please take a look at this: http://jsfiddle.net/MbrJf/ When I use inspect element, the body

  • 0

Please take a look at this: http://jsfiddle.net/MbrJf/

When I use inspect element, the body starts 100px from the top of the page, even though there is no margin or anything like that in the css. If the <nav> element is removed from the page, everything works ok (even if the margin-top rule is removed from the css, it works ok – but there is still a little gap).

The nav shouldn’t be all the way at the top, but when the margin-top is added, it pushes the h1, address, and rest of the site below it… it is very confusing. I’m trying to accomplish this: https://i.stack.imgur.com/Uu8QN.jpg

Can someone make sense out of this?

HTML:

<div id="wrapper">
  <header>
    <h1><a href="index.html" title="Ozio Sushi">Ozio Sushi</a></h1>
    <address>
    123.456.7890<br>
    123 Fake Street West, Toronto
    </address>
    <nav>
      <ul>
        <li><a href="about.html" title="About">About</a> </li>
        <li> <a href="menu.html" title="Menu">Menu</a></li>
        <li> <a href="gallery.html" title="Gallery">Gallery</a></li>
        <li> <a href="contact.html" title="Contact">Contact</a></li>
      </ul>
    </nav>
  </header>
</div>

CSS:

@charset "UTF-8";
/* CSS Document */


body { 
margin: 0px;
padding: 0px;
background-color: #362f2d;
}
a {
    text-decoration: none;
    color:inherit;
    border: none;
}
#wrapper {
    background-color: #362f2d;
    width: 100%;
    margin: 0px;
    padding: 0px;
    top: 0px;
    left: 0px;
}
header {
    clear: both;
    width: 100%;
    display: block;
}
nav { 
height: 50px;
width: 100%;
background-color: #f7941d;
margin-top: 100px;
}
header h1 {
    font-family: Kaushan script, cursive;
    color: white;
    float:left;
    font-size: 60pt;
    font-weight: 300;
    margin:0px;
}
address {
    font-family: Lato, Arial, sans-serif;
    color: white;
    font-weight:300;
    font-size: 8pt;
    float:left;
    font-style: normal;
}

li {
display: inline;
margin-right: 60px;
font-family: Lato, Arial, sans-serif;
color: white;
font-size: 16pt;
font-weight: 400;
}
#main {
    clear:both;
    margin:0px;
}


​

​

  • 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-13T16:07:47+00:00Added an answer on June 13, 2026 at 4:07 pm

    set the margin-top on the nav and the ul within the nav to 0:

    http://jsfiddle.net/MbrJf/3/

    The margins will push the body down, and the ul has the default margin which must be canceled (you should use a reset or normalize CSS file)

    EDIT

    Then you’d want something like this: http://jsfiddle.net/MbrJf/4/? The underlying issue in that case is that the header isn’t properly containing the logo h1 as it is floated. Applying one of the standard solutions like a clearfix or overflow:hidden will take care of that.

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

Sidebar

Related Questions

could somebody please take a look at this http://jsfiddle.net/bloodygeese/EzkFR/1/ My aim is to on
Hi please take a look at this fiddle http://jsfiddle.net/bloodygeese/pwjNQ/1/ I am trying to figure
can someone take a look at this please http://jsfiddle.net/bloodygeese/ecscY/56/ it looks like I have
Please take a look at this fiddle: http://jsfiddle.net/KA85s/3/ JQ-UI sets first option as default.
Please take a look at this fiddle: http://jsfiddle.net/dhcyA/ Try clicking on a block. What
Please take a look at this simple code: http://jsfiddle.net/kerp3/ The box has an inner
Please take a look at my fiddle: http://jsfiddle.net/wWHz4/ This is what I made so
Please take a look at this example. http://jsfiddle.net/LdeWK/2/ I want to know how to
Well Im stucked at this point.please take a look at this http://jsfiddle.net/karthik64/5jhgF/3/ Okay first
Please take a look at this http://jsfiddle.net/tt13/CFbpt/ What I need is, When user clicks

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.