Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
06/22/2017 08:09:27 PM (2 years ago)
Author:
djpaul
Message:

HTML <a> elements should never have title attributes.

Accessible support is too inconsistent across software and platforms.
In a small number of places (mainly legacy templates) where the link text was a meaningless value, the attribute was swapped out for aria-label, which reliably overides the link text readout.

Props rianrietveld

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-groups/bp-groups-notifications.php

    r11557 r11606  
    394394                     * @param string $notification_link The permalink for notification.
    395395                     */
    396                     return apply_filters( 'bp_groups_' . $amount . '_' . $action . 's_notification', '<a href="' . $notification_link . '" title="' . __( 'Group Membership Requests', 'buddypress' ) . '">' . $text . '</a>', $group_link, $total_items, $group->name, $text, $notification_link );
     396                    return apply_filters( 'bp_groups_' . $amount . '_' . $action . 's_notification', '<a href="' . $notification_link . '">' . $text . '</a>', $group_link, $total_items, $group->name, $text, $notification_link );
    397397                } else {
    398398
     
    492492                     * @param string $notification_link The permalink for notification.
    493493                     */
    494                     return apply_filters( 'bp_groups_' . $amount . '_' . $action . '_notification', '<a href="' . $notification_link . '" title="' . __( 'Groups', 'buddypress' ) . '">' . $text . '</a>', $total_items, $group->name, $text, $notification_link );
     494                    return apply_filters( 'bp_groups_' . $amount . '_' . $action . '_notification', '<a href="' . $notification_link . '">' . $text . '</a>', $total_items, $group->name, $text, $notification_link );
    495495                } else {
    496496
     
    581581                     * @param string $notification_link The permalink for notification.
    582582                     */
    583                     return apply_filters( 'bp_groups_' . $amount . '_' . $action . '_notification', '<a href="' . $notification_link . '" title="' . __( 'Groups', 'buddypress' ) . '">' . $text . '</a>', $total_items, $group->name );
     583                    return apply_filters( 'bp_groups_' . $amount . '_' . $action . '_notification', '<a href="' . $notification_link . '">' . $text . '</a>', $total_items, $group->name );
    584584                } else {
    585585
     
    667667                     * @param string $notification_link The permalink for notification.
    668668                     */
    669                     return apply_filters( 'bp_groups_' . $amount . '_' . $action . '_notification', '<a href="' . $notification_link . '" title="' . __( 'Groups', 'buddypress' ) . '">' . $text . '</a>', $total_items, $text, $notification_link );
     669                    return apply_filters( 'bp_groups_' . $amount . '_' . $action . '_notification', '<a href="' . $notification_link . '">' . $text . '</a>', $total_items, $text, $notification_link );
    670670                } else {
    671671                    /**
     
    749749                     * @param string $notification_link The permalink for notification.
    750750                     */
    751                     return apply_filters( 'bp_groups_' . $amount . '_' . $action . '_notification', '<a href="' . $notification_link . '" title="' . __( 'Groups', 'buddypress' ) . '">' . $text . '</a>', $total_items, $text, $notification_link );
     751                    return apply_filters( 'bp_groups_' . $amount . '_' . $action . '_notification', '<a href="' . $notification_link . '">' . $text . '</a>', $total_items, $text, $notification_link );
    752752                } else {
    753753                    /**
     
    831831                     * @param string $notification_link The permalink for notification.
    832832                     */
    833                     return apply_filters( 'bp_groups_' . $amount . '_' . $action . '_notification', '<a href="' . $notification_link . '" title="' . __( 'Group Invites', 'buddypress' ) . '">' . $text . '</a>', $total_items, $text, $notification_link );
     833                    return apply_filters( 'bp_groups_' . $amount . '_' . $action . '_notification', '<a href="' . $notification_link . '">' . $text . '</a>', $total_items, $text, $notification_link );
    834834                } else {
    835835                    /**
Note: See TracChangeset for help on using the changeset viewer.