A table header is a row, usually at the top of a table, that is styled differently to the other rows. Typically, header rows are where you categorize each column, so that your readers know what information is shown in the table. For example, if you had a table for temperatures over a week, you might have a table header with "Day" in one column, "Min Temp" in the next column, and "Max Temp" in the last column.
When you use the Table Editor to Create a Table, Paligo gives you the option to add a header. But you might create a table without a header and then later decide you need to Add Table Header. Alternatively, you may decide that you need a different type of header, for example, a Turn Cell into Table Header or the Turn Column into Table Header.
The following sections explain the various ways of setting up table headers to meet your requirements.
When you Create a Table you choose whether to add a table header or not. You can add it afterwards as well by using the Table Context Menu.
Caution
Alternatively, you could use the Source Code Editor and manually change cells (td element) into table header cells (th
). But if you take this approach, you need to be careful when changing the start and end tags, otherwise, you could make the XML invalid.
Tip
You can only add one header to a table, but it is possible to Turn Column into Table Header or Turn Cell into Table Header.
To add a header row to an existing table:
-
Select the topic or component in the Content Manager to open it in the Editor.
-
Right-click in the table to display the Table Context Menu.
-
Select Header, footer and title and choose Insert table head.
Paligo adds a table header row to your table.
-
Select Save.
You can make any individual table cell look like a table header cell. This can be useful if you want a complex table where cells inside the table also look like header cells.
Note
Although you can set Paligo to make a table cell look like a table header cell, it is still a regular cell in the structure. It does not change to use the th
element instead of the td
element.
-
Select the topic or component in the Content Manager to open it in the Editor.
-
Select a cell that you want to look like a table header cell.
-
Select the
td
element for the cell in the Element Structure Menu and choose Go to element. -
Add
class
attribute in the Element Attributes Panel. -
Set the value to
tableheader
. -
Repeat steps 2 to 4 for each cell that you want to look like a table header cell.
-
Select Save.
When you publish, Paligo will style the cell in the same way as a table header cell.
You can make the first column of a table look like a table header. This is useful if you want a table with the header running vertically down the side, instead of the standard header row across the top.
To make the first column in a table look like a table header:
-
Select the topic or component in the Content Manager to open it in the Editor.
-
Select a cell in the table.
-
Select the
table
orinformaltable
element and choose Go to element in the Element Structure Menu. -
Add the
tabstyle
attribute and in the Element Attributes Panel. -
Set the value to
rowheader-firstcol
. -
Select Save.
When you publish, Paligo will style the cells in the first column in the same way as table header cells.
Note
If your table already contains a header row, adding a table header column will make it look like it has both vertical and horizontal headers.
To remove the table header row, select any cell in the table header. Select the thead
element in the Element Structure Menu. From the menu, select Cut to remove the thead
element.
Comments
0 comments
Article is closed for comments.