<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <title>表单相关标签</title> </head> <body> <form action="" method="get"> 单行文本框:<input type="text" name="userName" id="userName" /><br /> 不能编辑的文本框:<input type="text" name="userName1" id="userName1" readonly="readonly" /><br /> 密码框:<input type="password" name="passWord" id="passWord" /><br /> 隐藏域:<input type="hidden" name="linkin_id" id="linkin_id" /><br /> 单选:<input type="radio" name="age" id="age1" value="男" />男 <input type="radio" name="age" id="age2" value="女" />女<br /> 多选:<input type="checkbox" name="age1" id="age3" value="男" />男 <input type="checkbox" name="age1" id="age4" value="女" />女<br /> 文件上传域:<input type="file" /><br /> 图像域:<input type="image" src="" /><br /> 4个按钮: <input type="submit" value="提交" name="button1" /> <input type="submit" value="提交" name="button2" disabled="disabled" /> <input type="reset" value="重置" name="button3" /> <input type="button" value="无动作" name="button4" /> </form> </body> </html>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <title>下拉相关标签</title> </head> <body> <form action="" method="get"> 下拉: <select> <option value="LinkinPark">林肯</option> <option value="NightWish">夜愿</option> </select> 列表框1: <select multiple="multiple"> <option value="LinkinPark">林肯</option> <option value="NightWish">夜愿</option> </select> 列表框2: <select multiple="multiple"size="10"> <optgroup label="名字"> <option value="LinkinPark">林肯</option> <option value="NightWish">夜愿</option> </optgroup> <optgroup label="国家"> <option value="LinkinPark">美国</option> <option value="NightWish">芬兰</option> </optgroup> </select> </form> </body> </html>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <title>多行文本框相关标签</title> </head> <body> <form action="" method="get"> 单行文本框:<input type="text" size="20" height="20" /><br /> 多行文本框:<textarea rows="10" cols="20"></textarea> </form> </body> </html>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <title>label相关标签</title> </head> <body> <form action="" method="get"> <label for="huhu">单行文本框:</label> <input type="text" size="20" height="20" id="huhu" /><br /> <label>多行文本框:<textarea rows="10" cols="20"></textarea></label> </form> </body> </html>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <title>button相关标签</title> </head> <body> <form action="" method="get"> <button type="submit" ><img alt="huhu" src="img/NightWish.jpg" /></button> </form> </body> </html>
原文地址:http://blog.csdn.net/u011794238/article/details/45394795