My new page template works fine with this call, <?php get_header(); ?> but not with this call (I get a blank Page), <?php get_header2(); ?>.
I have renamed "header" to "header2" to test and once the name changes it does not work.
How do I get header2 to work? Do I need to add something to functions.php?
ClaytonJames
Member
Posted 1 month ago #
Does it need to be expressed a little differently? I only pose that as a question because I am not sure myself.
<?php get_header( $name ); ?>
Reference: http://codex.wordpress.org/Function_Reference/get_header
Thanks Clayton, I used that from the codex as well putting the file name, header2.php where the $name was but it still brought up the default header.
I am now using a plugin for dynamic headers, http://nicasiodesign.com/blog/category/wordpress-plugins/. I probably should have done this right-off instead of wasting a rainy day.
This lets me change the image although I wanted to change some info in the header itself like some of the meta.
ClaytonJames
Member
Posted 1 month ago #
I bookmarked the link. It might come in handy in the future. Thanks!
Just for info:
get_header('myheader'); // will include header-myheader.php
get_footer('myfooter'); // will include footer-myfooter.php
get_sidebar('mysidebar'); // will include sidebar-mysidebar.php