• Hi,
    I’ve installed latest version of wordpress and tried to create custom post type with thumbnail support:

    protected function _applyCustomPostTypes() {
            add_action( 'init', array($this, 'customPostMedia') );
        }
    
        public function customPostMedia() {
            register_post_type( 'custom-media',
                array(
                    'labels' => array(
                        'name' => __( 'Media' ),
                        'singular_name' => __( 'Media' )
                    ),
                    'public' => true,
                    'has_archive' => true,
                    'rewrite' => array('slug' => 'custom-media'),
                    'supports' => array(
                        'title','editor','thumbnail'
                    )
    
                )
            );
        }

    No thumbnail box is shown in add/edit post page for this post type in admin.

    How can I add this support ?

    Best

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)

The topic ‘Custom post theme – thumbnail support’ is closed to new replies.