wp_is_mobile

FUNCTION wp-includes\vars.php (ligne 2) github
Creates common globals for the rest of WordPress Sets $pagenow global which is the filename of the current screen. Checks for the browser to set which one is currently being used. Detects which user environment WordPress is being used on. Only attempts to check for Apache, Nginx and IIS -- three web servers with known pretty permalink capability. Note: Though Nginx is detected, WordPress does not currently generate rewrite rules for it. See https://developer.wordpress.org/advanced-administration/server/web-server/nginx/

Paramètres

Entrée :
N/A
Sortie :
@param bool $is_admin Whether to use the Google Chrome Frame. Default is the value of is_admin().
@return bool

Utilisation

// Utilisation de la fonction wp_is_mobile
$result = wp_is_mobile();

if ($result) {
    // Votre logique ici
}

Actualités

Chargement des actualités...