標籤:
Html文檔基本結構
<html><head> <title>Document name goes here</title></head><body> Visible text goes here</body></html>
文本元素
<p>This is a paragraph</p><br /><hr><pre>This text is preformatted</pre><!--此標籤中間的文字的格式以輸入時為準,只用於古詩等的展示-->
特殊含義的文本元素
<!--塊級引用--><blockquote> Text quoted from some source.</blockquote><!--地址--><address> Address 1<br /> Address 2<br /> City<br /></address>
邏輯樣式元素
<em>This text is emphasized</em><strong>This text is strong</strong><code>This is some computer code</code><!--強調程度的排序是strong > em;code用於插入代碼-->
實體樣式元素 (用的比較少,一般使用css代替)
<b>This text is bold</b><i>This text is italic</i>
連結,錨,圖片元素
<!--錨元素--><a href="http://www.example.com/">This is a Link</a><!--用於開啟串連--><a href="http://www.example.com/ss.zip"></a><!--用於下載--><a href="mailto:[email protected]">Send e-mail</a><!--用於發送郵件--><!--命名的錨--><a id="tips">Useful Tips Section</a><a href="#tips">Jump to the Useful Tips Section</a><!--跳轉到id為tips的元素處--><!--圖片元素--><img src="URL" alt="Alternate Text"> <!--如果圖片不能顯示,則顯示alt的值-->
列表
<!--無序列表--><ul> <li>First item</li> <li>Next item</li></ul><!--有序列表--><ol> <li>First item</li> <li>Next item</li></ol><!--自訂欄表--><dl> <dt>First term</dt> <dd>Definition</dd> <dt>Next term</dt> <dd>Definition</dd></dl>
表格
<table border="1"> <tr> <th>someheader</th><!--th標籤中內容預設置中--> <th>someheader</th> </tr> <tr> <td>sometext</td> <!--td標籤中內容預設居左--> <td>sometext</td> </tr></table>
表單
<form action="http://www.example.com/test.asp" method="post/get"> <input type="text" name="lastname" value="Nixon" size="30" maxlength="50"> <input type="password"> <input type="checkbox" checked="checked"> <input type="radio" checked="checked"> <input type="submit"> <input type="reset"> <input type="hidden"> <select> <option>Apples</option> <option selected>Bananas</option> <option>Cherries</option> </select> <textarea name="Comment" rows="60" cols="20"></textarea></form>
實體
< : <
> : >
© : ©Other Elements
HTML 常用標籤錦集