You are here: Reference > JavaScript > client-side > HTML DOM > properties > complete (img, input:image)
complete property (img, input:image)
Returns a Boolean value that indicates whether the loading of an element is finished or not.
The onload event can be used to receive a notification when the loading process is completed.
Syntax:
You can find the related objects in the Supported by objects section below.
This property is read-only.
Possible values:
Boolean that indicates the state of loading.
One of the following values:
The loading is not finished yet. | |||||||
The loading is finished. |
Default: false.
Example HTML code 1:
This example shows how to use complete property:
|
||||
<head> <script type="text/javascript"> function OnLoadImage (img) { var isComplete = img.complete; alert(isComplete); } </script> </head> <body> <img src="picture.gif" onload="OnLoadImage (this);" /> </body> |
||||
|
||||
Did you find this example helpful?
|
Supported by objects:
HTML elements:
Related pages:
External links:
User Contributed Comments