tag_description() WordPress Function

The tag_description() function is used to display the description of a given tag. This is typically used within the context of a tag archive page.

tag_description( int $tag ) #

Retrieves tag description.


Parameters

$tag

(int)(Optional) Tag ID. Defaults to the current tag ID.


Top ↑

Return

(string) Tag description, if available.


Top ↑

More Information

Usage:
$description = tag_description();
Notes:

Output is wrapped in <p> tags.


Top ↑

Source

File: wp-includes/category-template.php

function tag_description( $tag = 0 ) {
	return term_description( $tag );
}


Top ↑

Changelog

Changelog
VersionDescription
2.8.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.