Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-34293

Table headings inside the tbody rather than the thead section

    Details

    • Testing Instructions:
      Hide

      Prerequisite:
      You need firebug or able to see page source.

      Test:
      visit tables on these pages:
      table#modules /admin/modules.php
      table#partipants /user/index.php?id=1
      table.compatibleblockstable /admin/blocks.php

      Make sure first row in the table containing headers should be wrapped in <thead> tags and rest in <tbody>

      Show
      Prerequisite: You need firebug or able to see page source. Test: visit tables on these pages: table#modules /admin/modules.php table#partipants /user/index.php?id=1 table.compatibleblockstable /admin/blocks.php Make sure first row in the table containing headers should be wrapped in <thead> tags and rest in <tbody>
    • Affected Branches:
      MOODLE_23_STABLE
    • Fixed Branches:
      MOODLE_24_STABLE
    • Pull Master Branch:
      wip-mdl-34293

      Description

      Some tables in Moodle put the table heading inside the tbody section rather than the thead. As well as being incorrect, this has at least two pragmatic effects. 1) It makes Moodle harder to theme, 2) it affects accessability.

      Some examples are:

      table#modules /admin/modules.php
      table#partipants /user/index.php?id=1
      table.compatibleblockstable /admin/blocks.php
      table.minicalendar /calendar/view.php?view=month&cal_d=1&cal_m=7&cal_y=2012&course=1

      There might be more, adding the following lines to a theme should highlight the issue as you browse the site, the second line hides a common false positive for vertical tables with headers as the left column:

      table tbody tr th

      {border: thick solid green !important; }

      table tbody tr th:first-child

      {border: none !important;}

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Votes:
                  1 Vote for this issue
                  Watchers:
                  1 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Fix Release Date:
                    3/Dec/12