我有一个自定义的帖子类型叫做“工作”,其中一个类别叫做“格式”
每当我转到URL域时。com/archives/category/formats它不显示我的自定义帖子类型,只显示分类为“formats”的普通帖子
有什么办法让这些东西出现吗?(我假设文件是archives-work.php)
更新:这在我的函数文件中。
<?php
// Custom Post Type - Work
function create_custom_post_work() {
register_post_type( \'work\',
array(
\'labels\' => array(
\'name\' => __( \'Work\' ),
\'singular_name\' => __( \'Work\' ),
),
\'public\' => true,
\'has_archive\' => true,
\'supports\' => array(
\'title\',
\'editor\',
\'thumbnail\',
\'custom-fields\',),
\'taxonomies\' => array(\'topics\', \'category\')
));
}
add_action( \'init\', \'create_custom_post_work\' );
?>