WordPress函数"register_post_type"用于注册自定义的文章类型(Custom Post Type),以便在WordPress管理后台中显示和管理。但是,如果使用该函数注册的自定义文章类型未显示在管理左侧边栏中,可能有以下几个原因:
register_post_type('custom_post_type', array(
'label' => 'Custom Post Type',
'public' => true,
'show_in_menu' => true,
));
register_post_type('custom_post_type', array(
'label' => 'Custom Post Type',
'public' => true,
'show_in_menu' => true,
'version' => '1.0',
));
推荐的腾讯云相关产品:腾讯云服务器(CVM)和腾讯云数据库(TencentDB)可用于搭建和托管WordPress网站。您可以通过以下链接了解更多关于腾讯云服务器和腾讯云数据库的信息:
领取专属 10元无门槛券
手把手带您无忧上云