wp_installing( int $is_installing = null )
Vérifie ou met Wordpress en mode installation.
Description
Si la constante WP_INSTALLING est définie durant le programme, la fonction retournera true.
Paramètre
$is_installing
(int) (Optionnel) True pour mettre Wordpress en mode installation, false pour désactiver ce mode. En omettant ce paramètre, on obtient le status actuel.
Valeur par défaut : null
Retourne
(bool) True si WordPress est en installation, sinon retourne false.
Structure de la fonction wp_installing()
Définie dans le fichier wp-includes/load.php à la ligne 1292 :
function wp_installing( $is_installing = null ) {
static $installing = null;
// Support for the `WP_INSTALLING` constant, defined before WP is loaded.
if ( is_null( $installing ) ) {
$installing = defined( 'WP_INSTALLING' ) && WP_INSTALLING;
}
if ( ! is_null( $is_installing ) ) {
$old_installing = $installing;
$installing = $is_installing;
return (bool) $old_installing;
}
return (bool) $installing;
}
Où trouver la fonction wp_installing()
dans le CMS Wordpress
Sources
Codex Wordpress : wp_installing()
Autres fonctions dans le même fichier : wp-includes/load.php