document.images.length : images « Document « JavaScript Tutorial






The length property contains the number of objects that are in the images[] array.

<html>
    <h2>A Circle</h2>
    <img src="http://www.java2s.com/style/logo.png">
    <h2>A Square</h2>
    <img src="http://www.java2s.com/style/logo.png"><br>
    <script language="JavaScript">
    <!--
    document.write(document.images.length," image objects.");
    -->
    </script>
    </html>








14.15.images
14.15.1.document.images
14.15.2.document.images.length