How to stretch a short page down to screen bottom?

M

metalive

Good day!

I have a website with a simple table layout. On some pages, there is
only little text in my main content-<td> so the page/table ends half way
down the screen displaying the plain black backround. Is there a way
(preferably with CSS) to have short pages automatically stretch to the
bottom of the browser's display area?

Greetings
 
R

Roy Schestowitz

metalive said:
Good day!

I have a website with a simple table layout. On some pages, there is
only little text in my main content-<td> so the page/table ends half way
down the screen displaying the plain black backround. Is there a way
(preferably with CSS) to have short pages automatically stretch to the
bottom of the browser's display area?

Greetings

Add the following to your table:

style="height: 100%;"

Roy
 
S

Steve Pugh

Roy Schestowitz said:
Add the following to your table:

style="height: 100%;"

On its own that only works in quirks mode. In standards mode you need
to also set the height of the body and html elements to 100%.

Steve
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,764
Messages
2,569,567
Members
45,041
Latest member
RomeoFarnh

Latest Threads

Top