I saw this code while looking into a solution to have the logo and link to change based on the post type you are viewing.
I would like to change the home logo and link while you a viewing a custom post type to have a different logo and link something like – site.com/custom-post-type.
Is there a way to use this code and change the link as well?
add_filter(‘avf_logo’,’av_change_logo’);
function av_change_logo($logo)
{
if(is_tax(‘portfolio_entries’,’south-canterbury-past-issues’) )
{
$logo = “http://kriesi.at/wp-content/themes/kriesi/images/logo.png”;
}
return $logo;
}
Thanks in advance.
Hey frankster1234,
Try adding this code as well:
add_filter('avf_logo','av_change_logo_url');
function av_change_logo_url($url)
{
if(is_tax(‘portfolio_entries’,’south-canterbury-past-issues’))
{
$url = "http://link.to/img.png";
}
return $url;
}
Best regards,
Jordan