get_category_to_edit

函数


get_category_to_edit ( $id )
参数
  • (int)
    $id
    Required:
返回值
  • (object)
定义位置
  • wp-admin/includes/taxonomy.php
    , line 40
引入
2.0.0
弃用

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

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