FYI:

I have written my own t:popup for use by my company that has more
functionality that t:popup and is customized for our use.

While I was using this I found a location in my code where the popup
didn't open where it was supposed to. After some research I found that
IE has a nice bug with the calculation of offsetTop with a TABLE
element.

My method:

1) calculate the DIV's X & Y co-ordinates on the screen
2) move the DIV to the document.body
3) re-position the DIV to the original X & Y co-ordinates

The reason I do this is so that if the popup is in a child element, it
won't be restricted to the parent. Once it is a direct child of the
BODY, it is able to be seen anywhere on the page.

What I have found is that IE incorrectly adds the offsetTop of the
TD/TH to the calculation of the offsetTop of its children (the problem
is that it isn't always broken, some times -- and I can't figure out
when -- the offsetTop in a TABLE somehow works). Resulting in an
almost double value of the offsetTop property.

I have opened a case with Microsoft to get a work around for this.
There is a patch for the bug:

http://support.microsoft.com/kb/811808

There is no work around (that is what the case is for).

I am not sure if this would affect t:popup or not (or other Tomahawk
controls). I will post the results and any JavaScript that would apply
if people are interested if Microsoft ever gets back to me with a good
solution.

-Andrew

Reply via email to