Adding Thumbnail support to Custom Post Types

miniaturas-wordpressSo you’ve created your Custom Post Type, adding the correct options to activate thumbnails on your type, but the thumbnails metabox does not appear. Why I know those things? Because I just get stuck in the same problem.

Obviously, I have solved it, and when I found magical solutions to rare problems, I come here to share them with you.

Let’s begin. You have created your Custom Post Type, adding this line:


Maybe you have created your custom type with Types or another plugin like that, and you have selected “Thumbnails”. And all of this is useless.

With these four lines in our Theme (funcions.php) or an own Plugin, our problem should dissapear:

function myplugin_thumbnails_support(){
    add_theme_support( 'post-thumbnails', array( 'my-custom-type' ) );

“Don’t document the problem; fix it”
.- Atli Björgvin Oddsson

Artículo escrito por

¡Exprésate! Dejanos tu comentario

Tu dirección de correo electrónico no será publicada. Los campos obligatorios están marcados con *

2 Comentarios

15 mayo, 2015


Thanks a lot for this useful tip. I was struggling with this issue!!

7 julio, 2013


This is really helpful, thanks a lot