IceDragon Posted July 27, 2008 Share Posted July 27, 2008 I am trying to set up a table that would cover the whole website (for main page - in the middle of a page there would be a main image and at the bottom a copyright image.), but instead the table only covers a small portion at the top (width fits right but height doesn't) <body> <table width="100%" height="100%" cellpadding="0" border="0" cellspacing="0"> <tr height="95%"> <td align="center"><img src="main_img.jpg" /></td> </tr> <tr height="5%"> <td align="left"><img src="copyright.jpg" /></td> </tr> </table> </body> anyone knows whats wrong with the code? Quote Link to comment Share on other sites More sharing options...
secoxxx Posted July 27, 2008 Share Posted July 27, 2008 You should be using divs. you wont have the same results in multiple browsers with tables. Quote Link to comment Share on other sites More sharing options...
IceDragon Posted July 27, 2008 Author Share Posted July 27, 2008 i tried but i can't seem to be able to get the copyright img appear at the bottom of the site.. It places it just below the main_img.jpg Quote Link to comment Share on other sites More sharing options...
IceDragon Posted July 27, 2008 Author Share Posted July 27, 2008 never mind. I've managed to fix it <style> #Header {height:180px; position:absolute; left:38%; top:15%;} #Footer {height:30px; position:absolute; bottom:0px;} </style> <div id="Header" align="center"><img src="main_img.jpg" /></div> <div id="Footer" align="left"><img src="copyright.jpg" /></div> </body> Quote Link to comment Share on other sites More sharing options...
secoxxx Posted July 27, 2008 Share Posted July 27, 2008 .footer { position:absolute; bottom:0; width:100%; } <div class="footer">Footer</div> Quote Link to comment Share on other sites More sharing options...
IceDragon Posted July 27, 2008 Author Share Posted July 27, 2008 Thanks man. I forgot about the width. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.