-
-
Save KnowTheCodePro/b1e13fe1d5667b35274130202ca3e64e to your computer and use it in GitHub Desktop.
Problem Solving Lab - Repositioning Post Info doesn't work on the first post. Why?
This file contains 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
add_action( 'genesis_entry_header', 'reposition_post_info_above_entry_title', 1 ); | |
/** | |
* Reposition the post info above the entry title. | |
* | |
* @since 1.0.0 | |
* | |
* @return void | |
*/ | |
function reposition_post_info_above_entry_title() { | |
if ( ! is_front_page() && ! is_home() && ! is_archive() ) { | |
return; | |
} | |
remove_action( 'genesis_entry_header', 'genesis_post_info', 12 ); | |
add_action( 'genesis_entry_header', 'genesis_post_info', 7 ); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment