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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T03:06:31+00:00 2026-06-11T03:06:31+00:00

I have a layout with header and sticky footer . Both are 40px high.

  • 0

I have a layout with header and sticky footer. Both are 40px high. Now I need to add aside with a scroolbar, which will fill the free space (verticaly). It should looks like that:

preview

There are two restrictions:

  • no JavaScript
  • no CSS3 calc() function

Is there any strict CSS solution of this problem?

  • 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-11T03:06:33+00:00Added an answer on June 11, 2026 at 3:06 am

    Here’s a little demo of what I’m about to explain: little link.

    First, position your header and footer using absolute and fixed, respectively. Add 40px of padding to both top and bottom of body, and make sure its box-sizing is border-box. Set your aside‘s height to 100%, and also make sure it’s a border-box. Basically;

    HTML:

    <header>
        I'm a header!
    </header>
    <aside>
        Lots and lots and lots of content!
        Glee is awesome!
    </aside>
    <footer>
        I'm a footer!
    </footer>
    

    CSS:

    html {
        -moz-box-sizing: border-box;
        -webkit-box-sizing: border-box;
        box-sizing: border-box;
        height: 100%;
    }
    body {
        padding-top: 40px;
        padding-bottom: 40px;
        -moz-box-sizing: border-box;
        -webkit-box-sizing: border-box;
        box-sizing: border-box;
        height: 100%;
    }
    header {
        height: 40px;
        width: 100%;
        position: absolute;
        top: 0px;
    }
    footer {
        height: 40px;
        width: 100%;
        position: fixed;
        bottom: 0px;
    }
    aside {
        -moz-box-sizing: border-box;
        -webkit-box-sizing: border-box;
        box-sizing: border-box;
        height: 100%;
        overflow: auto; /*make sure there are scrollbars when needed*/
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have layout which contains a header, content in the scrollview and a footer.
we have a Tiles layout page having Header, Menu, Body and Footer. In this
I have an application layout in my rails app to give a default header/footer
I want to add button to following header. It should have layout like http://www.fullstopinteractive.com/
I have layout, which contain two parts: header and body. Header contain TextView and
I'm creating a layout and have a header aligned on top, a footer aligned
How to align the buttons bottom of the screen.In the layout i have header
I have a basic layout page template: --- layout: default --- <header class="sidebar"> {{
I have a layout like this in which I want to display a label
I have a layout which looks like this: <LinearLayout> <ImageView> android:width=wrap_content android:height:wrap_content ... </ImageView>

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.