Last active
December 3, 2019 07:12
-
-
Save topleague/5900e58cb52b41b2c02cd43fd5961cb1 to your computer and use it in GitHub Desktop.
Relocating Elements in Gridified Blog Archives in Business Theme
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//# Remove and Relocate Featured Image on Blog & Archive Pages | |
remove_action( 'genesis_entry_content', 'genesis_do_post_image', 8 ); | |
add_action( 'genesis_entry_header', 'genesis_do_post_image', 8 ); | |
// Re-position Category Info on Blog & Archive Pages | |
add_action('genesis_before_loop','archive_elements_relocation'); | |
function archive_elements_relocation() { | |
if (is_home() || is_archive() ) { | |
remove_action( 'genesis_entry_header', 'genesis_do_post_title' ); | |
remove_action( 'genesis_entry_footer', 'genesis_post_meta' ); | |
add_action( 'genesis_entry_content', 'genesis_post_info', 8 ); | |
add_action( 'genesis_entry_content', 'genesis_do_post_title', 9); | |
add_action( 'genesis_entry_content', 'genesis_post_meta', 15 ); | |
} | |
if (is_single() ) { | |
remove_action( 'genesis_entry_footer', 'genesis_post_meta' ); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment