當前位置:軟件學堂 > 資訊首頁 > 網絡編程 > DIV+CSS > table單元格間距屬性cellspacing

table單元格間距屬性cellspacing

2012/11/20 10:11:32作者:佚名來源:網絡

移動端

【實例介紹】

table單元格間距屬性cellspacing

cellspacing屬性用于設置表格內部每個單元格之間的間距,這樣可以使表格不會顯得過于緊湊。

【基本語法】

<table cellspzcing>

【語法介紹】

單元格間距的單位是像素。

【實例代碼】

<html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>單元格間距屬性</title> </head> <body> <table border="5"align="center"height="100"width="400"cellspacing="5" >   <tr>     <td>單元格1</td>     <td>單元格2</td>   </tr>   <tr>     <td>單元格3</td>     <td>單元格4</td>   </tr> </table> </body> </html>

【代碼分析】

在代碼中,加粗的代碼標記將表格的內框寬度設置為5像素,在瀏覽器中預覽,效果如圖所示。

單元格間距屬性cellspacing運行效果

 【素材及源碼下載】

請點擊:table單元格間距屬性cellspacing 下載本實例相關素材及源碼

 

標簽: table    

欧美一级一极性活片免费观看,欧美一级艳片欧美精品,欧美一级性爱大片,欧美一级囗交视频 视频,欧美一级特黄录像视频