PDA

Click to See Complete Forum and Search --> : IE 6 ti IE 7 - sizing problems



Dan Abz
01-17-2007, 12:48 PM
Hi!

Just wondering if anyone has came across a problem the page resizing itself?

In IE 6 the page sits normal with a graphic to clicking out to some text.

In IE 7 the page either sits with the graphic half showing and you need to scroll to see the rest of it even though 75% of the page is visible and the text is all underneath each other as if there is no <br> or line spacing.

Any help would be great.

Cheers
Dan

catbert303
01-17-2007, 03:28 PM
Do you have a link to the page? What do Firefox or Opera do?

Dan Abz
01-18-2007, 04:45 AM
Sorry I don't have a link and I don't have Firefox or Opera available here.
It must be one of the bugs/quirks mode that isn't in IE7.

I also thinking it could be something to do with the iframe.

This is the iframe code

<iframe scrolling="Auto" frameborder="0" width="100%" height="100%" id="forpdf" name="forpdf" src="instructions.html">hello and welcoome to the doobery showcase vor over sea stuff</iframe>

Or the java script:

<script type="text/javascript">

function resizeIframe() {
parent.document.getElementById('forpdf').style.hei ght= document.getElementById('container').offsetHeight+ 0+'px';
}
function pdfload (varpdf){
//alert("Hi");
//alert ("iframe= "+parent.screenHeight);
parent.document.getElementById('forpdf').style.hei ght= parent.screenHeight;
document.location = varpdf;
}
function expandIt(getIt){
parent.document.getElementById('forpdf').style.hei ght= parent.screenHeight;
getIt.style.display=(getIt.style.display=="none")?"":"none";
}

onload=resizeIframe; pdfload("../documents/Hydraulics.pdf");

</script>


Really annoying as this is the 2nd site thats went tits up in IE7 which was fine in IE6.

keyone.it
01-21-2007, 09:47 AM
I think you did this only while posting here, but if you give a look at your code, everywhere you are setting the style.height property, height is miss-writter "hei ght".


It's difficult to understand what's the problem without a live example that can be tested with all the browsers.

What I can say though is that, unless it is really necessary, style should not be defined through JavaScript.
CSS is there for that, and is easier to make cross-platform.

When dealing with CSS hacks and IE7 keep in mind that in most cases IE7 will need the same CSS fixes as IE6, but will not be fooled by the IE6 hacks.
This means that while IE7 needs IE6 instructions, it will read the instructions you put for all other browsers, thus breaking your page.

The only all-working solution is using Conditional Comments in the page inline, to load specific CSS files for Other Browsers, IE5+, IE6 and IE7.