WordPress.org

Make WordPress Core


Ignore:
Timestamp:
08/19/2019 04:12:44 AM (2 months ago)
Author:
SergeyBiryukov
Message:

Accessibility: Make sure layout tables across the admin are correctly linearized.

Adds role="presentation" to the <table> elements used for layout purposes.

Ideally, HTML tables should be used for tabular data. When tables are used for layout purposes, it's important to remove any native semantics so that assistive technologies can correctly announce the table content in a linearized fashion.

Props greatislander, afercia.
Merges [45403] to the 5.2 branch.
See #46899.

Location:
branches/5.2
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/5.2

  • branches/5.2/src/wp-admin/includes/network.php

    r44460 r45834  
    224224        <p><?php _e( 'You will need a wildcard DNS record if you are going to use the virtual host (sub-domain) functionality.' ); ?></p>
    225225        <?php // @todo: Link to an MS readme? ?>
    226         <table class="form-table">
     226        <table class="form-table" role="presentation">
    227227            <tr>
    228228                <th><label><input type="radio" name="subdomain_install" value="1"<?php checked( $subdomain_install ); ?> /> <?php _e( 'Sub-domains' ); ?></label></th>
     
    273273        ?>
    274274        </p>
    275         <table class="form-table">
     275        <table class="form-table" role="presentation">
    276276            <tr>
    277277            <th scope='row'><?php esc_html_e( 'Server Address' ); ?></th>
     
    290290
    291291        <h3><?php esc_html_e( 'Network Details' ); ?></h3>
    292         <table class="form-table">
     292        <table class="form-table" role="presentation">
    293293        <?php if ( 'localhost' == $hostname ) : ?>
    294294            <tr>
Note: See TracChangeset for help on using the changeset viewer.