[thelist] 100% Image Height

James Aylard webmaster at equilon-mrc.com
Fri Sep 28 10:41:10 CDT 2001


Olly,

> the image doesnt show up at all in IE5.5, Opera, or Mozilla 0.9.4.

    Stretching an image to 100% height of the <td> *can* be done, although
behavior may not be consistent across browsers. First things first, though:
if the image doesn't show up at all, are you sure that your src attribute
contains a valid path? Make sure that the image shows up first, then go
about stretching it to fill your table.
    To get the image to stretch, make sure that your table and your <td> are
the height you expect. You may need to explicitly set their heights to do
this, but to test, be sure to turn the table's borders on to verify how tall
your containing <td> actually is. Also, keep in mind that the <table> does
not include a "height" attribute in the W3C HTML 4.01 specification,
although both Netscape 4.x and IE support it as a proprietary attribute
(although there may be implementation differences).
    Also consider using CSS for setting your table, td, and img sizes -- or
using CSS to set your image as the background image of the table or td with
a background-repeat value of repeat-y.
    If you continue to have trouble, post a url or the relevant snippet of
code for the list to consider.

hth,
James Aylard





More information about the thelist mailing list