0

I have a header div, inside this is some content. The whole div is text-align:right. I want the content to sit on the right but more importantly sit on the bottom of the div, not the top.

#header {

height:79px;
background:url(images/jtl-logo.png) no-repeat left top;
text-align:right;
padding:0px 9px; }

Surely there must be a way of doing this in the CSS so that content always aligns to the bottom of it's container, it seems like it's incredibly necessary?

The only other way I can think to do it is applying padding to the header to push it down, but that seems a bit ridiculous when this is such a simple thing.

Francesca
  • 26,842
  • 28
  • 90
  • 153
  • Take a look here: http://stackoverflow.com/questions/311990/how-do-i-get-a-div-to-float-to-the-bottom-of-its-container – Griffosx Jul 24 '12 at 14:35

1 Answers1

0

You could wrap up the text in another DIV or SPAN element and then apply CSS positioning to move it to the bottom.

Martin Blore
  • 2,125
  • 4
  • 22
  • 34
  • That's another way I thought. I'm just surprised you can text-align left and right but not bottom or top also. Seems like a no-brainer. – Francesca Jul 24 '12 at 14:36
  • I found this earlier when I was looking in to this myself, hope it helps: http://phrogz.net/css/vertical-align/index.html – Martin Blore Jul 24 '12 at 14:40