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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T18:23:51+00:00 2026-05-30T18:23:51+00:00

When I was working on a little project I ran into a delema I

  • 0

When I was working on a little project I ran into a delema I can’t for the life of me figure out. Why is it that the div inside #appHead is causing #windowBody to move down? Any Ideas?

<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>Atlas - Valencia College</title>
        <meta charset="utf-8">
        <link rel="stylesheet" href="styles.css" type="text/css">
        <!--<script type="text/javascript" src="scripts.js"></script-->
    </head>
    <body>
        <div id="bgGrad"></div>
        <div id="windowTop">
        </div>
        <div id="windowBody">
            <div id="appEnv">
                <div id="appHead">
                    <div style="margin-top:20px;height:20px;"></div>
                </div>
            </div>
        </div>
        <div id="windowFoot">
        </div>
    </body>
</html>

css

body{
background:url(“lol.png”);
margin:0;
}
#appEnv{
width:100%;
height:100%;
top:0;
bottom:0;
left:0;
right:0;
outline:dotted 1px blue;
}
#appHead{
height:100px;
}
#windowBody{
position:absolute;
top:0;
width:100%;
bottom:0;
}

Even when I removed all of the absolute positioning, it was still the case, however I may have done it wrong.

  • 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-30T18:23:52+00:00Added an answer on May 30, 2026 at 6:23 pm

    Ok, I played with this a bit and here’s what I’ve found:

    First, #windowBody is not being moved down. If you slap a border on it you’ll see that it doesn’t move regardless of other changes. It’s actually #appHead that moves.

    In your code, you have no content in the appHead div, but have instead thrown another div into it that includes a margin-top. Because there’s no content in #appHead it basically gets merged into it’s child div and gains it’s margin-top attribute, moving it down by 20px (you can change the 20px to another number to see the change). Adding even a single word to #appHead (but not inside it’s child div) will totally solve the problem.

    You can play around with it here: http://jsfiddle.net/tsuujin/QcpgC/

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

Sidebar

Related Questions

I was working on a little practice project in AS3 and I ran into
I'm working on a little web project that needs to keeps to a NumViews
I've started working on a little ruby project that will have sample implementations of
I'm working with a little project that I'm planning on using HTML5 in. So
I'm working on a little pet project that organizes people's comic books and stores
Working on a new project I've run into a major roadblock that has brought
I'm currently working on a JavaScript project that's a little larger than what I'm
I'm working on a little project in Flex that's an application to upload images
I am working on a little project and I need to display the author's
Ok I'm working on a little project at the moment, the Report expects an

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.