views:

39

answers:

2

I have a dynamic HTML document, and in a particular point of time it has a markup similar to this (but, of course, a lot more complex):

<div style="display: none">
    <select><option>some text</option></select>
</div>
<div>
    Some text
</div>

and my problem is that in IE 6, the select is still visible even though its parent is set as display: none. Has anyone else encountered this issue? I think I recall seeing this issue with checkboxes as well a long time ago. Other browsers work (of course), including IE8.

Of course, if you try just looking at this snippet in IE6, there will be no problem. It's a bug that is just triggered by doing things in the right order.

A: 

I can't reproduce the problem, tried on ie6 and it is not showing the select.

Can you place more of the code, to include the js you're using.

Also, ie6 tends to throw a hissy fit when it encounters little things.

Try adding a ";" to the end of your css. As per below: Haven't seen your code but this could be all it takes to make ie behave.

Gui Andrade
My question says it's not reproducible, and that it only happens under very specific circumstances. The page I have that shows the problem is huge and depends on a whole lot of javascript to run into the problem. My hope was that someone would respond with something like "Yes, I've seen this problem, and I solved it by setting CSS property foo to bar". (there is a similar bug where some things are not visible even though they should, which can be remedied by setting zoom: 1)
erikkallen
A: 

Althoug I'm not sure, I think I hit this issue

erikkallen