我想在管理区域中显示更多自定义帖子类型,但当我通过在屏幕选项中添加一个数字并单击应用来增加帖子数量时,什么都没有发生。然而,这适用于正常的帖子。
我的自定义帖子代码:
// Register Post Type
add_action( \'init\', \'create_tests_type\' );
function create_tests_type() {
$labels = array(
\'name\' => _x( \'Test\', \'post type general name\' ),
\'singular_name\' => _x( \'Test\', \'post type singular name\' ),
\'add_new\' => _x( \'Add New\', \'book\' ),
\'add_new_item\' => __( \'Add New Test\' ),
\'edit_item\' => __( \'Edit Tests\' ),
\'new_item\' => __( \'New Tests\' ),
\'all_items\' => __( \'All Tests\' ),
\'view_item\' => __( \'View Test\' ),
\'search_items\' => __( \'Search Tests\' ),
\'not_found\' => __( \'No Tests found\' ),
\'not_found_in_trash\' => __( \'No Tests found in the Trash\' ),
\'parent_item_colon\' => \'\',
\'menu_name\' => \'Tests\'
);
$args = array(
\'labels\' => $labels,
\'description\' => \'Holds our Tests data\',
\'public\' => true,
\'menu_position\' => 5,
\'supports\' => array( \'title\', \'editor\', \'thumbnail\', \'excerpt\', \'comments\' ),
\'has_archive\' => true,
);
register_post_type( \'test\', $args );
}
我已经搜索了很多来解决这个问题,但没有找到正确的解决方案。