Different Header on SOME static pages
-
Hello,
I am trying to use two different color headers on the site:
https://bulldawgtraining.com/wordpress1/
The Home page and default pages should have a red logo in the header. All pages related to Physical Therapy https://bulldawgtraining.com/wordpress1/physical-therapy/
should have a blue logo. There will be about 5 pages with the blue logo – I can set them all in the “if(is_page) code as I did for the current blue page. However, then all the other pages have no logo … how do I set that at the end with php?I have set these two pages specifically in the header.php file as follows:
[ Moderator Note: Please post code or markup snippets between backticks or use the code button. As it stands, your code may now have been permanently damaged/corrupted by the forum’s parser. Or use pastebin.com instead. ]
<body <?php body_class(); ?>> <div id="wrapper" class="hfeed"> <div id="header"> <?php if(is_page('Physical Therapy') ): // Physical Therapy?> <img src="https://bulldawgtraining.com/wordpress1/wp-content/uploads/2012/10/Bull-Dog-Logo-Final-Lotus-BLUE.jpg" width="350px"> <?php elseif(is_front_page() )://front_page ?> <img src="https://bulldawgtraining.com/wordpress1/wp-content/uploads/2012/07/bulldawg-logo.jpg" width="350px"> <?php endif; // end the if, no images for other categories ?> <div class="logo-address"> 571-970-6068 5001-A Lee Highway Suite 102 Arlington, VA 22207 <ul> <li><form role="search" method="get" id="searchform" action="https://bulldawgtraining.com/wordpress1/" > <div><label class="screen-reader-text" for="s">Search for:</label> <input type="text" value="" name="s" id="s" /> <input type="submit" id="searchsubmit" value="Search" /> </div> </form></li> </ul> </div><!-- #logo-address--> </div><!-- #header -->
But want to be able to apply a default red logo to “else.” can someone please suggest how to do this?
- The topic ‘Different Header on SOME static pages’ is closed to new replies.