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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T06:53:34+00:00 2026-05-12T06:53:34+00:00

I am in need of a css layout for fixed size sidebar and a

  • 0

I am in need of a css layout for fixed size sidebar and a fluid content area. Problem is, most css layouts for this format use float to position the sidebar. Because of this, I can not use a clear: both inside the content area.

Check out the html attached. Content area skips to bottom of nav content at float.

I need a solution for this type of a css layout which still allows me to use floats/clear inside the content area.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
    <meta http-equiv="content-type" content="text/html; charset=iso-8859-1">
    <style type="text/css" media="screen">
        body {
            margin: 0;
            padding: 0;
        }

        #nav {
            float: left;
            width: 160px;
        }

        #content {
            margin: 0 0 0 200px;
            background-color: green;
        }       
</style>
</head>
<body>
<div>

    <div id="nav">

        This is the nav content<br/>
        This is the nav content<br/>
        This is the nav content<br/>
        This is the nav content<br/>
        This is the nav content<br/>
        This is the nav content<br/>
        This is the nav content<br/>
        This is the nav content<br/>
        This is the nav content<br/>
        This is the nav content<br/>
        This is the nav content<br/>
        This is the nav content<br/>
        This is the nav content<br/>
        This is the nav content<br/>
        This is the nav content<br/>

    </div>
    <div id="content">

        This is the main content<br/>
        This is the main content<br/>
        This is the main content<br/>
        This is the main content<br/>


        <div style="padding: 10px; float: left; width: 100px; background-color: yellow;">Left</div>
        <div style="padding: 10px; float: right; width: 100px; background-color: orange;">Right</div>

        <div style="clear: both;"> </div>

        (This shouldn't be way down here) This is the main content<br/>
        This is the main content<br/>
        This is the main content<br/>
        This is the main content<br/>

    </div>
</div>
</body>
</html>
  • 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-05-12T06:53:34+00:00Added an answer on May 12, 2026 at 6:53 am

    I changed the #nav from “float:left;” to “position:absolute;”. Will that do what you wanted?

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

Sidebar

Related Questions

I need to layout a html datatable with CSS. The actual content of the
Pulling my hair out with this simple CSS layout. I have a 2-column fixed
I need to build a HTML/CSS layout with the following layout |Static Div|Content Div0|Content
I need some help with a CSS layout. It is set up like this:
i need to find away to parse html and css layout to be able
I'm not new at CSS, but this is problem for me and I can't
[Update] I actually compromised on this problem for now by foregoing the fixed footer
I need to create the following layout: +--------+----------------------------------+-----------+ | fixed | variable | variable
I have another CSS problem. A layout that escapes me. I could, I suppose,
Background I need to do a rather complex layout for a client, using fixed

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.