html常用的知识点以及混合框架

html中:
 
<hr/> 在页面中创建水平线
例如:

 
<p> p标签是定义段落
 
>
alt 作为可预备可替换信息,在无法加载图片时显示文字信息
 
定义html表格
<table>定义表格
<caption>定义表格标题。
<th>定义表格的表头。
<tr>定义表格的行。
<td>定义表格单元。
<thead>定义表格的页眉。
<tbody>定义表格的主体。
<tfoot>定义表格的页脚。
<col>定义用于表格列的属性。
<colgroup>定义表格列的组。
 
Table with frame="box":四周边框
MonthSavings
January$100
Table with frame="above":上边框线
MonthSavings
January$100
Table with frame="below":下边框线
MonthSavings
January$100
Table with frame="hsides":上下边框线
MonthSavings
January$100
Table with frame="vsides":左右边框线
MonthSavings
January$100
 
使用 HTML5 的网站布局
header定义文档或节的页眉
nav定义导航链接的容器
section定义文档中的节
article定义独立的自包含文章
aside定义内容之外的内容(比如侧栏)
footer定义文档或节的页脚
details定义额外的细节
summary定义 details 元素的标题
HTML框架
 
<html>
 
<frameset rows="25%,50%,25%">
 
<frame src="/example/html/frame_a.html">
<frame src="/example/html/frame_b.html">
<frame src="/example/html/frame_c.html">
 
</frameset>
 
</html>
<html>
 
<frameset cols="25%,50%,25%">
<frame src="/example/html/frame_a.html">
<frame src="/example/html/frame_b.html">
<frame src="/example/html/frame_c.html">
 
<noframes>
<body>您的浏览器无法处理框架!</body>
</noframes>
 
</frameset>
 
</html>
 
混合框架结构
<html>
 
<frameset rows="50%,50%">
 
<frame src="/example/html/frame_a.html">
noresize="noresize"
<frameset cols="25%,75%">
<frame src="/example/html/frame_b.html"> <frame src="/example/html/frame_b.html" noresize="noresize">
<frame src="/example/html/frame_c.html"> 加入noresize="noresize"框架不可移动改变大小
</frameset>
 
</frameset>
 
</html>
 
A2DDD1ACEE784E2E880D8791544C1090
 
导航框架
 
<html>
 
<frameset cols="120,*">
 
<frame src="/example/html/ html_contents.html">
<frame src="/example/html/frame_a.html" name="showframe">
 
</frameset>
 
</html>
内联框架
<html>
 
<body>
 
<iframe src="/i/eg_landscape.jpg"></iframe>
 
<p>一些老的浏览器不支持 iframe。</p>
<p>如果得不到支持,iframe 是不可见的。</p>
 
 
</body>
</html>
AD432EECCEF944529C37DB4844A14B36
 
内联框架iframe
 
添加 iframe 的语法
URLIframe - 设置高度和宽度
实例
 
 
Iframe - 删除边框
实例
 
 
<!DOCTYPE html>
<html>
<body>
 
<iframe src="/example/html/demo_iframe.html" name="iframe_a"></iframe>
 
<p><a href="http://www.w3school.com.cn" target="iframe_a">W3School.com.cn</a></p>
 
<p><b>注释:</b>由于链接的目标匹配 iframe 的名称,所以链接会在 iframe 中打开。</p>
 
</body>
9BFFB48FC89E46E38FA49877B0E0E0AA
 
 
<noscript> 标签
Your browser does not support JavaScript!
HTML实体名
HTML 中有用的字符实体
注释:
显示结果描述实体名称实体编号
 空格&nbsp;&#160;
<小于号&lt;&#60;
>大于号&gt;&#62;
&和号&amp;&#38;
"引号&quot;&#34;
'撇号&apos; (IE不支持)&#39;
分(cent)&cent;&#162;
£镑(pound)&pound;&#163;
¥元(yen)&yen;&#165;
欧元(euro)&euro;&#8364;
§小节&sect;&#167;
©版权(copyright)&copy;&#169;
®注册商标&reg;&#174;
商标&trade;&#8482;
×乘号&times;&#215;
÷   
 
html中颜色名
 
 
HTML5 表单元素
 
HTML5 <datalist> 元素
listid 实例
 
 
17330A07574D49B49BDC4DA734353A0C
 
 
<input type="password">密码字段
输入限制
属性描述
disabled规定输入字段应该被禁用。
max规定输入字段的最大值。
maxlength规定输入字段的最大字符数。
min规定输入字段的最小值。
pattern规定通过其检查输入值的正则表达式。
readonly规定输入字段为只读(无法修改)。
required规定输入字段是必需的(必需填写)。
size规定输入字段的宽度(以字符计)。
step规定输入字段的合法数字间隔。
value规定输入字段的默认值。
 
type=date
 
<form action="action_page.php">
Birthday:
<input type="date" name="bday">
</form>
526E08FDB6134813812741A5548B7D7D
 
 
可以输入添加限制
 
<form action="action_page.php">
Enter a date before 1980-01-01:<br>
<input type="date" name="bday" max="1979-12-31"><br><br>
Enter a date after 2000-01-01:<br>
<input type="date" name="bday" min="2000-01-02"><br><br>
<input type="submit">
</form>
 
常见的输入
输入类型:range
<input type="range">实例
<form> <input type="range" name="points" min="0" max="10"> </form>
输入类型:month
<input type="month">实例
<form> Birthday (month and year): <input type="month" name="bdaymonth"> </form>
输入类型:week
<input type="week">实例
<form> Select a week: <input type="week" name="week_year"> </form>
输入类型:time
<input type="time">实例
<form> Select a time: <input type="time" name="usr_time"> </form>
输入类型:datetime
<input type="datetime">实例
<form> Birthday (date and time): <input type="datetime" name="bdaytime"> </form>
输入类型:datetime-local
<input type="datetime-local">实例
<form> Birthday (date and time): <input type="datetime-local" name="bdaytime"> </form>
输入类型:email
<input type="email">实例
<form> E-mail: <input type="email" name="email"> </form>
输入类型:search
<input type="search">实例
<form> Search Google: <input type="search" name="googlesearch"> </form>
输入类型:tel
<input type="tel">实例
<form> Telephone: <input type="tel" name="usrtel"> </form>
输入类型:url
<input type="url">实例
<form> Add your homepage: <input type="url" name="homepage"> </form>
 
 
 
readonly 属性
readonly
disabled 属性
disabled
maxlength 属性
maxlength实例
 
 
autocomplete 属性
 
autofocus 属性 页面加载自动获得焦点
 
form 属性
实例
 
 
formaction 属性
实例
 
 
height 和 width 属性仅用于 <input type="image">。
实例
 
 
multiple 属性
实例
 
 
pattern 属性
<form action="/example/html5/demo_form.asp" method="get">
国家代码:<input type="text" name="country_code" pattern="[A-z]{3}"
title="三个字母的国家代码" />
<input type="submit" />
</form>
 
placeholder 属性
实例
 
required 属性
 
step 属性
示例
 
HTML5 浏览器支持
 
 
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值