Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

absolute positioned DIV height not fully displayed in IE 1

Status
Not open for further replies.

JRBeltman

IS-IT--Management
Feb 5, 2004
290
0
0
NL
Hi,
I'm using the TIGA wordpress theme which uses an 'absolute positioned div' as sidebar.

The problem is that the height of the div is larger than the screen and IE simply cuts the div off. When making it relative IE shows the complete div (full height).

However, I need it absolute.
Anyone knows how to fix this issue and make IE realize that the absolute positioned DIV is larger than the default screen height?

JR (IT = Logic (except for a well known OS where it equals luck) -> Back to the Basics!
 
Code:
<div style='position: relative'>

	<div style='position: absolute; height: 2000px; border: 1px solid black;'>hi</div>


</div>

Try this out in a most simple html file and you will see the issue I'm talking about in IE6 (perhaps also other IE versions)

It is caused by the absolute div being inside the relative one.

JR (IT = Logic (except for a well known OS where it equals luck) -> Back to the Basics!
 
This bug is described at and the fix involves adding a height of 1% for IE6 on the container div e.g.
Code:
/* Hides from IE-mac \*/
* html .container1 {height: 1%;}
/* End hide from IE-mac */


____________________________________________________________
Mark,
[URL unfurl="true"]http://aspnetlibrary.com[/url]

Need help finding an answer? Try the Search Facility or read FAQ222-2244.
 
Simple but elegant and it works!
Cheers for the solution... You got a STAR!

JR (IT = Logic (except for a well known OS where it equals luck) -> Back to the Basics!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top