[Resolved] Disable post images for a specific category only

Home Forums Support Disable post images for a specific category only

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #1520098
    Samuel

    I use Custom Post Type UI and now I have a new Custom Post Type. The category Overview displays the images in the same way as my blog archive. But I don’t want any images in this new Custom Post Type. How can I deactivate it? Unfortunately there is only one general rule in the Customizer.

    #1520319
    David
    Staff
    Customer Support
    #1523255
    Samuel

    Hi David,

    wow very powerful these filters. Thanks!

    That works for me:

    // /touren-Archivseite individuell gestalten
    add_filter( 'option_generate_blog_settings', 'lh_custom_search_results_page_settings' );
    function lh_custom_search_results_page_settings( $options ) {
        if ( is_post_type_archive( $myposttype ) ) {
    	$options['post_image'] = false;
        }
      
        return $options;
    }
    #1523472
    David
    Staff
    Customer Support

    They certainly are 🙂
    Glad to be of help.

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.