table in table -> 100% height does not work

Discussion in 'HTML' started by Paul Schmidinger, Aug 10, 2004.

  1. Hello,

    I have a complex table (which I have simplified for this post to allow
    better focus on the problem ). In one cell, I want to show 2 images. One at
    the top of the cell, one at the bottom. I do not know the height of the
    cell - the height depends on the amount of content in the other cells in the
    same row and on the width of the beowser-window. What I tried is creating
    another table in the cell, with 2 rows (with 1 cell each), aligning the
    images at the top and bottom. But the browser (IE 6) ignores the
    height="100%" -- which is strange, for usually it accepts this attribute.

    Here is the simplified example:
    http://www.eigelb.at/tables.html

    If I specify the height of the table absolute (in Pixels) and without "%",
    it works fine. But I can not do that for I do not know the height of the
    cell and therefore the height of the table.

    Any help would be appreciated -- I don't care if there is a subtable in the
    cell or not, I just want to align 2 images in a cell - one on top, one at
    bottom, no matter what height the cell has. I would to prefer not using
    JavaScript (e. g. reading the height of the cell, then setting the height of
    the table using JavaScript).

    Thanks,
    Paul Schmidinger

    -- www.eigelb.at
    Paul Schmidinger, Aug 10, 2004
    #1
    1. Advertising

  2. Paul Schmidinger

    Claus Madsen Guest

    Paul Schmidinger wrote:

    > Any help would be appreciated -- I don't care if there is a subtable
    > in the cell or not, I just want to align 2 images in a cell - one on
    > top, one at bottom, no matter what height the cell has. I would to
    > prefer not using JavaScript (e. g. reading the height of the cell,
    > then setting the height of the table using JavaScript).
    >


    Maybe this will do the trick:

    http://clausmadsen.dk/uk/test/

    --
    Claus Madsen - http://clausmadsen.dk
    Claus Madsen, Aug 10, 2004
    #2
    1. Advertising

  3. > > Any help would be appreciated -- I don't care if there is a subtable
    > > in the cell or not, I just want to align 2 images in a cell - one on
    > > top, one at bottom, no matter what height the cell has. I would to
    > > prefer not using JavaScript (e. g. reading the height of the cell,
    > > then setting the height of the table using JavaScript).
    > >

    >
    > Maybe this will do the trick:
    >
    > http://clausmadsen.dk/uk/test/


    It does, thank you! I experimented with rowspan and colspan before, but I
    used too many of them so the browser would not use my width- and
    height-attributes. But using only some simple rowspans should do the trick!

    Paul Schmidinger
    -- www.eigelb.at
    Paul Schmidinger, Aug 10, 2004
    #3
  4. Paul Schmidinger

    roma1123

    Joined:
    Mar 24, 2011
    Messages:
    1
    roma1123, Mar 24, 2011
    #4
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Not4u
    Replies:
    9
    Views:
    1,027
    Not4u
    Feb 27, 2004
  2. Replies:
    8
    Views:
    6,664
    Neredbojias
    Dec 9, 2005
  3. Bernd Meier
    Replies:
    6
    Views:
    500
    GTalbot
    Jan 14, 2008
  4. fred
    Replies:
    3
    Views:
    260
    Zifud
    Mar 17, 2005
  5. Replies:
    5
    Views:
    867
Loading...

Share This Page