In my javascript method I have this:
if (getInternetExplorerVersion() != '-1') {
alert("IE!");
Ice.Menu.showIt(targCompObject.offsetLeft
+ targCompObject.parentNode.offsetLeft,
targCompObject.offsetTop
+ targCompObject.parentNode.offsetTop, popupMenu,
targComp);
} else {
Ice.Menu.showIt(targCompObject.offsetLeft,
targCompObject.offsetTop, popupMenu, targComp);
}
On FF and Chrome the else part is working fine. On IE, I had to change to calculation so now I have the main if… which is still not good.
Do you know any alternative?
UPDATE: Forgot to mention that for IE, the left is correctly calculated but for top it’s not.
Temporary work-around (ugly of course) is that I have decreased x number of pixels from teh calculation to fit the position where I want the function to display the popup on IE.
Thanks.
There was a div with a margin-top and that was the cause of incorrect left offset calculation for IE.