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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

div height 100%

Status
Not open for further replies.

thysonj

Programmer
Jul 6, 2001
240
US
I am new with CSS layout and can't for the life of me figure this out. I think it is pretty basic though.

All I want is a page that will expand to the height of the browser. I have a 100 px banner at the top and everything underneathe should fill the page to the bottom.
Code:
<div style="width:100%;height:100%;margin:0 auto;">
	<div style="background-image:url(images/banner.jpg);width:100%;height:100;"></div>
	<div style="border:solid black 1px;width:100%;height:100%;text-align:center;clear:both;">
		<div style="border:solid black 1px;width:95%;height:100%;position:relative;top:0;left:0;"></div>
	</div>
</div>

This doesn't do it since the lowest div simply expands to 100% of the browser and not 100% of the available browser space underneath the banner.
 
This was discussed the other day in this thread: thread215-1415440.

Greg
"Personally, I am always ready to learn, although I do not always like being taught." - Winston Churchill
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top