Stumped: Custom Post Featured Image Box Not Showing
-
This is a weird issue. I have 4 custom post types. The first 3 work great. The 4th one, added last night by copy/pasting one of the previous types and changing the names will not show the featured image box for anything. It’s not anywhere on the editing screen nor is it listed in the screen options panel.
I’ve done the following with no results:
-Disabled all plugins
-Changed Themes
-Changed the name of the custom post type
-Flushed PermalinksHere is the one that works:
add_action('init', 'gifts_register_post_type'); function gifts_register_post_type() { register_post_type( 'gifts', array( 'labels' => array( 'name' => 'Gifts', 'singular_name' => 'Gift', 'add_new' => 'Add new gift', 'edit_item' => 'Edit gift', 'new_item' => 'New gift', 'view_item' => 'View gift', 'search_items' => 'Search gifts', 'not_found' => 'No gifts found', 'not_found_in_trash' => 'No gifts found in Trash' ), 'public' => true, 'supports' => array( 'title', 'editor', 'excerpt', 'custom-fields', 'revisions', 'thumbnail' ), 'has_archive' => true, 'taxonomies' => array() ) );
And here is the copy of that code that does not:
add_action('init', 'products_register_post_type'); function products_register_post_type() { register_post_type( 'products', array( 'labels' => array( 'name' => 'Products', 'singular_name' => 'Product', 'add_new' => 'Add new product', 'edit_item' => 'Edit product', 'new_item' => 'New product', 'view_item' => 'View product', 'search_items' => 'Search product', 'not_found' => 'No products found', 'not_found_in_trash' => 'No products found in Trash' ), 'public' => true, 'supports' => array('title', 'title', 'editor', 'excerpt', 'custom-fields', 'revisions', 'thumbnail' ), 'has_archive' => true, 'taxonomies' => array() ) );
The first custom post type “gifts” works great. The featured image shows up just fine.
This is also in my functions.php file :
add_theme_support( 'post-thumbnails' ); set_post_thumbnail_size( 210, 210, true );
Any thoughts on what to try next? I’m completely at a dead end here. :/
- The topic ‘Stumped: Custom Post Featured Image Box Not Showing’ is closed to new replies.