wxr_term_description() WordPress Function

The wxr_term_description() function is used to return the description of a given term from the WordPress taxonomy. This is useful for displaying the description of a category or tag on a post or page.

wxr_term_description( WP_Term $term ) #

Output a term_description XML tag from a given term object


Parameters

$term

(WP_Term)(Required)Term Object


Top ↑

Source

File: wp-admin/includes/export.php

	function wxr_term_description( $term ) {
		if ( empty( $term->description ) ) {
			return;
		}

		echo "\t\t<wp:term_description>" . wxr_cdata( $term->description ) . "</wp:term_description>\n";
	}


Top ↑

Changelog

Changelog
VersionDescription
2.9.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.