tag_exists( int|string $tag_name )

Check whether a post tag with a given name exists.


Description Description


Parameters Parameters

$tag_name

(int|string) (Required)


Top ↑

Return Return

(mixed)


Top ↑

Source Source

File: wp-admin/includes/taxonomy.php

function tag_exists( $tag_name ) {
	return term_exists( $tag_name, 'post_tag' );
}

Top ↑

Changelog Changelog

Changelog
Version Description
2.3.0 Introduced.


Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.