Close this window

Using the <tgroup> tag

Description

The tgroup tag identifies a new portion of a table.

Example

This CNXML:


<table frame="all" id="budgettable1">
  <name>Budget - Comparison by year</name>
  <tgroup cols="4" align="left" colsep="1" 
	  rowsep="1">
    <colspec colnum="1" colname="c1"/>
    <colspec colnum="2" colname="c2"/>
    <colspec colnum="3" colname="c3"/>
    <colspec colnum="4" colname="c4"/>
    <thead valign="top">
      <row>
	<entry morerows="1" 
	       align="center">Item</entry>
	<entry namest="c2" nameend="c4" 
	       align="center">Year</entry>
      </row>
      <row>
	<entry align="center">1998</entry>
	<entry align="center">1999</entry>
	<entry align="center">2000</entry>
      </row>
    </thead>
    <tbody valign="top">
      <row>
	<entry>Income</entry>
	<entry>12,293</entry>
	<entry>12,398</entry>
	<entry>14,298</entry>
      </row>
      <row>
	<entry>Expenditure</entry>
	<entry>293</entry>
	<entry>398</entry>
	<entry>298</entry>
      </row>
      <row>
	<entry>Surplus</entry>
	<entry>12000</entry>
	<entry>12000</entry>
	<entry>14000</entry>
      </row>
    </tbody>
  </tgroup>
</table>
	

Results in this display:

Budget - Comparison by year
Item Year
1998 1999 2000
Income 12,293 12,398 14,298
Expenditure 293 398 298
Surplus 12000 12000 14000

Attributes(what's this?)

Children(what's this?)

colspec (zero or more), spanspec (zero or more), thead (zero or one), tfoot (zero or one), tbody (one, required)

Parents(what's this?)

table

Close this window