Unexpected "Tables ideally should not be missing headers."

Unexpected "Tables ideally should not be missing headers."

by John Percival -
Number of replies: 8

I am getting a "Tables ideally should not be missing headers." from the Brickfield Accessibility tool.

Here is the errant HTML

<table border="1" cellspacing="0" cellpadding="0" class="generaltable">
    <thead>
        <tr>
            <th width="157" class="header" scope="col">
                Type of Assessment
            </th>
            <th width="157" class="header" scope="col">
                Name of Assessment or Exam
            </th>
            <th width="148" class="header" scope="col">
                Percentage of total assessment scheme
            </th>
            <th width="153" class="header" scope="col">
                Relevant TLOs
            </th>
        </tr>
    </thead>
    <tbody>
        <tr>
            <td width="157">
                Summative
            </td>
            <td width="157">
                Assessed Talk
            </td>
            <td width="148">
                40%
            </td>
            <td width="153">
                TLO 3
            </td>
        </tr>
        <tr>
            <td width="157">
                Summative
            </td>
            <td width="157">
                Written event plan and rationale
            </td>
            <td width="148">
                60%
            </td>
            <td width="153">
                TLOs 1, 2, 4
            </td>
        </tr>
    </tbody>
</table>

Can anyone help me understand why it is generating this error please, as I have thead and th elements.

Thanks

Average of ratings: -
In reply to John Percival

Re: Unexpected "Tables ideally should not be missing headers."

by Brickfield Education Labs -
Picture of Core developers Picture of Plugin developers
Hi John, many thanks for your interest in our Accessibility toolkit and how it works!

For your table code, I've tested this in a number of Moodle sites, including the Moodle sandbox demo and it is not triggering the error for the check "Tables ideally should not be missing headers.". I analysed a page with multiple typical errors, and your HTML code, but there were no table errors found, just the others.

Would it be possible for you to make a module backup of whichever course resource you have the HTML saved in, then we could test it by restoring and seeing what the issue might be? I'll message you our support email separately.

Many thanks, Karen
Attachment sandbox_demo.png
Average of ratings: Useful (1)
In reply to Brickfield Education Labs

Re: Unexpected "Tables ideally should not be missing headers."

by John Percival -
Thanks so much for the reply, Karen. I've just sent you an email. The problem occurs in a Section summary and two assignment description fields. John
In reply to Brickfield Education Labs

Re: Unexpected "Tables ideally should not be missing headers."

by John Percival -
Hello, did anyone get a chance to look at the course backup I sent? The error is still showing at our end. Many thanks!
In reply to John Percival

Re: Unexpected "Tables ideally should not be missing headers."

by John Percival -
I've been informed of one of our scheduled tasks producing a PHP warning:
PHP Notice: Undefined offset: 0 in
/srv/vle.oakhill.ac.uk/public/htdocs/admin/tool/brickfield/classes/manager.php
on line 386
Could this be related?
In reply to John Percival

Re: Unexpected "Tables ideally should not be missing headers."

by Karen Holland -
Picture of Core developers Picture of Plugin developers Picture of Testers
Hi John, just to confirm, we are still working on this, using your course backup, and are trying to identify exactly where this is misbehaving. Thanks for your patience! Karen
In reply to John Percival

Re: Unexpected "Tables ideally should not be missing headers."

by Mike Churchward -
Picture of Core developers Picture of Plugin developers Picture of Testers

I believe we have a working solution. I have created MDL-75724 to track the progress.

In reply to Mike Churchward

Re: Unexpected "Tables ideally should not be missing headers."

by John Percival -

Many thanks, I'll watch there.

J

In reply to John Percival

Re: Unexpected "Tables ideally should not be missing headers."

by Karen Holland -
Picture of Core developers Picture of Plugin developers Picture of Testers
Hi John, we have now submitted code via Tracker MDL-75724 to fix this table header check as requested!

If you'd like to review its details and even vote for it, that will show its benefits for those doing peer reviewing, to hopefully get it approved and integrated into the next Moodle minor release.