关于document

来源:互联网 发布:手机验钞机软件2016 编辑:程序博客网 时间:2024/05/21 10:15

在document中取值方式,一直取,也一直记不住怎么取,主要知其然还不知其所以然。现在好好静下心想了想,感觉应该是这样,我认为其然也,而不知其是否然也。

1.document.operform.elements["cifcorpinf.cifno"].value;

2.document.getElementById("CIFNO").value;

3.document.operform.elements['cifcorpinf.cifno'].getAttribute("value")

其中valueform中一个element的attribute.

你也可有以同样得到其中的maxlength  name 等属性值