用户提交数据提交数据的两个要素:数据名称+数据的值action要把数据提交到哪里,接收的地址input决定input显示什么的,不是input本身而是type属性form是块级元素block elementinput是内联标签 inline-block element<form method="get|post" action="url"><input><input type="text"><input type="password"></form>
<form method="get" action=""><p>用户名:<input type="text"></p><p>密码:<input type="password" id="password1"></p><p><input type="submit" value="登录"></p></form>
点击显示,数据提交.html?
<form method="get" action=""><p>用户名:<input type="text" name="username"></p><p>密码:<input type="password" id="password1" name="password"></p><p><input type="submit" value="登录" ></p></form>
点击显示,数据提交.html?username=&password=
label
内联元素
<label for="">123</label>123

<form action="get" action=""><label for="username">用户名</label><input type="text" id="username" name="username"></form>

label的for属性值与某一个input的id值相同时,点击label可以聚集给input输入框
<form action="get" action=""><label for="username">用户名</label><input type="text" id="username" name="username"><br><label for="password">密码</label><input type="password" id="password" name="password"><br>密码用md5保存什么是md5:消息摘要的算法,不可逆加密算法,只要加了密,不能再解密,这种方式不用提供密钥</form>
<form action="get" action=""><label for="username">用户名</label><input type="text" id="username" name="username" readonly="readonly" value="123"disabled="disabled"><br><label for="password">密码</label><input type="password" id="password" name="password"><br></form>

<form action="get" action=""><label for="username">用户名</label><input type="text" id="username" name="username" value="1234"disabled="disabled"><br><label for="password">密码</label><input type="text" id="password" name="password" value="123" readonly="readonly"><br><input type="submit" value="提交"></form>
数据提交表单/get?password=123
readyonly只读,表单提交提交出去
disabled禁用,表单提交不提交被禁用的数据
单选
<form method="get" action=""><input type="radio" id="male" checked="checked"><label for="male">男士</label><input type="radio" id="female"><label for="female">女士</label></form>

<form method="get" action=""><input type="radio" id="male" checked="checked" name="sex"><label for="male">男士</label><input type="radio" id="female" name="sex"><label for="female">女士</label></form>

<form method="get" action=""><input type="radio"id="male"checked="checked"name="sex"value="male"><label for="male">男士</label><input type="radio"id="female"name="sex"value="female"><label for="female">女士</label><br><input type="submit"></form>
同一个name就可以多选一,通过名字区分,发给服务器得发数据名称:数据集的值,这是一一对应的
<form action="" method="get"><select name="lang" id=""><option value="">请选择</option><option value="js">JavaScript</option><option value="java">JAVA</option><option value="php">PHP</option><option value="python">Python</option></select><br><input type="submit" value="提交"></form>
