欢迎来到DIVCSS5查找CSS资料与学习DIV CSS布局技术!
  <thead>标签定义及用法
 
  1、在html中,<thead>标签是用来组合html表格的表头内容,通常与<tbody>标签和<tfoot>标签一起使用,分别用来定义表格的表头、主体和页脚。
 
  2、<thead>标签必须是<table>标签元素的子元素,应用在<caption>标签、<colgroup>标签之后,<tbody>和<tfoot>标签之前。
 
  3、<thead>标签、<tbody>标签和<tfoot>标签默认情况下不会影响表格的布局,通常使用css来定义表格的样式。
 
  <thead>标签基本属性(html5已经不支持)
 
  alignright:<thead>元素中内容的对齐方式(值:left、center、justify、char)。
 
  char:<thead>元素中内容根据哪个字符来对进行文本对齐(值:character)。
 
  charoff:<thead>元素中内容的第一个对齐字符的偏移量(值:number)。
 
  valign:<thead>元素中内容的垂直对齐方式(值:top、middle、bottom、baseline)。
 
  <thead>标签支持html全局属性和html事件属性
 
  格式
 
  <thead>
 
  <tr>
 
  <td>......</td>
 
  </tr>
 
  ......
 
  </thead>
 
  实例
 
  
 
  
 
  <!doctypehtml>
 
  <html>
 
  <head>
 
  <metacharset="UTF-8">
 
  <title>html<tbody>标签笔记</title>
 
  </head>
 
  <body>
 
  <tableborder="1">
 
  <thead>
 
  <tr>
 
  <th>thead1</th>
 
  <th>thead2</th>
 
  <th>thead3</th>
 
  </tr>
 
  </thead>
 
  <tfoot>
 
  <tr>
 
  <td>tfoot1</td>
 
  <td>tfoot2</td>
 
  <td>tfoot3</td>
 
  </tr>
 
  </tfoot>
 
  <tbody>
 
  <tr>
 
  <td>tbody1</td>
 
  <td>tbody2</td>
 
  <td>tbody3</td>
 
  </tr>
 
  </tbody>
 
  </table>
 
  </body>
 
  </html>




本文转载自中文网


 

如需转载,请注明文章出处和来源网址:http://www.divcss5.com/html/h53945.shtml