SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Member
    Join Date
    Nov 2004
    Location
    fsaf
    Posts
    1
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    CSS div height...

    I know there is something in the faq about this but I just couldn't get it to work right...

    Code:
    .outerthing
    {
      DISPLAY: table;
      FLOAT: left;
      PADDING: 0px;
      BORDER-STYLE: none;
      HEIGHT: auto;
    }
    .inner
    {
      DISPLAY: table-cell;
      HEIGHT: 100%;
      FLOAT: left;
    }
    
    <span class=\"outerthing\">
                  <div class=\"inner\">$new</div>
                  <div class=\"inner\"><a href=forum.php?id=$forum[id]>$forum[name]</a><br />$forum[descrip]</div>
                  <div class=\"inner\">$numofthreads</div>
                  <div class=\"inner\">$numofposts</div>
                  <div class=\"inner\">$lastpdate</div>
                  </span>
    I have the body/html height to 100%... and the thing is... it stretches to 100% fine in Mozilla Firefox... but not in IE. Anybody got suggestions..

  2. #2
    Non-Member Egor's Avatar
    Join Date
    Jan 2004
    Location
    Melbourne, Australia
    Posts
    7,305
    Mentioned
    1 Post(s)
    Tagged
    1 Thread(s)
    Maybe because IE doesn't understand display: table; and display: table-cell;?

  3. #3
    The CSS Clinic is open silver trophybronze trophy
    Paul O'B's Avatar
    Join Date
    Jan 2003
    Location
    Hampshire UK
    Posts
    40,341
    Mentioned
    179 Post(s)
    Tagged
    6 Thread(s)
    You need to set the outerv to 100% for ie.

    Code:
    * html .outerthing {height:100%}
    Which should come after the height:auto if course

    IE doesn't understand display table but its not for ie anyway. Ie inherits the 100% whereas mozilla doesn't unless you make it like a table. IE just ignores the display:table.

    Paul


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •