Skip to content
SilktideHelp

Cell headers

Silktide checks table cells that name their headings using the headers attribute, and verifies that every ID they reference actually exists. A reference to a missing ID silently breaks the connection between a cell and its heading.

In complex tables, each data cell can carry a headers attribute listing the id values of the heading cells that apply to it. If an ID is mistyped, or the heading it pointed to was renamed or removed, the association quietly stops working.

<!-- Problem: no element with id="prise" exists (typo for "price") -->
<td headers="prise">$40</td>

Why this matters

A uses headers associations to announce the right headings before each value, which is how someone who cannot see the table keeps track of what each number means. When a reference points at nothing, the cell is announced without its context, and the listener has no way of knowing that anything is missing - the table simply becomes harder or impossible to follow.

Broken references usually creep in over time: a heading's id gets renamed, a column is deleted, or a regenerates IDs. Nothing changes visually, so without automated checking nobody notices.

How to fix it

  1. Find the cell's headers attribute and compare each listed ID against the id attributes of the table's heading cells.
  2. Correct any typos, or update the list to the heading's current id.
  3. If a referenced heading no longer exists, remove the stale ID from the list.
  4. If the table is simple - one row or column of headings - consider dropping headers associations entirely and using <th> cells with scope attributes instead, which cannot break this way.
<!-- Fixed: the reference matches a real heading -->
<th id="price">Price</th>
...
<td headers="price">$40</td>

How Silktide tests this

  1. Find every table cell with a headers attribute on each page.
  2. Split the attribute value into individual IDs.
  3. Look up each ID anywhere in the page.
  4. Report each cell that references at least one ID that does not exist.

Troubleshooting

The ID exists but the cell is still reported

Check for exact-match issues: IDs are case-sensitive, so Price and price are different IDs. Also confirm the list is separated by spaces only - commas or other punctuation become part of the ID and break the lookup.

Learn more

Last updated

Was this page helpful?