January 7, 201016 yr hiya guys, i am trying to set up a simple page layout, i think from the files its clear what im trying to achieve, i want a header div then nav bar then a links on the left and content on the right with a simple footer at the bottom, i cannot seem to get the header to stay at the bottom :S also i would like to know how to make it so that when the content div fills with information it will expand with the hole page if that makes senes ? so i can put as much info as i want in it. thanks for any help Darren Marshall - Portfolio - Copy.zip
January 7, 201016 yr Everything should be inside your header/content/footer divs. Header --navBar Content --pagecontent (right box) --links (left box) Footer --Anything Also remove the "align=left" from everything. Everything will go to 800px if you don't give it a width so remove all of those. <div class="wrapper"> <div class="header"> <div class="logo_or_whatever">Header</div> <div class="navBar"> <ul> <li>Nav1</li> <li>Nav2</li> </ul> </div> <!--/navBar --> </div> <!-- /header --> <div class="content clearfix"> <div class="pagecontent">Page Content</div> <div class="links">Links.</div> </div> <!-- /content --> <div class="footer"> Footer </div> <!-- /footer --> </div> <!-- /wrapper --> @charset "utf-8"; /* CSS Document */ .wrapper{ width:800px; margin:auto; /* centers the "wrapper" div */ } .header{ background-color:#CCCCCC; } .navBar{ background-color:#FF00FF; } .links{ width:190px; height:300px; float:left; background-color:#CCCCCC; } .content{ margin-top:40px; } .pagecontent { float:right; width:570px; height:300px; background-color:#999999; } .footer{ background-color:#FF00FF; } /* CLEARFIX - http://www.positioniseverything.net/easyclearing.html */ .clear { clear: both; display: block; overflow: hidden; visibility: hidden; width: 0; height: 0; } .clearfix:after { clear: both; content: ' '; display: block; font-size: 0; line-height: 0; visibility: hidden; width: 0; height: 0; } .clearfix { display: inline-block; } * html .clearfix { height: 1%; } .clearfix { display: block; }
January 7, 201016 yr Author Everything should be inside your header/content/footer divs. Header --navBar Content --pagecontent (right box) --links (left box) Footer --Anything Also remove the "align=left" from everything. Everything will go to 800px if you don't give it a width so remove all of those. <div class="wrapper"> <div class="header"> <div class="logo_or_whatever">Header</div> <div class="navBar"> <ul> <li>Nav1</li> <li>Nav2</li> </ul> </div> <!--/navBar --> </div> <!-- /header --> <div class="content clearfix"> <div class="pagecontent">Page Content</div> <div class="links">Links.</div> </div> <!-- /content --> <div class="footer"> Footer </div> <!-- /footer --> </div> <!-- /wrapper --> @charset "utf-8"; /* CSS Document */ .wrapper{ width:800px; margin:auto; /* centers the "wrapper" div */ } .header{ background-color:#CCCCCC; } .navBar{ background-color:#FF00FF; } .links{ width:190px; height:300px; float:left; background-color:#CCCCCC; } .content{ margin-top:40px; } .pagecontent { float:right; width:570px; height:300px; background-color:#999999; } .footer{ background-color:#FF00FF; } /* CLEARFIX - http://www.positioniseverything.net/easyclearing.html */ .clear { clear: both; display: block; overflow: hidden; visibility: hidden; width: 0; height: 0; } .clearfix:after { clear: both; content: ' '; display: block; font-size: 0; line-height: 0; visibility: hidden; width: 0; height: 0; } .clearfix { display: inline-block; } * html .clearfix { height: 1%; } .clearfix { display: block; } Perfect thanks alot
January 8, 201016 yr Author On Google? Not even - http://layouts.ironmyers.com/100_percent_Layouts/layout/?id=1 ? that doesn't really help though because i wanted to know the code
January 11, 201016 yr On Google? Not even - http://layouts.ironmyers.com/100_percent_Layouts/layout/?id=1 ? Actually, you could have downloaded some of them and studied the HTML / CSS layouts (as I'm going to do )
Create an account or sign in to comment