Last active
December 17, 2015 02:49
-
-
Save braddalton/5539151 to your computer and use it in GitHub Desktop.
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
// Register full-width content widget | |
genesis_register_sidebar( array( | |
'id' => 'full-content', | |
'name' => __( 'Full Content', 'child' ), | |
'description' => __( 'This is the full-width content section.', 'child' ), | |
) ); | |
/** | |
* Author Brad Dalton | |
* @link http://wpsites.net/ | |
*/ | |
// Display Widget Content After Header Home Page Only | |
function wpsites_full_width_content() { | |
if ( is_home() && is_active_sidebar( 'full-content' ) ) { | |
echo '<div id="full-content">'; | |
dynamic_sidebar( 'full-content' ); | |
echo '</div><!-- end #full-content -->'; | |
} | |
} | |
add_action ( 'genesis_after_header', 'wpsites_full_width_content' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment