wxr_tag_name() WordPress Function

This function retrieves the name of a tag given its ID. Tag names are used to identify tags within WordPress. Each tag is given a unique ID, which is used by this function to retrieve the name of the tag. This function is useful for displaying the name of a tag on a website, or for retrieving the name of a tag for use in programming.

wxr_tag_name( WP_Term $tag ) #

Output a tag_name XML tag from a given tag object


Parameters

$tag

(WP_Term)(Required)Tag Object


Top ↑

Source

File: wp-admin/includes/export.php

	function wxr_tag_name( $tag ) {
		if ( empty( $tag->name ) ) {
			return;
		}

		echo '<wp:tag_name>' . wxr_cdata( $tag->name ) . "</wp:tag_name>\n";
	}


Top ↑

Changelog

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