Last active
March 4, 2017 23:29
-
-
Save waynebcox/64dec0f1d4762eeb33fc9d79745c7459 to your computer and use it in GitHub Desktop.
[ Genesis ] Add full width area above header
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
add_action( 'genesis_header', 'utility_bar' ); | |
/** | |
* Add utility bar above header. | |
*/ | |
function utility_bar() { | |
echo '<div class="header-top">'; | |
genesis_widget_area( 'top-header-bar', array( | |
'before' => '<div class="utility-bar"><div class="wrap">', | |
'after' => '</div></div>', | |
) ); | |
echo '</div>'; | |
} | |
//* Register widget areas | |
genesis_register_sidebar( array( | |
'id' => 'utility-bar', | |
'name' => __( 'Top Header Bar', '[ theme-name ]' ), | |
'description' => __( 'This is the top bar section on the header.', '[ theme-name ]' ), | |
) ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment