Advertisement
Guest User

Untitled

a guest
Aug 1st, 2015
228
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.67 KB | None | 0 0
  1. /*
  2. * Genesis Remove Author Box from Single Templates for the The Events Calendar
  3. * The Events Calendar @3.10
  4. * Genesis @2.1.2
  5. * this adds the filter for testing add_filter( 'get_the_author_genesis_author_box_single', '__return_true' );
  6. * To Do Fixed Trying to get property of non-object notice
  7. */
  8. add_action( 'pre_get_posts', 'tribe_genesis_hide_author_single_events' );
  9. function tribe_genesis_hide_author_single_events( $query ) {
  10.  
  11. //ADD POST TYPE CHECK if isset
  12. if( is_singular( 'tribe_events' ) || $query->query['post_type'] == 'tribe_venue' || $query->query['post_type'] == 'tribe_organizer' ) {
  13. remove_action( 'genesis_after_entry', 'genesis_do_author_box_single', 8 );
  14. }
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement