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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T18:53:00+00:00 2026-05-11T18:53:00+00:00

I have a page where while the page loads, I put an absolute DIV

  • 0

I have a page where while the page loads, I put an absolute DIV over all of my content with “height:100%” that states “the page is loading…”.

However, it appears from the scrollbar that the height of the page is 100% + the height of the content.

This immediately goes away once the page loads and the overlay absolute positioned DIV is set to display:none.

This happens in Firefox 3, Chrome, IE6.

Any ideas on how to make height:100%, just 100% and not more?

<html>
  <head>
     <style type="text/css">
         * html, * body {height: 100%; margin: 0; padding: 0}
            #message {background: black; height: 100%; left: 0; opacity: 0.15; position: absolute; top: 0%; width: 100%}
            #loading {height: 100%; left: 0; position: absolute; top: 45%; width: 100%; z-index: 2}
            #loading p {background: white; border: 2px solid #666; width: 180px}
     </style>
  </head>
  <body>
     <div id="grayout"></div>
     <div id="loading"><p>Page is loading...</p></div>
     <div id="content">
     // content is dynamically loaded into this div via AJAX
     </div>
  </body>
</html>

Update: it appears the problem is that I have “top:45%”. How do move that DIV to the center of the page (since it’s a “page is loading message”) without causing this same problem all over again?

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

    If that element has vertical padding or margin, it’s added to the height of the block according to the CSS specification (see the visual formatting model for absolutely positioned, non-replaced elements).


    Edit   The top:45% is moving your element 45% down. Remove it (top:0) or set the element’s height to auto (default value).

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

Sidebar

Ask A Question

Stats

  • Questions 121k
  • Answers 121k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer I have this problem a lot with Eclipse and Scala.… May 12, 2026 at 12:34 am
  • Editorial Team
    Editorial Team added an answer Expanding on @kanad's response... Your 13MB of dlls will only… May 12, 2026 at 12:34 am
  • Editorial Team
    Editorial Team added an answer Well, https://stackoverflow.com/content/img/so/logo is a 404. If it were not, then… May 12, 2026 at 12:34 am

Related Questions

I want to have the addthis widget available for my users, but I want
I will apologize in advance as this post is born out of severe frustration.
I've been experiencing a high degree of flicker and UI lag in a small
I have a web page where I want to switch the background image of

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

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.