form表单元素的自定义属性 CreateTime--2016年9月22日09:03:40 Author:Marydon 场景: <script type="text/javascript"> var name = "lisi"; function test1 () { var name = "zhang"; function test2 () { console.log(this.name); } alert(name); //…
Form表单元素 action method input: name value type: text password button radio checkbox file submit reset select下拉选择: name option textarea文本域: name cols rows form表单:用于搜集用户输入的数据并传递给指定后台程序进行处理 action:指定后台处理程序的地址 method:数据提交的方法 get:默认的提交方法,数据会附加在地址上…
1.当输入用户名和密码为空的时候,需要判断.这时候就用到了校验用户名和密码,这个需要在jsp的前端页面写:有两种方法,一种是用submit提交.一种是用button提交.方法一: 在jsp的前端页面的头部插入一个js方法: function checkUser(){ var result = document.getElementById("userid").value; var password = document.getElementById("userpassid&q…