html的DOM中document对象forms集合用法实例
2015-01-21 00:00
746 查看
本文实例讲述了html的DOM中document对象forms集合用法。分享给大家供大家参考。具体分析如下:
forms 集合可返回对文档中所有 Form 对象的引用。
语法:
例子:
希望本文所述对大家的javascript程序设计有所帮助。
forms 集合可返回对文档中所有 Form 对象的引用。
语法:
document.forms[]
例子:
<html> <body> <form name="Form1"></form> <form name="Form2"></form> <form name="Form3"></form> <script type="text/javascript"> document.write("This document contains: ") document.write(document.forms.length + " forms.") </script> </body> </html>
希望本文所述对大家的javascript程序设计有所帮助。
相关文章推荐
- html的DOM中document对象forms集合用法实例
- html的DOM中document对象anchors集合用法实例
- html的DOM中document对象anchors集合用法实例
- html的DOM中document对象images集合用法实例
- html的DOM中document对象images集合用法实例
- JavaScript HTML DOM节点类型之Document类型(Document对象属性和Document对象集合属性)
- javascript-第八节-DOM对象实例集合
- HTML DOM Document 对象(转自w3cSchool)
- HTML DOM Document 对象
- html的DOM中Event对象onabort事件用法实例
- HTML DOM Document 对象
- javaScript学习之HTML DOM Document对象
- HTML DOM Document 对象
- HTML DOM Document 对象
- HTML DOM Document 对象
- JavaScript入门<3>JS外置对象:HTML DOM与Window子对象实例详解
- html的DOM中Event对象onblur事件用法实例
- html的DOM中Event对象onabort事件用法实例
- document.querySelector获取不到html标签对象实例的原因
- JavaScript入门<3>JS外置对象:Window、Document对象与DOM实例详解