wpseek.com
Bazujące na WordPress narzędzie wyszukiwania dla deweloperów i twórców motywów.
term_description › WordPress Function
Od2.8.0
Przestarzałyn/a
› term_description ( $term = 0, $deprecated = null )
| Parametry: (2) |
|
| Powrót: |
|
| Zdefiniowane na: |
|
| Codex: | |
| Dziennik zmian: |
|
Retrieves term description.
Powiązane Funkcje: tag_description, category_description, the_author_description, the_archive_description, wp_sidebar_description
Źródło
function term_description( $term = 0, $deprecated = null ) {
if ( ! $term && ( is_tax() || is_tag() || is_category() ) ) {
$term = get_queried_object();
if ( $term ) {
$term = $term->term_id;
}
}
$description = get_term_field( 'description', $term );
return is_wp_error( $description ) ? '' : $description;
}