Link to home
Start Free TrialLog in
Avatar of angelic_webmaster
angelic_webmasterFlag for United States of America

asked on

Wordpress - how to make 2 different logos - one on some pages one on others

Here is the website. Trying to make two logos appear. One on a few pages, and another on other pages?

http://www.ronhenrey.com/welcome/
SOLUTION
Avatar of James Rodgers
James Rodgers
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of angelic_webmaster

ASKER

Ok I will try these both and let you know.
My father passed away this last week so I have not been able to respond.
Would this still work on my new template I am using.
<?php
$logoImg = get_post_meta(get_the_ID(),'logo-image');
try
{
	$logoImg = $logoImg[0];
}
catch (Exception $e)
{
	$logoImg = "/wp-content/images/uploads/default-logo.png"; //place a default image here for pages that don't have it set
}
?>
	<img src="<?php	echo $logoImg;?>" alt="Logo"/>

Open in new window


www.ronhenrey.com
re: post 39299292

Yes that should still work.
If you have a custom field  named "logo-image" on a page it should display that image. If you don't have that custom field on a page, it will display the default image.
Thank you all for helping me. The code was great - although I went a different route :)