diff --git src/wp-admin/update-core.php src/wp-admin/update-core.php
index 61527bfc82..9863a23637 100644
|
|
foreach ( (array) $plugins as $plugin_file => $plugin_data ) { |
287 | 287 | $compat .= '<br />' . sprintf( __( 'Compatibility with WordPress %1$s: Unknown' ), $core_update_version ); |
288 | 288 | } |
289 | 289 | } |
| 290 | |
| 291 | $tested_php = ! empty( $plugin_data->update->requires_php ); |
| 292 | $compatible_php = ( ! $tested_php || version_compare( substr( PHP_VERSION, 0, strlen( $plugin_data->update->requires_php ) ), $plugin_data->update->requires_php, '>=' ) ); |
| 293 | $can_update = ! $tested_php || $compatible_php; |
| 294 | |
| 295 | if ( ! $can_update ) { |
| 296 | $compat .= '<br>' . __( 'Incompatible with your version of PHP.' ) . ' '; |
| 297 | /* translators: Link to servehappy page */ |
| 298 | $compat .= sprintf( |
| 299 | __( '%sLearn more about updating PHP.%s' ), |
| 300 | '<a href="https://wordpress.org/support/upgrade-php/">', |
| 301 | '</a>' |
| 302 | ); |
| 303 | } |
| 304 | |
290 | 305 | // Get the upgrade notice for the new plugin version. |
291 | 306 | if ( isset( $plugin_data->update->upgrade_notice ) ) { |
292 | 307 | $upgrade_notice = '<br />' . strip_tags( $plugin_data->update->upgrade_notice ); |
… |
… |
foreach ( (array) $plugins as $plugin_file => $plugin_data ) { |
308 | 323 | ?> |
309 | 324 | <tr> |
310 | 325 | <td class="check-column"> |
| 326 | <?php if ( $can_update ) : ?> |
311 | 327 | <input type="checkbox" name="checked[]" id="<?php echo $checkbox_id; ?>" value="<?php echo esc_attr( $plugin_file ); ?>" /> |
312 | 328 | <label for="<?php echo $checkbox_id; ?>" class="screen-reader-text"> |
313 | 329 | <?php |
… |
… |
foreach ( (array) $plugins as $plugin_file => $plugin_data ) { |
318 | 334 | ); |
319 | 335 | ?> |
320 | 336 | </label> |
| 337 | <?php endif; ?> |
321 | 338 | </td> |
322 | 339 | <td class="plugin-title"><p> |
323 | 340 | <?php echo $icon; ?> |