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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T21:54:59+00:00 2026-06-18T21:54:59+00:00

This might be a really basic css question but I tried to create my

  • 0

This might be a really basic css question but I tried to create my fluid layout following instructions from a book, so far my header and nav bar seems to be in the place but the content div isn’t, also I’d like to make my content height flexible because it’s for a dynamic web app so the footer should be positioned below it accordingly. Ok so here’s the mockup of what id like to achieve
enter image description here

<body>

<div id="header">
<h1>LOGO</h1>
<ul>
<li><a href= ""> Home </a></li>
<li><a href= ""> Logout </a></li>
</ul>
</div>

<div id="navigation">
<ul>
    <li><a href="">Home</a></li> 
    <li><a href="">My account</a></li> 
    <li><a href="">Help</a></li> 
    <li><a href="">Contact Us</a> </li> 
    </ul>

</div>
<div id="personalised">
<p>Hey there</p>
</div>
<div id="content">

</div>
<div id="footer">
<p>&copy; TEST</p>
</div>
</body>
</html>

here’s my css code:

body{
width: 90%;
margin: 0 auto;}

#content {
overflow: auto;
height: 29em;}

#header{
height: 60px;
overflow: hidden;
}
#header h1 {
    float: left;
}
#header ul {

    float: right;
}
#header li {
    display: inline;
    padding: 0.5em;
}

#personalised p {
float: left;
width: 20%;
margin-top:5%;}

#navigation{
margin: 1%;}

#navigation ul {
font-family: Arial, Verdana;
font-size: 14px;
padding: 0px;
list-style: none;
}

div#navigation {
float:right;
position: absolute;
top: 10%;
right: 5%;
}
#navigation ul li {
display: block;
position: relative;
float: left;
}
#navigation li ul { display: none; }

#header, #footer, #navigation, #personalised {
margin: 1%;
}
#footer {
padding: 0.5em 0;
font-family: Arial, Verdana;
font-size: 10px;
text-align: center;}

I know this is long, but I’d really appreciate your help. Thanks in advance

  • 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-18T21:55:01+00:00Added an answer on June 18, 2026 at 9:55 pm

    Try working on your formatting first. (It’s not too bad, but can use improvement.) That’s one of the biggest benefits to you is code that you can read. You can look through what I’ve done here and play with what you like. http://jsfiddle.net/mPH8X/

    <head>
    <style>
    div {
     border: 1px dashed #FF0000;
    }
    body {
        margin: 0px;
        padding: 0px;
    }
    
    .clear {
        clear: both;
    }
    
    #header {
        min-height: 60px;
        overflow: hidden;
        margin: 1%;
    }
    #header h1 {
        float: left;
    }
    #header ul {
    
        float: right;
    }
    #header li {
        display: inline;
        padding: 0.5em;
    }
    
    #navigation{
        margin: 1%;
        float: right;
    }
    
    #navigation ul {
        font-family: Arial, Verdana;
        font-size: 14px;
        padding: 0px;
        margin: 0px;
        list-style: none;
    }
    
    #navigation ul li {
        margin: 0px;
        padding: 0px;
        display: block;
        position: relative;
        float: left;
    }
    
    #navigation li ul { 
        display: none; 
    }
    
    .body {
        clear: both;
    }
    
    #personalised {
        margin: 1%;
        float: left;
        width: 20%;
    }
    
    #content {
        margin: 1%;
        float; right;
        min-height: 29em;
    }
    
    #personalised p {
        margin: 0px;
        padding: 0px;
    }
    
    #header, #footer, #navigation, #personalised {
    
    }
    
    #footer {
        padding: 0.5em 0;
        font-family: Arial, Verdana;
        font-size: 10px;
        text-align: center;
    }
    </style>
    <body>
    
    <div id="header">
        <h1>LOGO</h1>
        <ul>
            <li><a href= ""> Home </a></li>
            <li><a href= ""> Logout </a></li>
        </ul>
        <div class="clear"></div>
    </div>
    
    <div id="navigation">
        <ul>
            <li><a href="">Home</a></li> 
            <li><a href="">My account</a></li> 
            <li><a href="">Help</a></li> 
            <li><a href="">Contact Us</a> </li> 
        </ul>
    
        <div class="clear"></div>
    </div>
    
    <div class="body">
        <div id="personalised">
            <p>Hey there</p>
            <div class="clear"></div>
        </div>
    
        <div id="content">
    
        </div>
    </div>
    
    <div id="footer">
        <p>&copy; TEST</p>
    </div>
    </body>
    </html>
    

    Edit: Looking at your content statement, you are looking for CSS’s min-height. Min-height will set it to a minimum height and grow when necessary. overflow: auto; says if your content stretches past the maximum height, add a scrollbar.

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

Sidebar

Related Questions

This might be a really basic question but how do I create default values
This might sound very very basic 101 type question, but I really need help
This might seem like a really basic question but, When dividing the output of
This might sound a silly question but I've really spend hours in trying to
I've just started learning jQuery/javascript, so this might seem like a really basic question,
The Question i am asking might be a basic but i really need more
I know this question might sound really basic for most of you. I need
I know this question might be repeated many times but would really appreciate any
This question might be really easy but for the life of me i cant
this might be really simple and I've tried searching but I haven't been able

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.