/*
>>> Title : html的一些基本标签
>>> Author: 刘晨晖
>>> Date : 2009-07-04
>>> EMAIL : huichengongzi@gmail.com
>>> 转载请注明出处,谢谢合作!
*/
1. 链接
<p>
This is a text: <a href ="http://www.baidu.com"> 百度 </a>is a link to 百度。
</p>
2. 图片链接
<p>
You can also use an photo as a link:
<a href="http://www.baidu.com">
<img border="0" src ="breed.jpg"> //src 是图片文件 breed.jpg 的路径
</a>
</p>
3. 在一个新的窗口打开
<a href="http://www.w3schools.com/" target="_blank">Visit W3Schools!
</a>
4. 垂直分栏
<html>
<frameset cols="25%,50%,25%">
<frame src="http://www.baidu.com">
<frame src="http://www.google.cn">
<frame src="http://192.168.29.128">
</frameset>
</html>
5. 水平分栏
<html>
<frameset rows="25%,50%,25%">
<frame src="http://www.baidu.com">
<frame src="http://www.google">
<frame src="http://192.168.29.128">
</frameset>
</html>
6. 表格
<table bordet="1"> <table> 创建表格
<th>Heading</th>
<tr> 行 </tr>
<td> 表格中的数据 </td>
<caption> 表格的标题 </caption>
<th colspan="2">Telephone</th>
--------Telephone 占两个单元格(行)
<th rowspan="2">Telephone:</th>
--------Telephone 占两个单元格(列)
<ul>
<li>apples</li>
<li>bananas</li>
<li>pineapples</li>
</ul>
----------------- 无序表
DIV 是层的标记 , 相当于一个区域块 . 这个比 table 要好 , 可以准确的定位比例
cellpadding 为表格的埴充 ;
<table border="1" cellpadding="100">
cellspacing 为表格的间距 ;
<table border="1" cellspacing="100">
给表格增加背景色或者背景图像:
<table border="1" bgcolor="red">
<h4>A background image:</h4>
<table border="1" background="Vista_ 黑夜精灵 .jpg">
给单元格增加背景
<td bgcolor="red">First</td>
给单元格内容设置对齐方式:
<html>
<body>
<table width="400" border="1">
<tr>
<th align="left">Money spent on....</th>
<th align="right">January</th>
<th align="right">February</th>
</tr>
<tr>
<td align="left">Clothes</td>
<td align="right">$241.10</td>
<td align="right">$50.20</td>
</tr>
<tr>
<td align="left">Make-Up</td>
<td align="right">$30.00</td>
<td align="right">$44.45</td>
</tr>
<tr>
<td align="left">Food</td>
<td align="right">$730.40</td>
<td align="right">$650.00</td>
</tr>
<tr>
<th align="left">Sum</th>
<th align="right">$1001.50</th>
<th align="right">$744.65</th>
</tr>
</table>
</body>
</html>