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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T05:54:44+00:00 2026-05-11T05:54:44+00:00

In the markup shown below, I’m trying to get the content div to stretch

  • 0

In the markup shown below, I’m trying to get the content div to stretch all the way to the bottom of the page but it’s only stretching if there’s content to display. The reason I want to do this is so the vertical border still appears down the page even if there isn’t any content to display.

Here is my DEMO:

body {     font-family: Trebuchet MS, Verdana, MS Sans Serif;     font-size:0.9em;     margin:0;     padding:0; } div#header {     width: 100%;     height: 100px; } #header a {     background-position: 100px 30px;     background: transparent url(site-style-images/sitelogo.jpg) no-repeat fixed 100px 30px;     height: 80px;     display: block; } #header, #menuwrapper {     background-repeat: repeat;     background-image: url(site-style-images/darkblue_background_color.jpg); } #menu #menuwrapper {     height:25px; } div#menuwrapper {     width:100% } #menu, #content {     width:1024px;     margin: 0 auto; } div#menu {     height: 25px;     background-color:#50657a; }
<form id='form1'>   <div id='header'>       <a title='Home' href='index.html' />   </div>    <div id='menuwrapper'>       <div id='menu'>       </div>   </div>    <div id='content'>   </div> </form>

  • 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. 2026-05-11T05:54:44+00:00Added an answer on May 11, 2026 at 5:54 am

    Your problem is not that the div is not at 100% height, but that the container around it is not.This will help in the browser I suspect you are using:

    html,body { height:100%; } 

    You may need to adjust padding and margins as well, but this will get you 90% of the way there.If you need to make it work with all browsers you will have to mess around with it a bit.

    This site has some excellent examples:

    http://www.brunildo.org/test/html_body_0.html
    http://www.brunildo.org/test/html_body_11b.html
    http://www.brunildo.org/test/index.html

    I also recommend going to http://quirksmode.org/

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

Sidebar

Related Questions

i'm trying to populate a ViewData instance with html markup like shown below. When
I am trying to create a table in an XHTML document shown below (only
I have an FAQ page that looks like the markup shown below When the
The markup below is used for my jQuery carousel widget. The first div serves
I am trying to show name-value pairs in a table cell as shown below
I'm using Ajax to dynamically populate a DIV. I have each page content stored
I am trying to get the below code to call to a PHP file,
EDIT My jsfiddle entry is here : http://jsfiddle.net/ehNrE/3/ All the codes(only those required) below
I need help with jQuery selectors. Say I have a markup as shown below:
I have the following standard markup: <body> <header><div class=wrapper>Header</div></header> <div id=create>create something</div> <div class=wrapper>Content</div>

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.