Created
September 14, 2019 13:51
-
-
Save topleague/8654081a2ca3d9bf6549cc1ffa3e4277 to your computer and use it in GitHub Desktop.
Show a Logo Before Site Title
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
/*----- Display Logo before Site Title -----*/ | |
add_action( 'genesis_header', 'lwp_site_image', 5 ); | |
function lwp_site_image() { | |
$header_image = get_header_image() ? '<img alt="" src="' . get_header_image() . '" />' : get_avatar( get_option( 'admin_email' ), 224 ); | |
printf( '<div class="site-image">%s</div>', $header_image ); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment