08-19-2005, 11:57 PM
08-20-2005, 12:12 AM
Gecko DOM Reference:
Hope this helps
08-20-2005, 12:18 AM
I just did further debugging and found that IE6 has problem with style.naturalHeight/naturalWidth, I use alert() to output the naturalHeight in IE and it shows "undefined". I did a search online, and people say that naturalWidth/Height work in IE.
Any other way to find image's original width/height? It's because not all the <img> has width or height defined in the html.
08-20-2005, 12:46 AM
I just tried "if(img.complete)" in img.onload, and found that the loading is not complete even though IE already trigger onload function. Weird! Firefox never has that problem.
08-20-2005, 05:25 AM
Another weird thing:
I put the following inside the img.onload function:
it says "complete"!!! So img.complete says "not complete", but readyState says "complete"!
Powered by vBulletin® Version 4.2.2 Copyright © 2017 vBulletin Solutions, Inc. All rights reserved.