the_date

FUNCTION wp-includes\general-template.php (ligne 2663) github
Displays or retrieves the date of the post (once per date). Will only output the date if the current post's date is different from the previous one output. i.e. Only one date listing will show per day worth of posts shown in the loop, even if the

Paramètres

Entrée :
$format = '', $before = '', $after = '', $display = true
Sortie :
@param string $format  Optional. PHP date format. Defaults to the 'date_format' option.
@param string $before  Optional. Output before the date. Default empty.
@param string $after   Optional. Output after the date. Default empty.
@param bool   $display Optional. Whether to echo the date or return it. Default true.
@return string|void String if retrieving.

Utilisation

// Utilisation de la fonction the_date
$result = the_date($format = '', $before = '', $after = '', $display = true);

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

Actualités

Chargement des actualités...