From 8389eae2e503bad92dfb8ea3f55df8d8b2c5abc9 Mon Sep 17 00:00:00 2001 From: Dan Helfman Date: Sun, 18 May 2008 01:43:20 -0700 Subject: [PATCH] Expanded workaround for IE iframe positioning bug to include IE 7 and not just 6. --- static/js/Wiki.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/static/js/Wiki.js b/static/js/Wiki.js index c362e3e..f681bc7 100644 --- a/static/js/Wiki.js +++ b/static/js/Wiki.js @@ -2255,9 +2255,8 @@ function calculate_position( anchor, relative_to ) { position.y += relative_pos.y; // Work around an IE "feature" in which an element within an iframe changes its absolute - // position based on how far the page is scrolled. The if is necessary to prevent this - // workaround from screwing positions up in sane browsers like Firefox. - if ( getStyle( "content", "position" ) == "absolute" ) + // position based on how far the page is scrolled. + if ( /MSIE/.test( navigator.userAgent ) ) position.y -= getElement( "html" ).scrollTop; }