Anonymous 0

Hi,

I'm about to place a div (height 30px) at the bottom of a HTML page. On some pages there will be a scroll, then the div should be placed at the very end of the page (not like Facebook's always visible), sometimes the content is very short. Then it should be placed at the very bottom of the browser.

If I should do it with tables it should look something like this:

<table height="100%">
<tr><td>Content of page</td></tr>
<tr><td height="30">Footer</td></tr>
</table>

How to do this without tables? Is it possible?

2 answers

5
points
This was chosen as the best answer

This will do it:

http://www.cssstickyfooter.com/

always at the bottom of the page or the bottom of the window, depending on how much content you have.

Answered about 7 years ago by Tony Crockford
  • Just what I was looking for! Thank you very much! Robert Lord about 7 years ago
  • Oh, how could I have missed this link/solution before >_< Jens Hedqvist about 7 years ago
1
point

Another option available to you would be the tag new in HTML 5:

http://www.w3schools.com/html5/tag_footer.asp

Although of course not supported in IE (I feel like I should just make that phrase a signature) it's something to keep an eye on.

Then you can just style the tag in CSS to stay at the bottom of the page.

Answered about 7 years ago by Jim Holby