get_category_to_edit( int $id ): object

In this article

Gets category object for given ID and ‘edit’ filter context.

Parameters

$idintrequired

Return

object

Source

function get_category_to_edit( $id ) {
	$category = get_term( $id, 'category', OBJECT, 'edit' );
	_make_cat_compat( $category );
	return $category;
}

Changelog

VersionDescription
2.0.0Introduced.

User Contributed Notes

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