функция
since 4.1.0
get_the_archive_description()
Проверено на WordPress 6.9, обновлено Источник: WordPress Developer Resources.
Сигнатура
get_the_archive_description(): string
Описание
См. alsoterm_description()
Оригинал (английский)
Возвращаемое значение
string
Исходный код
wp-includes/general-template.php:1844
function get_the_archive_description() {
if ( is_author() ) {
$description = get_the_author_meta( 'description' );
} elseif ( is_post_type_archive() ) {
$description = get_the_post_type_description();
} else {
$description = term_description();
}
/**
* Filters the archive description.
*
* @since 4.1.0
*
* @param string $description Archive description to be displayed.
*/
return apply_filters( 'get_the_archive_description', $description );
}
История изменений
| Версия | Описание |
|---|---|
| 4.9.0 | Added support for post type archives. |
| 4.7.0 | Added support for author archives. |
| 4.1.0 | Introduced. |

