I'd like to add content directly after the div#main
(end of header.php
) and before /div#main
(beginning of footer.php
).
I'm using an own child-template (of twentythirteen), that contains only
style.css
and functions.php
at the moment.
I added the following content to my functions.php
function myAddedStuff() {
echo "Stuff";
}
add_action( 'get_header', 'myAddedStuff' );
add_action( 'get_footer', 'myAddedStuff' );
For the footer it works well, since myAddedStuff()
is executed, before get_footer
. But for get_header
I'd like to execute myAddedStuff()
afterwards. How can I do that.
Should I use an alternative hook? How can I easily find hooks? Is the an easy way to add contents to certain HTML commands? (e.g. use div#main
as a "hook").