Site logo

Archived topic

site header for archives pages

8 replies · Started by paolab on April 30, 2018

Viewing posts 1–9 of 9

Hi,
I'm using a sticky logo for the blog which appears when scrolling down and I'd like to display a static one only in archives taxonomy pages.
I've tried with Page headers widget but doesn't work.
Do have any advice or workaround to solve it?

Hi there,

Not quite sure if I understand.

The page you linked currently doesn't have a navigation or navigation logo.

Can you explain a bit more?

Let me know.

Sorry I'm really not sure what I'm looking at here as I can't seem to navigate to other pages with your current set up.

The method you linked is old. Now we actually have a filter for you to change the logo with:
https://docs.generatepress.com/article/generate_logo/

Let me know if this helps.

Hi Leo,

I'm sorry maybe I haven't explained correctly.
I have a logo site. You can see it when you scroll down
http://it9.siteground.eu/~nesthing/paisanosmodernos/home/
This works perfectly.

But I would like to change the behaviour of the logo site only in tags pages
http://it9.siteground.eu/~nesthing/paisanosmodernos/home/tag/plantas/
Here I want to display a static logo. It's the same logo but static. How could I get this?

I hope that makes sense.

Paola.

No, I don't have any logo in here because it appears fixed in all pages.
I'm using main navigation, sticky.

Where I can add this code?
add_filter( 'generate_logo','tu_custom_about_logo' );
function tu_custom_about_logo( $logo )
{
// If we are on the about page, set our custom logo
if ( is_page( 'about' ) )
return 'URL TO OUR LOGO IN HERE';

// Or else, set the regular logo
return $logo;

}

On a second thought, try uploading a logo in site identity, then add this snippet to remove the header on every page except tags page:

add_action( 'after_setup_theme','lh_remove_header' );
function lh_remove_header() {
    if ( !is_tag() ) {
        remove_action( 'generate_header','generate_construct_header' );
    }
}
This archived topic is closed to new replies.