||View All MessagesBack to WebFX|
I haven't got the faintest idea why the problem ocurred. On my home computer running MSIE 6 SP1 on Winxp there is nothing wrong. On my work (Webdevelopment company) I've tried several machines with also MSIE 6 SP1 on Winxp.
Maybe it has something to do with somekind of Windows update.
What I figured out was, the browser could not get the time to fill the document.body before the height and width was read. I noticed this, because when I used the alert() to figure out the w and h values the menu showed correctly, so it has to do something with not giving the browser the chance to load the content into the popup (so when the scripts asks for w and h, and there is no content yet it returns incorrect values).
I thought a sick and ugly do while loop could give the browser some time to do it's job before requesting the height and width (also odd because do while loops eat away your cpu time resulting in less available cpu time for loading of the content).
What actually is the problem, and why such a dumb solution fixes it, I don't know.
I noticed the contextmenu have a height of 202px when correctly shown, and a height of 192px when shown incorrect. This 10px difference was exact the same as the width value when shown incorrect.
The http://webfx.eae.net/dhtml/dhtmlmenu4/contextdemo.html demo reacted the same. All machines on my work had the bug, my home computer did not.
I also remember some other people posted this "bug" in the webboard in the past.
From: Erik Arvidsson
Sent: Feburary 13, 2003
What problem is it you are trying to solve? Are you using an external CSS file or inline CSS text. All know size errors gets fixed when using CSS text.
The reason for the size errors when using CSS files seems to be that some installations of IE incorrectly caches the CSS file and does not corectly return the readyState. I've never been able to reproduce the bug (except in an early version by disabling the IE cache settting).
To be honest I cannot believe your code works. The preferredHeight will get a value of falseHeight + n * 10. This cannot be right. This will not work in cases where the preferredHeight should be falseHeight + 3 (for example).
It would be interesting to know what browser version and OS version you are using and a test case that shows the bug. I would really like to get a hold of these bugs because as of yet I've not been able to reproduce them.