Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New to the CF scene
    Join Date
    Dec 2005
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Newb: Sorry if I couldn't find this. Help with variable and fixed width CSS layouts

    Is this layout possible with CSS? After a lot of failed attempts, I just can't make it work with CSS without scrollbars but it works fine (with invalid code and depracated tags) across browsers with tables as far as I know...

    Table layout:
    http://www.zachhegwood.com/otherstuff/tablelayout.html

    Anyway, any help would be appreciated.

    Thanks.

  • #2
    Regular Coder Graft-Creative's Avatar
    Join Date
    Aug 2004
    Location
    Web Designer - North East Lancashire U.K.
    Posts
    842
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I got pretty close:

    Code:
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    <title>Untitled Document</title>
    <style type="text/css">
    
    html, body {
    height: 100%;
    }
    
    div#header {
    height: 85px;
    background: #555;
    }
    
    div#sidebar {
    clear: both;
    float: left;
    background: #777;
    min-height: 100%;
    width: 150px;
    }
    
    * html div#sidebar {
    height: 100%;
    }
    
    div#content {
    min-height: 100%;
    background: #888;
    margin-left: 150px;
    }
    
    * html div#content {
    height: 100%;
    }
    
    div#footer {
    height: 50px;
    margin-left: 150px;
    margin-top: -50px;
    background: #999;
    }
    
    </style>
    </head>
    
    <body>
    <div id="header"></div>
    <div id="sidebar"></div>
    <div id="content"></div>
    <div id="footer"></div>
    </body>
    </html>
    It's a bit out, but maybe it will give you something to work from.

    Kindest regards,

    Gary

  • #3
    New to the CF scene
    Join Date
    Dec 2005
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts
    thanks, man... I'll work with that.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •