wpseek.com
Eine auf WordPress spezialiserte Suchmaschine für Entwickler und Theme-Autoren



wp_delete_category › WordPress Function

Seit2.0.0
Veraltetn/v
wp_delete_category ( $cat_id )
Parameter:
  • (int) $cat_id Category term ID.
    Erforderlich: Ja
Gibt zurück:
  • (bool|int|WP_Error) Returns true if completes delete action; false if term doesn't exist; Zero on attempted deletion of default Category; WP_Error object is also a possibility.
Definiert in:
Codex:

Deletes one existing category.



Quellcode

function wp_delete_category( $cat_id ) {
	return wp_delete_term( $cat_id, 'category' );
}