簡單實(shí)用的網(wǎng)頁表格特效 | ||||||||||||||||||||||
| 在我們制作主頁的過程中,用到表格的地方非常多,靈活運(yùn)用表格技巧可以為我們的網(wǎng)頁增色不少,這里我就詳細(xì)介紹幾中特效表格的制作方法。 一、彩色虛線表格 二、鼠標(biāo)指向單元格變色
onmouseout=”this.style.backgroundColor=”” 鼠標(biāo)離開效果onmouseover=”this.style.backgroundColor=’#FFcccc'”鼠標(biāo)放上去的效果, 可以修改#FFcccc的值來改變顏色 <table width=”200″ border=”1″ cellspacing=”0″ cellpadding=”0″> <tr> <td onmouseout=”this.style.backgroundColor=”” onmouseover=”this.style.backgroundColor=’#FFcccc'”>?</td> </tr> <tr> <td onmouseout=”this.style.backgroundColor=”” onmouseover=”this.style.backgroundColor=’#FFccaa'”>?</td> </tr> </table> ? .bg { FILTER: Alpha(Opacity=20); BACKGROUND-COLOR: #66ccff } .tab1 { BORDER-RIGHT: #0099cc thin dotted; BORDER-TOP: #00cc66 thin dotted; BORDER-LEFT: #6699ff thin dotted; BORDER-BOTTOM: #ff0000 thin dotted } 三、立體表格 ?
<table border=”1″ bordercolorlight=”#ffffff” bordercolordark=”#ffffff” width=”200″ cellpadding=”0″ cellspacing=”0″> <tr align=”center”> <td width=”86″ bordercolorlight=”#000000″ bordercolordark=”#eeeeee” bgcolor=”#B7B7B7″ >立體</td> <td width=”108″ bordercolorlight=”#000000″ bordercolordark=”#eeeeee” bgcolor=”#B7B7B7″ >表格</td> </tr> </table> 四、表格嵌套 1、利用表格的間距來做嵌套 <table width=”200″ border=”1″ cellspacing=”4″ cellpadding=”0″> <tr> <td>?</td> <td>?</td> <td>?</td> </tr> </table> 主要是用到間距 cellspacing=”4″
2、充分利用根據(jù)表格對(duì)齊的方式 這里主要是將第一個(gè)表格居左,第二個(gè)表格居右,第三個(gè)表格居中。這樣當(dāng)你隨意調(diào)整里面三個(gè)表格大小的時(shí)候,他們的間距將保持不變,非常方便。
<table width=”200″ border=”1″ cellpadding=”0″ cellspacing=”0″ bordercolor=”#FF0000″> <tr> <td><table width=”60″ border=”1″ align=”left” cellpadding=”0″ cellspacing=”0″> <tr> <td>?</td> </tr> </table> <table width=”60″ border=”1″ align=”right” cellpadding=”0″ cellspacing=”0″> <tr> <td>?</td> </tr> </table> <table width=”80″ border=”1″ align=”center” cellpadding=”0″ cellspacing=”0″> <tr> <td>?</td> </tr> </table></td> </tr> </table> ? .bg { FILTER: Alpha(Opacity=20); BACKGROUND-COLOR: #66ccff } .tab1 { BORDER-RIGHT: #0099cc thin dotted; BORDER-TOP: #00cc66 thin dotted; BORDER-LEFT: #6699ff thin dotted; BORDER-BOTTOM: #ff0000 thin dotted } 五、半透明表格
這里主要是用到了CSS濾鏡filter: Alpha(Opacity=20)。 <style type=”text/css”> <!– .bg { background-color: #66CCFF; filter: Alpha(Opacity=20); } –> <table width=”200″ border=”0″ cellpadding=”0″ cellspacing=”0″ class=”bg”> <tr> <td><div align=”center”>半</div></td> <td><div align=”center”>透明</div></td> </tr> <tr> <td><div align=”center”>表</div></td> <td><div align=”center”>格</div></td> </tr> </table> 六、陰影表格
這里主要用到了CSS濾鏡style=”filter:shadow(color=#cccccc,direction=120);width:300;padding-right:10;padding-bottom:10″ |
簡單實(shí)用的網(wǎng)頁表格特效
簡單實(shí)用的網(wǎng)頁表格特效 在我們制作主頁的過程中,用到表格的地方非常多,靈活運(yùn)用表格技巧可以為我們的網(wǎng)頁增色不少,這里我就詳細(xì)介紹幾中特效表格的制作方法。 一、彩色虛線表格 虛 線 表 格 <style type="text/css"> <!-- .tab1 { border-top-width:
