View Full Version : IE iframe issue

09-12-2009, 10:54 PM
http://www.berrystonework.co.nz/ in IE6 and IE7 when the window size is changed horizontally the iframe content becomes offset. Only happens in IE. Any ideas, has got me stumped? :roll:

09-15-2009, 12:01 AM
Seems like I have stumbled upon the 4th dimension here don't you think?

09-15-2009, 12:12 AM
It appears that the iframe is positioning itself relative to the browser and not the table. I would need to spend some time going through everything to find the culprit and solution.

Question - Why the use of an iframe?
Simple layout. Can be accomplished easily with div's and css.

09-15-2009, 11:00 PM
Hi coloeagle, well the gallery is the main reason and my client didn't really want the code changed only the design. If I can fix the IE issue, well it works so not bothered about changing the system. Search engines index all pages.

I've tried setting backgrounds for all possible backgrounds and it remains white! Will be spending some more time on this later.

09-16-2009, 03:23 AM
Remove the "style="position:relative;" from the iframe tag. This will fix the position issue for ie and has no affect on other browsers.

09-16-2009, 04:30 AM
I put that in to try and fix the issue, forgot to take it out. Well have had a mess about and fixed it. My first thought was, bet it's unfixable issue for iframes in td cell because tables aren't really meant for layout. So I've stuck iframe in a div outside table with position absolute and it works. Lesson here is, don't put iframes in tables.

09-16-2009, 06:54 AM
Lesson here is, don't put iframes in tables.

Nope, lesson is 'don't use tables for layout...full stop.' ;)