• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

WP SITES

2665

Original Genesis Tutorials & 5000+ Guaranteed Code

Snippets

  • Support
  • Newsletter
  • Videos
  • Log in

Premium Member? - Request custom code

Remove Entry Meta From Custom Post Types in Genesis

This code removes the entry meta in the entry header and entry footer from custom post types.

Simply replace post-type in the following code with the name of your post type.

Then you’ll need to add the code at the end of your child themes functions file using a code editor.

add_action( 'init', 'sample_remove_entry_meta', 11 );
/**
 * Remove entry meta for post types
 * 
 * @link https://gist.github.com/nathanrice/03a5871e5e5a27f22747
 */
function sample_remove_entry_meta() {

	remove_post_type_support( 'post-type', 'genesis-entry-meta-before-content' );
	remove_post_type_support( 'post-type', 'genesis-entry-meta-after-content' );

}

The above code replaces the following which was used before Genesis 2.2 was released:

//* Remove the post info function
remove_action( 'genesis_entry_header', 'genesis_post_info', 12 );

//* Remove the post meta function
remove_action( 'genesis_entry_footer', 'genesis_post_meta' );

Related Tutorials

  • How to remove post info from custom post type only in Genesis

Custom Post Type Entry Meta

Reader Interactions

Leave a Reply Cancel reply

You must be logged in to post a comment.

Primary Sidebar

PHP Code

template_include

get_body_class

if else

array

class_exists

foreach

sprintf

add_action

printf

variable

Advertise · WPEngine · Genesis · Log in

  • How Premium Membership Works
  • Sign Up
  • Support
  • Subscription Details/Invoice
  • Tagged Tutorials
  • Access-Download Problems