trourgySmurdy
New Member
I'm having problems with a div within an iFrame, and I've looked at about a dozen posts on this site to no avail. Basically, the content of the iframe has a scrollbar and the Iframe cuts it off. As recommended by posts on this site I have set the height of html and body to some absolute value (170px) because the children use height:100%, but this does not work. I've also tried setting the height of the children to 170px, and this did not work either. The only thing that seems to work is setting the iframe to some number > 230 px. However, I'd prefer the iframe height to remain at 170px.In general, I'm looking for a way to have a two viewports, one title section that does not scroll and one content section that scrolls within an iframe. The content should be displayed with 1 vertical scrollbar to scroll the content section.My code is included below, with theiframe I am using.\[code\]<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /><title>Untitled Document</title></head><body> <iframe src="http://stackoverflow.com/html/scrolling2.html" scrolling="no" style="height:170px"/></body></html><html xmlns="http://www.w3.org/1999/xhtml" ><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /><title>Untitled Document</title><style>html, body { position:absolute; top:0; left:0; border:0; margin:0; padding:0; height:inherit; min-height:inherit;}.parent_div { height:100%; min-height:100%; padding:0px; margin:0px; border:0px}.wrapper_div { margin: 0; padding:0px 0px 0px 3px; width:100%; height:100%; min-height:100%;}.wrapper #title_table .titleHeader_row th.coltitle_cell { border: 1px solid #a7cbe3; border-left: none; font: bold 11px; min-height: 35px; margin: 0; padding: 0; position: relative;}.record_div { margin:0px; width:100%; height:100%; /*need this to take up remaining height not occupied by title_table*/ overflow:auto;}</style></head><body><div class="parent_div" id="listing"> <DIV class="wrapper_div" > <TABLE id="title_table" > <TR > <TH class="coltitle_cell">123 </TH> <TH class="coltitle_cell">123<br/>123 </TH> <TH class="coltitle_cell">123<br/>123<br/>123 </TH> <TH class="coltitle_cell">123<br/>123<br/>123 </TH> <TH class="coltitle_cell">123<br/>123 </TH> <TH class="coltitle_cell">123<br/>123 </TH> <TH class="coltitle_cell">123<br/>123 </TH> <TH class="coltitle_cell">123<br/>123 </TH> <TH class="coltitle_cell">123<br/>123 </TH> </TR> </TABLE> <DIV class="record_div" id="coldata_div" > <TABLE class="record_table" id="coldata_table"> <TR> <TD class="dummy_cell"></TD> <TH >123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123<br/>123 </TH> <TH >123<br/>123<br/>123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123 </TH> </TR> <TR> <TD ></TD> <TH >123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123<br/>123 </TH> <TH >123<br/>123<br/>123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123 </TH> </TR> <TR> <TD ></TD> <TH >123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123<br/>123 </TH> <TH >123<br/>123<br/>123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123 </TH> </TR> <TR> <TD ></TD> <TH >123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123<br/>123 </TH> <TH >123<br/>123<br/>123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123 </TH> </TR> <TR> <TD ></TD> <TH >123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123<br/>123 </TH> <TH >123<br/>123<br/>123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123 </TH> <TH >123<br/>123 </TH> </TR> </TABLE></div></DIV></body></html>\[/code\]