我想创建一个名为testimonials的自定义帖子类型,为此我想让管理员有机会添加公司名称/用户名以及他们提供了哪些推荐,我知道我可以做到这一点通过在我的functions.php
文件中声明一个自定义的帖子类型,但它似乎不工作,我得到的只是普通的帖子字段,有人可以告诉我哪里出错了,或者我该怎么做?自定义帖子类型wordpress
function testimonials_register() {
$args = array(
'label' => __('Testimonials'),
'singular_label' => __('Testimonial'),
'public' => true,
'show_ui' => true,
'capability_type' => false,
'hierarchical' => false,
'rewirte' => true,
'supports' => array('title', 'editor')
);
register_post_type('testimonial', $args);
}