Changeset 3750368 for gt-performance/trunk/src/Admin/AdminModule.php
- Timestamp:
- 10/16/2026 12:05:01 PM (10 days ago)
- File:
-
- 1 edited
-
gt-performance/trunk/src/Admin/AdminModule.php (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
gt-performance/trunk/src/Admin/AdminModule.php
r3748613 r3750368 1053 1053 <?php $this->stat( __( 'Page cache', 'gt-performance' ), $optimizeOnly ? __( 'Host cache, optimize only', 'gt-performance' ) : ( $cacheReady ? __( 'Active', 'gt-performance' ) : __( 'Needs setup', 'gt-performance' ) ), $cacheReady ? 'success' : 'warning' ); ?> 1054 1054 <?php $this->stat( __( 'Cloudflare', 'gt-performance' ), ! empty( $settings['cloudflare']['enabled'] ) ? __( 'Connected', 'gt-performance' ) : __( 'Not connected', 'gt-performance' ), ! empty( $settings['cloudflare']['enabled'] ) ? 'success' : 'neutral' ); ?> 1055 <?php $this->stat( __( 'Unused CSS', 'gt-performance' ), UnusedCssOptimizer::available() ? __( 'Enabled', 'gt-performance') : __( 'Off', 'gt-performance' ), UnusedCssOptimizer::available() ? 'warning' : 'neutral' ); ?>1055 <?php $this->stat( __( 'Unused CSS', 'gt-performance' ), UnusedCssOptimizer::available() ? ( $cacheReady ? __( 'Enabled', 'gt-performance' ) : __( 'Not running', 'gt-performance' ) ) : __( 'Off', 'gt-performance' ), UnusedCssOptimizer::available() ? 'warning' : 'neutral' ); ?> 1056 1056 <?php $this->stat( __( 'CSS results ready', 'gt-performance' ), number_format_i18n( $cssReady ), $cssReady > 0 ? 'success' : 'neutral' ); ?> 1057 1057 </section> … … 1084 1084 <a class="button button-primary" href="<?php echo esc_url( $this->tabUrl( 'setup' ) ); ?>"><?php esc_html_e( 'Open setup', 'gt-performance' ); ?></a> 1085 1085 <?php elseif ( ! $cacheReady ) : ?> 1086 <p><?php esc_html_e( 'Install the page-cache drop-in below, enable origin caching, then verify a public page before adding more optimizations. ', 'gt-performance' ); ?></p>1086 <p><?php esc_html_e( 'Install the page-cache drop-in below, enable origin caching, then verify a public page before adding more optimizations. Until then no page is optimized, whatever the optimization settings say.', 'gt-performance' ); ?></p> 1087 1087 <a class="button button-secondary" href="<?php echo esc_url( $this->tabUrl( 'cache' ) ); ?>"><?php esc_html_e( 'Open cache settings', 'gt-performance' ); ?></a> 1088 1088 <?php elseif ( $optimizeOnly && empty( $settings['cloudflare']['enabled'] ) ) : ?> … … 1111 1111 $verified = get_option( SetupReport::VERIFY_OPTION, null ); 1112 1112 $hosts = is_array( $probe ) ? array_map( 'strval', (array) $probe['host_caches'] ) : $report->hostCachesFromEnvironment(); 1113 $probeError = is_array( $probe ) ? (string) ( $probe['error'] ?? '' ) : ''; 1113 1114 $plugins = $report->cachePlugins(); 1114 1115 $suggested = SetupReport::recommendedMode( $hosts ); … … 1138 1139 $this->setupRow( 1139 1140 __( 'Host page cache', 'gt-performance' ), 1140 array() === $hosts1141 ? ( is_array( $probe ) ? __( 'No host page cache answered for your home page.', 'gt-performance') : __( 'Not checked yet. Detect fetches your home page once as a visitor.', 'gt-performance' ) )1141 ( array() === $hosts 1142 ? ( is_array( $probe ) ? ( '' === $probeError ? __( 'No host page cache answered for your home page.', 'gt-performance' ) : __( 'No host page cache was found in the server environment.', 'gt-performance' ) ) : __( 'Not checked yet. Detect fetches your home page once as a visitor.', 'gt-performance' ) ) 1142 1143 /* translators: %s: comma-separated host cache names. */ 1143 : sprintf( __( 'Your host caches pages: %s. Optimize only is the right mode here.', 'gt-performance' ), implode( ', ', $hosts ) ), 1144 array() === $hosts ? ( is_array( $probe ) ? __( 'None found', 'gt-performance' ) : __( 'Not checked', 'gt-performance' ) ) : __( 'Found', 'gt-performance' ), 1145 array() === $hosts ? 'neutral' : 'success', 1144 : sprintf( __( 'Your host caches pages: %s. Optimize only is the right mode here.', 'gt-performance' ), implode( ', ', $hosts ) ) ) 1145 . ( '' === $probeError ? '' : ' ' . $probeError ), 1146 '' !== $probeError ? __( 'Check failed', 'gt-performance' ) : ( array() === $hosts ? ( is_array( $probe ) ? __( 'None found', 'gt-performance' ) : __( 'Not checked', 'gt-performance' ) ) : __( 'Found', 'gt-performance' ) ), 1147 '' !== $probeError ? 'warning' : ( array() === $hosts ? 'neutral' : 'success' ), 1146 1148 'gtperf_setup_probe', 1147 1149 __( 'Detect host cache', 'gt-performance' )
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)