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

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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T11:35:39+00:00 2026-06-13T11:35:39+00:00

I am currently working on a HTML5 and CSS project and am having a

  • 0

I am currently working on a HTML5 and CSS project and am having a problem getting the containers to display properly.

What I want to have is a header bar at the top, a wrapper that contains 2 other divs and then a footer at the bottom which is always at the bottom of the window or at the bottom of the content whichever is further down.

Here’s a snippet:

html, body
{
	padding: 0;
	margin: 0;
}

#wrapper
{
	position: absolute;
	background-color: purple;
	height: 100%;
	width: 100%;
	margin-top: 0px;
}

header
{
	position: absolute;
	width: 100%;
	height: 80px;
	background-color: black;
	color: white;
}


#articleContainer
{
	background-color: blue;
	width: 75%;
	margin-left: auto;
	margin-right: auto;
	height: auto;
	margin-top: 80px;
}

#articleContent
{
	width: 70%;
	background-color: yellow;
	float: left;
}

#articleSideBar
{
	position: relative;
	width: 28%;
	background-color: green;
	float: right;
	margin-left: 2px;
	margin-right: 2px;
	display: inline;
	margin-top: 0px;
	float: right;
	height: auto;
}
<html>
	<head>
		<title>index</title>
		<link href="ArticleStyleSheet.css" rel="stylesheet" type="text/css" />
	</head>
	<body>
		<div id="wrapper">
			<header>
				Header
			</header>
			<div id="articleContainer">
				Article Container
				
				<div id="articleContent">
					The quick brown fox jumped over the lazy dogs back. All good men must come to the aid of the party
				</div>
				
				<div id="articleSidebar">
					Article Sidebar
				</div>
			</div>
		</div>
	</body>
</html>

At the moment the articleContainer is only the height of however many lines there are. What I want to have is the formContainer to fill the rest of the screen, I’ve tried adding the height: 100%; attribute but then this feels the form container over the screen size. I.e. a vertical scrollbar appears which is about the same height as the header. How can I get the formContainer to fill the available screen space without the scroll bar. However, if the content is larger than the form container should expand to fill the extra space.

Thanks for any help you can provide.

  • 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-13T11:35:41+00:00Added an answer on June 13, 2026 at 11:35 am

    If you really want a css3 solution the one you’re looking for is setting height: calc(100% - 80px); on #articleContainer as demonstrated in this fiddle, however this will not work in all browsers.

    Example using old flexbox model css:

    html, body
    {
        padding: 0;
        margin: 0;
        height: 100%;
    }
    
    #wrapper
    {
        display: -webkit-box;
        -webkit-box-orient: vertical;
        min-height: 100%;
        background-color: purple;
        width: 100%;
        margin-top: 0px;
    }
    
    header
    {
        width: 100%;
        height: 80px;
        background-color: black;
        color: white;
    }
    
    #articleContainer {
        width: 75%;
        margin: auto;
        background-color: blue;
        display: -webkit-box;
        -webkit-box-flex: 1;
    }
    
    #articleContent
    {
        width: 70%;
        background-color: yellow;
    }
    
    #articleSideBar
    {
        position: relative;
        width: 28%;
        background-color: green;
        margin-left: 2px;
        margin-right: 2px;
        display: inline;
        margin-top: 0px;
        height: auto;
    }​
    

    same thing, but this time using new flexbox model
    css

    html, body
    {
        padding: 0;
        margin: 0;
        height: 100%;
    }
    
    #wrapper
    {
        display: -webkit-flex;
        -webkit-flex-direction: column;
        min-height: 100%;
        background-color: purple;
        width: 100%;
        margin-top: 0px;
    }
    
    header
    {
        width: 100%;
        height: 80px;
        background-color: black;
        color: white;
    }
    
    #articleContainer {
        width: 75%;
        margin: auto;
        background-color: blue;
        display: -webkit-flex;
        -webkit-flex: 1;
    }
    
    #articleContent
    {
        width: 70%;
        background-color: yellow;
    }
    
    #articleSideBar
    {
        position: relative;
        width: 28%;
        background-color: green;
        margin-left: 2px;
        margin-right: 2px;
        display: inline;
        margin-top: 0px;
        height: auto;
    }​
    

    version with only the paragraph in yellow

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

Sidebar

Related Questions

I am currently working on an HTML, CSS, PHP project. I want to display
I am currently working on a html5 and jquery project. I have an html5
I'm currently working on a JavaScript project that uses the HTML5 canvas as a
I'm currently working on a project that uses django-registration and Django CMS. When display
i have used this tooltip in my project its working great but the problem
I am currently working on a GWT project where I am displaying an HTML
Currently working on a site built in Django and i'm getting an issue when
I'm currently working on a project where I need to print out a lesson
I'm working on a Chess-based hobby project with HTML/CSS/PHP. I wasn't familiar with chess
I do html/css by trade, and I have been working on and off django

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.