--- a/wp/wp-admin/site-health-info.php Tue Dec 15 15:52:01 2020 +0100
+++ b/wp/wp-admin/site-health-info.php Wed Sep 21 18:19:35 2022 +0200
@@ -6,18 +6,10 @@
* @subpackage Administration
*/
-/** WordPress Administration Bootstrap */
-require_once __DIR__ . '/admin.php';
-
-$title = __( 'Site Health Info' );
-
-if ( ! current_user_can( 'view_site_health_checks' ) ) {
- wp_die( __( 'Sorry, you are not allowed to access the debug data.' ), '', 403 );
+if ( ! defined( 'ABSPATH' ) ) {
+ die();
}
-wp_enqueue_style( 'site-health' );
-wp_enqueue_script( 'site-health' );
-
if ( ! class_exists( 'WP_Debug_Data' ) ) {
require_once ABSPATH . 'wp-admin/includes/class-wp-debug-data.php';
}
@@ -26,46 +18,7 @@
}
$health_check_site_status = WP_Site_Health::get_instance();
-
-require_once ABSPATH . 'wp-admin/admin-header.php';
?>
-<div class="health-check-header">
- <div class="health-check-title-section">
- <h1>
- <?php _e( 'Site Health' ); ?>
- </h1>
- </div>
-
- <div class="health-check-title-section site-health-progress-wrapper loading hide-if-no-js">
- <div class="site-health-progress">
- <svg role="img" aria-hidden="true" focusable="false" width="100%" height="100%" viewBox="0 0 200 200" version="1.1" xmlns="http://www.w3.org/2000/svg">
- <circle r="90" cx="100" cy="100" fill="transparent" stroke-dasharray="565.48" stroke-dashoffset="0"></circle>
- <circle id="bar" r="90" cx="100" cy="100" fill="transparent" stroke-dasharray="565.48" stroke-dashoffset="0"></circle>
- </svg>
- </div>
- <div class="site-health-progress-label">
- <?php _e( 'Results are still loading…' ); ?>
- </div>
- </div>
-
- <nav class="health-check-tabs-wrapper hide-if-no-js" aria-label="<?php esc_attr_e( 'Secondary menu' ); ?>">
- <a href="<?php echo esc_url( admin_url( 'site-health.php' ) ); ?>" class="health-check-tab">
- <?php
- /* translators: Tab heading for Site Health Status page. */
- _ex( 'Status', 'Site Health' );
- ?>
- </a>
-
- <a href="<?php echo esc_url( admin_url( 'site-health.php?tab=debug' ) ); ?>" class="health-check-tab active" aria-current="true">
- <?php
- /* translators: Tab heading for Site Health Info page. */
- _ex( 'Info', 'Site Health' );
- ?>
- </a>
- </nav>
-</div>
-
-<hr class="wp-header-end">
<div class="notice notice-error hide-if-js">
<p><?php _e( 'The Site Health check requires JavaScript.' ); ?></p>
@@ -179,6 +132,3 @@
<?php } ?>
</div>
</div>
-
-<?php
-require_once ABSPATH . 'wp-admin/admin-footer.php';