表单的运用

<iframe>内嵌框架
语法 <iframe src="URL" name="框架名">......</iframe>
scrolling(是否显示滚动条) yes(显示) no(不显示)auto(自动)
frameborder(是否显示边框)1(显示)0(不显示)

form(表单)
基本结构 <form name="form1" action="URL" method="get">
用户名:<input type="text" name="uname"/>
密码:<input type="password" name="password"/>
</form>

name(名字) action(表单提交地址) target(打开方式)
method(表单数据提交的方式(get公开)(post保密)) enctype(MIME类型)

<input>(表单元素:输入框)
type(类型) value(值) size(宽度) readonly(是否只读)
maxlength(输入字符的最大长度) disabled(是否禁用)

在<input>中,type的不同就有不同的框
type="text"(文本框) text="password"(密码框)
type="radio"(单选) type="checkbox"(复选)
type="button"(确定按钮) type="submit"(提交按钮)
type="reset"(重写按钮) type="image"(图片按钮)
PS:checked表示默认选中,要注意当type="radio",也就是单选时,name的值要一致。

原文地址:https://www.cnblogs.com/feng17176/p/5736162.html