?php /** * This file adds the category archive template. * */ //* Force full width content layout add_filter( 'genesis_pre_get_option_site_layout', '__genesis_return_full_width_content' ); //* Remove the breadcrumb navigation remove_action( 'genesis_before_loop', 'genesis_do_breadcrumbs' ); //* Remove the post info function remove_action( 'genesis_entry_header', 'genesis_post_info', 5 ); //* Remove the post content remove_action( 'genesis_entry_content', 'genesis_do_post_content' ); //* Remove the post image remove_action( 'genesis_entry_content', 'genesis_do_post_image', 8 ); //* Add portfolio body class to the head // add_filter( 'body_class', 'executive_add_portfolio_body_class' ); function executive_add_portfolio_body_class( $classes ) { $classes[] = 'executive-pro-portfolio'; return $classes; } /** * Display as Columns * */ function be_portfolio_post_class( $classes ) { $columns = 4; // Set the number of columns here $column_classes = array( '', '', 'one-half', 'one-third', 'one-fourth', 'one-fifth', 'one-sixth' ); $classes[] = $column_classes[$columns]; global $wp_query; if( 0 == $wp_query->current_post || 0 == $wp_query->current_post % $columns ) $classes[] = 'first'; return $classes; } add_filter( 'post_class', 'be_portfolio_post_class' ); //* Add the featured image after post title add_action( 'genesis_entry_header', 'sk_category_grid' ); function sk_category_grid() { if ( $image = genesis_get_image( 'format=url&size=category-image' ) ) { printf( '
%s
', get_permalink(), $image, the_title_attribute( 'echo=0' ) ); } } //* Customize entry meta in the entry header add_filter( 'genesis_post_info', 'sp_post_info_filter' ); function sp_post_info_filter($post_info) { // $post_info = '[post_date] by [post_author_posts_link] [post_comments] [post_edit]'; $post_info = '[post_date] [post_edit]'; return $post_info; } //* Remove the post meta function remove_action( 'genesis_entry_footer', 'genesis_post_meta' ); genesis();