Wordpress 删除Woocommerce类别列表页面上的类别说明(管理区域)

Wordpress 删除Woocommerce类别列表页面上的类别说明(管理区域),wordpress,woocommerce,Wordpress,Woocommerce,如何从woocommerce的类别列表页面中删除类别说明。我不想删除添加描述功能,我将使用它,而只是从类别列表(在管理区域)中删除它,因为我有很多很长的描述,并且列表中包含的描述看起来不太好。一直在谷歌上搜索这个,毫无意外地没有运气 提前感谢。删除woocommerce和wordpress默认类别列表页面上的内容 /*========== Remove Category Column on Wordpress Category Listing Page ==========*/ function

如何从woocommerce的类别列表页面中删除类别说明。我不想删除添加描述功能,我将使用它,而只是从类别列表(在管理区域)中删除它,因为我有很多很长的描述,并且列表中包含的描述看起来不太好。一直在谷歌上搜索这个,毫无意外地没有运气


提前感谢。

删除woocommerce和wordpress默认类别列表页面上的内容

/*========== Remove Category Column on Wordpress Category Listing Page ==========*/
function cap_remove_category_desc_cat_listing($columns)
{
// only edit the columns on the current taxonomy
if ( !isset($_GET['taxonomy']) || ($_GET['taxonomy'] != 'category' && $_GET['taxonomy'] != 'product_cat') )
    return $columns;

// unset the description columns
if ( $posts = $columns['description'] ){ unset($columns['description']); }

return $columns;
}
add_filter('manage_edit-category_columns','cap_remove_category_desc_cat_listing');
add_filter('manage_edit-product_cat_columns','cap_remove_category_desc_cat_listing');