• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

remove post info on custom post type

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › Design Tips and Tricks › remove post info on custom post type

This topic is: not resolved
  • This topic has 2 replies, 3 voices, and was last updated 12 years, 9 months ago by Summer.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • January 26, 2014 at 1:03 pm #87112
    Bill
    Participant

    I have researched several ways to try and do this, but none work for me. I am using a HTML genesis theme.
    I a using this code...but the custom post type for "condominiums" will not remove the date on the Custom Post.

    /** Remove custom Post Type post_info */
    add_action('template_redirect', 'remove_post_info_cpt');
    function remove_post_info_cpt() {
    if ( 'condominiums' !== get_post_type())
    remove_action( 'genesis_entry_header', 'genesis_post_info' );
    }

    the name of the custom post type is verified as "condominiums", so not sure why the date is still appearing on these posts under the post title. What am I doing wrong?

    January 26, 2014 at 6:46 pm #87153
    pxforti
    Participant

    I think you need to add priority to it:

    remove_action( 'genesis_entry_header', 'genesis_post_info', 12 );


    writeNowDesign
    WordPress and Ecommerce Website Design

    January 26, 2014 at 11:00 pm #87193
    Summer
    Member

    Actually, I think your conditional logic might be what's hanging you up.

    What you have above is testing the post type, and if the post type is NOT condominiums, then remove the post info.

    What you should be using is:

    if (  ‘condominiums’ == get_post_type() )
       remove_action( ‘genesis_entry_header’, ‘genesis_post_info’ );
    }

    That way, if your post type tests "true" for "condominiums", then it'll perform the remove_action. The way you have it now, it'll perform that remove_action for every post type except "condominiums".


    WordPress / Genesis Site Design & Troubleshooting: A Touch of Summer | @SummerWebDesign
    Slice of SciFi | Writers, After Dark

  • Author
    Posts
Viewing 3 posts - 1 through 3 (of 3 total)
  • The forum ‘Design Tips and Tricks’ is closed to new topics and replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2026 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble