Created
January 27, 2015 17:37
-
-
Save eri-trabiccolo/c17629195d5416859da2 to your computer and use it in GitHub Desktop.
Add a full width widget area before customizr colophon
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 widget area between footer widgets and colophon */ | |
add_filter( 'tc_default_widgets' , 'add_footer_colophon_widget' ); | |
function add_footer_colophon_widget( $defaults ) { | |
$defaults['fc_widgets'] = array( | |
'name' => __( 'Footer Colophon Widget' , 'customizr' ), | |
'description' => __( 'Widget Area Before Colophon' , 'customizr' ) | |
); | |
return $defaults; | |
} | |
add_action('__footer' , 'display_my_fc_widget', 11 ); | |
function display_my_fc_widget() { | |
echo '<div class="footer-colophon">'; | |
dynamic_sidebar('fc_widgets'); | |
echo '</div>'; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment