get_post_modified_time

FUNCTION wp-includes\general-template.php (ligne 3051) github
Filters the localized time a post was last modified.

Paramètres

Entrée :
$format = 'U', $gmt = false, $post = null, $translate = false
Sortie :
@param string|int|false $the_time The formatted time or false if no post is found.
@param string           $format   Format to use for retrieving the time the post
@param WP_Post|null     $post     WP_Post object or null if no post is found.
@param string      $format    Optional. Format to use for retrieving the time the post
@param bool        $gmt       Optional. Whether to retrieve the GMT time. Default false.
@param int|WP_Post $post      Post ID or post object. Default is global `$post` object.
@param bool        $translate Whether to translate the time string. Default false.
@return string|int|false Formatted date string or Unix timestamp if `$format` is 'U' or 'G'.

Utilisation

// Utilisation de la fonction get_post_modified_time
$result = get_post_modified_time($format = 'U', $gmt = false, $post = null, $translate = false);

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

Actualités

Chargement des actualités...