![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
So, basically this is the problem. I have this... div id="mainframe" img src="image.jpg" id="image" /div Then when I try to in a function say... function checkImage() { var image = document.getElementById("image"); var height = image.height; } -------------- Many times the image height will not be defined. |
|
I recently changed the past so it uses AJAX to change the <img src... stuff to return new data for that inner HTML block.. Still the image will not have properties. Now, this is a problem in IE/FF, but not in opera. Any ideas on how to make sure the image is loaded so its height/width properties are available... either by swapping the image.src or by using ajax to swap out the div innerHTML?? |
#3
| |||
| |||
|
![]() |
| Thread Tools | |
| Display Modes | |
| |