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 5 of 5
  1. #1
    Regular Coder
    Join Date
    Apr 2005
    Posts
    313
    Thanks
    18
    Thanked 2 Times in 2 Posts

    Column alignment?

    REF: http://moderntimes.com/tmp/

    I have two questions regarding the above page.

    1. How do I get the 1px border on the right side of the center column to extend to the bottom of the page?

    2. And how do I get the top of the Search box to align with the text in the adjoining column?

    Thanks,
    Michael

  • #2
    Regular Coder Jutlander's Avatar
    Join Date
    Jun 2007
    Location
    In my own sick little world :P
    Posts
    425
    Thanks
    1
    Thanked 12 Times in 12 Posts
    Have a look at this 3 column layout. It does what you need. Try and study the code, our id names are almost the same, so shouldn't be too hard.

    Code:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    <title>3 columns with header &amp; footer layout</title>
    <style type="text/css">
    * {
    margin: 0;
    padding: 0;
    }
    body {
    margin-bottom: 40px;
    }
    #wrapper {
    margin: 0 auto;
    margin-top: 15px;
    width: 900px;
    border: 1px solid #777;
    color: #444;
    background: #fff;
    }
    #header {
    border-bottom: 1px solid #777;
    padding: 1em;
    background: #ddd;
    }
    #left {
    float: left;
    width: 170px;
    padding: 1em;
    }
    #right {
    float: right;
    width: 170px;
    padding: 1em;
    }
    #content {
    margin-left: 200px;
    margin-right: 200px;
    border-left: 1px solid #777;
    border-right: 1px solid #777;
    padding: 15px;
    }
    #content p {
    margin-bottom: 20px; 
    }
    #content h2 {
    margin: 0 0 .5em 0;
    }
    #footer {
    clear: both;
    border-top: 1px solid #777;
    text-align: center;
    padding: 10px;
    background: #ddd;
    }
    </style>
    </head>
    
    <body>
    
    <div id="wrapper">
    
    	<div id="header"><h1>Header</h1></div>
    
    	<div id="left">
    	<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor 
    	incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis 
    	nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. 
    	Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu 
    	fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in 
    	culpa qui officia deserunt mollit anim id est laborum.</p>
    	</div>
    	
    	<div id="right">
    	<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor 
    	incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis 
    	nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. 
    	Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu 
    	fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in 
    	culpa qui officia deserunt mollit anim id est laborum.</p>
    	</div>
    	
    	<div id="content">
    	
    	<h2>Content header</h2>
    	
    	<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor 
    	incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis 
    	nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. 
    	Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu 
    	fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in 
    	culpa qui officia deserunt mollit anim id est laborum.</p>
    	
    	<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor 
    	incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis 
    	nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. 
    	Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu 
    	fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in 
    	culpa qui officia deserunt mollit anim id est laborum.</p>
    	
    	<p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor 
    	incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis 
    	nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. 
    	Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu 
    	fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in 
    	culpa qui officia deserunt mollit anim id est laborum.</p>
    
    	</div>
    	
    	<div id="footer"><p>Lorem ipsum dolor sit amet</p></div>
    
    </div>
    
    </body>
    </html>
    .
    .

  • #3
    Regular Coder
    Join Date
    Apr 2005
    Posts
    313
    Thanks
    18
    Thanked 2 Times in 2 Posts
    Hi Jutlander,

    Yes that works. I should have seen the "right" border! It all makes sense. Extremely good response!

    I don't quit know what you mean by our id names?

    Jutland, great name, great battle!

    Again, thanks much,
    Michael Mills

  • #4
    Regular Coder Jutlander's Avatar
    Join Date
    Jun 2007
    Location
    In my own sick little world :P
    Posts
    425
    Thanks
    1
    Thanked 12 Times in 12 Posts
    Quote Originally Posted by michael180 View Post
    Hi Jutlander,

    I don't quit know what you mean by our id names?
    I meant that you have a #wrapper, just as I do - just to take one example.

    Quote Originally Posted by michael180 View Post
    Jutland, great name, great battle!
    Hell, I thought when Scotland can have highlanders, then we can have jutlanders.
    .
    .

  • #5
    Regular Coder
    Join Date
    Apr 2005
    Posts
    313
    Thanks
    18
    Thanked 2 Times in 2 Posts
    I see, thanks, again.
    MM


  •  

    Posting Permissions

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