Not showing whole div if you minimize in IE

Discussion in 'HTML & Website Design' started by zokiii, Jun 9, 2006.

  1. #1
    I have problems with showing some div in IE .
    It shows in first loading div ok (div contains picture and some text under logo), but if you minimize window and bring up again you will see differencies.
    ->It will not show whole div
    Or you can cross over the window with something else (like explorer) and then again div is not showing.

    Firefox and Opera show page Ok.

    Link

    What could be a problem ?
     
    zokiii, Jun 9, 2006 IP
  2. ludwig

    ludwig Notable Member

    Messages:
    2,253
    Likes Received:
    66
    Best Answers:
    0
    Trophy Points:
    225
    #2
    maybe this can cause it

    <div id="main">
    <div id="content">
    <div id="mainfeature">
     
    ludwig, Jun 9, 2006 IP
  3. FeelLikeANut

    FeelLikeANut Peon

    Messages:
    330
    Likes Received:
    19
    Best Answers:
    0
    Trophy Points:
    0
    #3
    zokiii, it seems you are having your first experience with IE's "Peek-a-boo" bug. The fix is almost as odd as the bug itself. . . . You need to assign a height of 0 to the box that disappears, and, since assigning a height of 0 will produce an unwanted affect on any other browser, you will need to use conditional comments to ensure this style is applied only to IE.

    <!--[if IE]>
    <style type="text/css">
    #mainfeature { height: 0 }
    </style>
    <![endif]-->
    Code (markup):
     
    FeelLikeANut, Jun 9, 2006 IP
  4. zokiii

    zokiii Peon

    Messages:
    656
    Likes Received:
    13
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Thanks FeelLikeANut !

    It works!
     
    zokiii, Jun 9, 2006 IP
  5. kk5st

    kk5st Prominent Member

    Messages:
    3,497
    Likes Received:
    376
    Best Answers:
    29
    Trophy Points:
    335
    #5
    There are several ways to fix the Peekaboo bug. I stole Big John's test case and applied each of the various fixes. I also show one or two more fixes than he lists. It's a Good Thing to have options. Sometimes one fix or another may cause troubles. At least one fix will work in any given case.

    cheers,

    gary
     
    kk5st, Jun 9, 2006 IP
  6. zokiii

    zokiii Peon

    Messages:
    656
    Likes Received:
    13
    Best Answers:
    0
    Trophy Points:
    0
    #6
    Unfortunately, when i put this code for IE I'm losing bottom border.
    Border is under text Digital camera news.
    You can see it in Firefox.

    Link

    What should I do ?
     
    zokiii, Jun 10, 2006 IP
  7. FeelLikeANut

    FeelLikeANut Peon

    Messages:
    330
    Likes Received:
    19
    Best Answers:
    0
    Trophy Points:
    0
    #7
    That problem with the border was actually already there. Before the fix was applied for the banner, that border was initially invisible and would only reappear at the same time that the banner would dissappear. Applying the exact same fix to the #content box seems to do the trick.
    <!--[if IE]>
    <style type="text/css">
    #mainfeature, #content { height: 0; }
    </style>
    <![endif]-->
    Code (markup):
     
    FeelLikeANut, Jun 10, 2006 IP