Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I have this in my functions.php

add_theme_support( 'post-thumbnails' );

This means all my post-types (normal posts and custom-post-types) have post-thumbnails enabled.

Is it possible to just enable them inside a custom-post-type and not on normal posts?

share|improve this question
add comment

2 Answers

up vote 3 down vote accepted

Use remove_post_type_support to disable features for specific post types.

add_action( 'init', 'wpa63635_init' );
function wpa63635_init() {
    remove_post_type_support( 'post', 'thumbnail' );
}
share|improve this answer
add comment

If you specify a "supports" argument when registering the Custom Post type, you can leave out "thumbnail" which will disable it for that post-type.

See the Codex entry for register_post_type and look at the 'supports' argument.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.