1. 程式人生 > >html基礎之(內容列表元素,內容嵌套元素。。。。。)完結

html基礎之(內容列表元素,內容嵌套元素。。。。。)完結

html

1.內容列表元素

有序列表,無序列表,自定義列表

無序列表<ul><li></li></ul>

有序列表<ol><li</li>></ol> 可以加start="" 在ol裏面加

自定義列表<dl><dt><dd></dd></dt></dl>

列表嵌套 列表裏面還可以添加列表

內容格式化

<pre></pre>可以把想弄出想展示的格式

<p></p>段落與段落的分割線

<blockquote></blockquote>引用其他地方的

<div></div>沒有特別的語義,去做布局排版

2.內容嵌套元素

插入圖片<img src="">

<img src="" alt=“”>alt 如果圖片不存在會顯示alt內容

<img src="" width="" hight="">更改圖片大小像素

<a herf=""><img src=""></a>

插入網頁標簽

<iframe src=""></iframe>

<iframe src="" width="" height="" ></iframe>

<iframe src="" width="" height="" frameborder="0" allowfullscreen=""></iframe>

3.插入一個資源地址

<embed src="" width="" height="" type="插件類型比如flash"></embed>

4.插入圖片映射區域

<img src="" width="" hight="" usemap="#chinamap">

<map name="chinamap"></map>

<area shape="circle" coords="0,0,222" herf="" ></area>

shape=rect (x,y,x,y)

多邊形 polygon (x,y,x,y,x......)

5.插入視頻

視頻封裝格式也就是視頻容器

AVI:可用MPEG-2, DIVX, XVID, WMV3, WMV4, WMV9, H.264

WMV:可用WMV3, WMV4, WMV9

RM/RMVB:可用RV40, RV50, RV60, RM8, RM9, RM10

MOV:可用MPEG-2, MPEG4-ASP(XVID), H.264

MKV:可用所有視頻編碼方案

視頻編解碼

MPEG-2

MPEG-4 Simple Profile

H.264/AVC

AVS

VC-1

視頻元素

<video> src="" width="" height="" ></video>

contorls="contorls" 載入控件

autoplay="true" 自動播放

loop="true" 反復播放

muted=""視頻處於一個靜音狀態

poster=""視頻播放插入的一個圖片

preload 設置後,預先載入視頻

auto 當前頁面加載後載入zhenggeshipin

meta 載入元數據

none 不載入視頻

load 事先加載全部內容

<video controls="controls">

<source src="">

<source src="">

<source src="">

</video>

可以多用幾個格式 防止格式解析不了出錯

音頻跟視頻差不多

不過標簽是<audio></audio>

表格元素

<table style="width:" style="backgroup:">列操作也能達到效果</table>

border="" 建議不用 後期用css

<table>

<tr>

<td>

<td>

<tr>

<tr>

<td>

<td>

<tr>

<tr>

<td>

<td>

<tr>

</table>

<cosplan>合並水平單元格

<td cosplan="幾個單元格填幾">內容</td>

<rowspan>

標準化單元格

<caption>內容</caption> 加入標題

<thead>內容</thead> 表頭無論放在哪都是第一行

<tbody></tbody> 指明數據部分

<tfoot></tfoot>放在最後一行

列操作也可以

<col group>

<col style="backgroup:">

</col group>

註釋與元數據以及全局屬性

<!---->

元數據 不備註

全局屬性(常用的)

class 規定元素的一個或多個類名(引用樣式表中的類)

id 規定元素的唯一 id。

style 規定元素的行內 CSS 樣式。

title 規定有關元素的額外信息。

表單元素

<from></from>

<from name=""></from> 名字

<from name="" method="get,post"></from>提交方式

<from name="" method="get,post" target ="blank"></from>新打開網頁

<from name="" method="get,post" target ="blank" enctype=""></from>

編碼方式默認的就好

<from name="" method="get,post" action=""></from>

提交地址<from>

<input type="test" name="username" value="">

<input type="test" name="usepassword" value="">

<input type="sumbit" name="登陸" value="dossumbit">

</from>

<input></input>標簽

name定義名字標簽

value 定義控件初始值

size空間長度 能顯示的最大字符

maxlength 允許用戶輸入的最大字符

type

1. 提交,重置,普通按鈕

sumbit reset button

2.普通文本框,密碼框

test password

3.單選框和復選框

radio checkbox

4.隱藏框

hidden

<textarea></textarea> 多行文本框

rows 行 cols 列

select菜單下拉

multlple 進度條

fieldest ,legend 表單分組,組合


本文出自 “大李子” 博客,謝絕轉載!

html基礎之(內容列表元素,內容嵌套元素。。。。。)完結