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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T16:00:13+00:00 2026-06-06T16:00:13+00:00

http://designobvio.us/vodka/ Live demo I’ve set my html, container, main and 100% but nomatter what

  • 0

http://designobvio.us/vodka/ Live demo

I’ve set my html, container, main and 100% but nomatter what I do I cannot get the border to be 100% height without scroll bars?

How can I achieve an effect?

HTML

  <div id="main">

  </div>

CSS (not currently the live code but this is what i’ve tried )

html, body{height:100%; width:100%;} 
#main{height:100%; position:absolute; top:0px; bottom:0px; left:0px; right:0px; border:5px solid #000;}
  • 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-06T16:00:16+00:00Added an answer on June 6, 2026 at 4:00 pm

    Are you looking for a fixed border or dynamic border? The problem with your code is the W3C box-model. In the default model, padding, margin and border are added to the size of your element. So in your code what you’re really telling it is “make the box 100% and then add 10px worth of border”.

    Normally an easy change would be to manually switch the box model, but unfortunately that property does not play nice with height: 100%. So you have a few options:

    1) If you are looking for a fixed border, this is a good trick: http://css-tricks.com/body-border/
    2) If you need a dynamic border, you need to somehow get around the additional height the border adds. Here is one way:

    html,body { height:100%; padding: 0; margin: 0; }
    #container {
        min-height:100%;
        border-right: 5px solid #000;
        border-left: 5px solid #000;
        position: relative; /* relative postion so we can absolutely position footer within it */
    }
    #header {
        height: 100px;
        border-top: 5px solid #000;
        background-color: red;
    }
    #content { padding: 0 0 100px 0; } /*padding must be equal to the height of the footer*/
    #footer {
        height: 100px;
        border-bottom: 5px solid #000;
        background-color: blue;
        position: absolute;
        bottom: 0;
        width: 100%; /* with absolute position, a width must be declared */
    } 
    

    HTML

    <div id="container">
        <div id="header"></div>
        <div id="content"></div>
        <div id="footer"></div>
    </div>
    

    jsfiddle here: http://jsfiddle.net/Qw2cb/

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

Sidebar

Related Questions

Heres the site: http://designobvio.us/portfolio/body.html I've tried css3, % base. Cannot seem to get this
Heres the design http://vvcap.net/db/OuxLOYioWmjIAavL5N9U.htp Here's a demo! http://designobvio.us/GoldGrid2/ I'm trying to get a vertically
http://lakefrontmotorlodge.co.nz/new/ I am trying to get the background to fade smoothly, but it fades
http://designobvio.us/DoUs/directPro.html jQuery Script $(window).scroll(function() { $('#nav').css('top', $(this).scrollTop() + px); }); HTML <nav id=nav class=grid_2>
heres the site http://designobvio.us/DoUs/directPro.html anyone know which selector I'd target to make my navigation
My Website: http://designobvio.us/portfolio/index.html Aspiring Website Layout: http://www.googlezeitgeist.com/en/top-searches/rebecca_black I've just finished my navigation bar which
Here is my website: http://designobvio.us/portfolio/body.html Here's my aspiring website: http://www.googlezeitgeist.com/en/top-searches/battlefield_three I'm getting pretty close
http://www.chai3d.org/doc/classc_camera.html#6b5bbcc535b601c19e10be288dfc65f7 for bool cCamera::set ( const cVector3d & a_localPosition, const cVector3d & a_localLookAt, const
http://mindfulintegrations.com/signiacapital/index.html It works fine in FF3 and IE8 using SwfObject2 and wmode=transparent, but for
http://jsbin.com/oqotew/edit#html,live If you visit the link above when you have a wide browser window,

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.