site_status_tests

FILTER wp-admin\includes\class-wp-site-health.php (ligne 2956) github
Filters which site status tests are run on a site. The site health is determined by a set of tests based on best practices from both the WordPress Hosting Team and web standards in general. Some sites may not have the same requirements, for example the automatic update checks may be handled by a host, and are therefore disabled in core. Or maybe you want to introduce a new test, is caching enabled/disabled/stale for example. Tests may be added either as direct, or asynchronous ones. Any test that may require some time to complete should run asynchronously, to avoid extended loading periods within wp-admin.

Paramètres

Entrée :
$tests
Sortie :
@param array[] $tests {

Utilisation

// Modifier la valeur avec le filtre 'site_status_tests'
add_filter('site_status_tests', 'ma_fonction_filtre', 10, 1);

function ma_fonction_filtre($tests) {
    // Modifier la valeur
    return $tests;
}

Actualités

Chargement des actualités...