$conf, $runtime; function_exists('chdir') AND chdir(APP_PATH); $r = 'mysql' == $conf['cache']['type'] ? website_set('runtime', $runtime) : cache_set('runtime', $runtime); } function runtime_truncate() { global $conf; 'mysql' == $conf['cache']['type'] ? website_set('runtime', '') : cache_delete('runtime'); } register_shutdown_function('runtime_save'); ?>post thumbnails - Featured image is not showing in wp-admin|Programmer puzzle solving
最新消息:Welcome to the puzzle paradise for programmers! Here, a well-designed puzzle awaits you. From code logic puzzles to algorithmic challenges, each level is closely centered on the programmer's expertise and skills. Whether you're a novice programmer or an experienced tech guru, you'll find your own challenges on this site. In the process of solving puzzles, you can not only exercise your thinking skills, but also deepen your understanding and application of programming knowledge. Come to start this puzzle journey full of wisdom and challenges, with many programmers to compete with each other and show your programming wisdom! Translated with DeepL.com (free version)

post thumbnails - Featured image is not showing in wp-admin

matteradmin8PV0评论

Featured image is not displaying on wp-admin side. I have also selected 'featured image' option from Screen Options. While Selecting image from media it doesn't show selected image in the metabox. I have written the below code:

function twentytwelve_setup() {
  add_theme_support('post-thumbnails');
  }
add_action( 'after_setup_theme', 'twentytwelve_setup' );

Featured image is not displaying on wp-admin side. I have also selected 'featured image' option from Screen Options. While Selecting image from media it doesn't show selected image in the metabox. I have written the below code:

function twentytwelve_setup() {
  add_theme_support('post-thumbnails');
  }
add_action( 'after_setup_theme', 'twentytwelve_setup' );
Share Improve this question edited Sep 19, 2016 at 11:59 cjbj 15k16 gold badges42 silver badges89 bronze badges asked Sep 19, 2016 at 11:57 Nehal ShahNehal Shah 312 silver badges3 bronze badges 2
  • 1 That code looks fine. The behaviour is unusual and it's difficult to say what may be causing it. The usual debugging path would be to disable all plugins and see if the problem is still there. Then switch them on one by one. – cjbj Commented Sep 19, 2016 at 12:01
  • why do you have this inside a function? Can't you just put add_theme_support( 'post-thumbnails' ); directly inside your functions.php? – RiddleMeThis Commented Sep 17, 2018 at 15:35
Add a comment  | 

2 Answers 2

Reset to default 2

Have you double checked if the featured-image section is enabled under the Screen Options tab?

You can disable/comment these plugin/code one by one by which having remove_meta_box() function.

remove_meta_box function is used to removes a meta box or any other element from a particular post edit screen of a given post type. It can be also used to remove a widget from the dashboard screen.

Once you filter this things you get the cause point. Best of luck!

Post a comment

comment list (0)

  1. No comments so far