ajax.php
7 months ago
cloud_news.tpl.php
7 months ago
cloud_promo.tpl.php
7 months ago
new_version.php
7 months ago
new_version_dev.tpl.php
7 months ago
score.php
7 months ago
slack.php
7 months ago
ajax.php
24 lines
| 1 | <?php |
| 2 | /** |
| 3 | * Health Check Script |
| 4 | * |
| 5 | * Triggers a health check request for speed when the document is loaded. |
| 6 | * |
| 7 | * @package LiteSpeed |
| 8 | * @since 1.0.0 |
| 9 | * @deprecated 3.3 Will only show banner after user manually checked score |
| 10 | */ |
| 11 | |
| 12 | namespace LiteSpeed; |
| 13 | |
| 14 | defined( 'WPINC' ) || exit; |
| 15 | |
| 16 | $url = Utility::build_url( Router::ACTION_HEALTH, Health::TYPE_SPEED, true, null, array(), true ); |
| 17 | ?> |
| 18 | <script> |
| 19 | document.addEventListener('DOMContentLoaded', function() { |
| 20 | jQuery(document).ready( function() { |
| 21 | jQuery.get( '<?php echo $url; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>' ) ; |
| 22 | } ) ; |
| 23 | }); |
| 24 | </script> |