Posted By

hotdiggity on 09/02/10


Tagged

css alignment


Versions (?)

Who likes this?

2 people have marked this snippet as a favorite

jplr
damienan


Align child div to bottom of parent div


 / Published in: CSS
 

  1. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  2. <html>
  3. <head>
  4. <title></title>
  5. </head>
  6. <style>
  7. html, body {height: 100%}
  8. #outer {position: relative; height: 50%;}
  9. #inner {position: absolute; bottom: 10px;}
  10. #outer, #inner {border: 1px solid #ccc;}
  11. </style>
  12. <body>
  13. <div id="outer">OUTER
  14. <div id="inner">INNER
  15. </div>
  16. </div>
  17. </body>
  18. </html>

Report this snippet  

You need to login to post a comment.