diff --git a/wp-admin/includes/class-wp-plugins-list-table.php b/wp-admin/includes/class-wp-plugins-list-table.php
index e487e32cfb..cc76e0e53d 100644
|
a
|
b
|
class WP_Plugins_List_Table extends WP_List_Table { |
| 946 | 946 | $requires_php = isset( $plugin_data['requires_php'] ) ? $plugin_data['requires_php'] : null; |
| 947 | 947 | $compatible_php = is_php_version_compatible( $requires_php ); |
| 948 | 948 | $class = $is_active ? 'active' : 'inactive'; |
| 949 | | $checkbox_id = 'checkbox_' . md5( $plugin_data['Name'] ); |
| | 949 | |
| | 950 | static $checkbox_id_attrs = array(); |
| | 951 | |
| | 952 | $checkbox_id = 'checkbox_' . md5( $plugin_data['Name'] ); |
| | 953 | $checkbox_id_attr = $checkbox_id; |
| | 954 | |
| | 955 | // Ensure the ID attribute is unique. |
| | 956 | $suffix = 2; |
| | 957 | while ( in_array( $checkbox_id_attr, $checkbox_id_attrs, true ) ) { |
| | 958 | $checkbox_id_attr = "$checkbox_id-$suffix"; |
| | 959 | $suffix++; |
| | 960 | } |
| | 961 | |
| | 962 | $checkbox_id_attrs[] = $checkbox_id_attr; |
| | 963 | |
| 950 | 964 | if ( $restrict_network_active || $restrict_network_only || in_array( $status, array( 'mustuse', 'dropins' ), true ) || ! $compatible_php ) { |
| 951 | 965 | $checkbox = ''; |
| 952 | 966 | } else { |
| 953 | 967 | $checkbox = sprintf( |
| 954 | 968 | '<label class="screen-reader-text" for="%1$s">%2$s</label>' . |
| 955 | 969 | '<input type="checkbox" name="checked[]" value="%3$s" id="%1$s" />', |
| 956 | | $checkbox_id, |
| | 970 | $checkbox_id_attr, |
| 957 | 971 | /* translators: %s: Plugin name. */ |
| 958 | 972 | sprintf( __( 'Select %s' ), $plugin_data['Name'] ), |
| 959 | 973 | esc_attr( $plugin_file ) |