wpseek.com
Outil de recherche WordPress pour les développeurs et auteurs de thèmes



is_taxonomy_viewable › WordPress Function

Depuis5.1.0
Dépréciéen/a
is_taxonomy_viewable ( $taxonomy )
Paramètres:
  • (string|WP_Taxonomy) $taxonomy Taxonomy name or object.
    Requis: Oui
Retourne:
  • (bool) Whether the taxonomy should be considered viewable.
Défini(e) dans:
Codex:

Determines whether a taxonomy is considered "viewable".



Source

function is_taxonomy_viewable( $taxonomy ) {
	if ( is_scalar( $taxonomy ) ) {
		$taxonomy = get_taxonomy( $taxonomy );
		if ( ! $taxonomy ) {
			return false;
		}
	}

	return $taxonomy->publicly_queryable;
}