Different header logo for different collections for Debut theme

Solved
Excursionist
14 1 1

Hi there, I'm trying to change the CSS code on my website so I am able to show a different header logo on various collection pages. I managed to add a css code so my main logo is hidden on only the collection pages, but I want that logo to be replaced with a different one for certain collections.

 

How would I go about this? 

0 Likes
Highlighted
Trailblazer
192 33 46
{% if collection.handle == 'collection handle 1' or collection.handle == 'collection handle 2' or collection.handle == 'collection handle 3'%}
<img src="logo-2.png" alt="logo 2">
{% endif %}

You can use this method.Put on top of the logo that is hidden in collection.

1 Like
Highlighted
Excursionist
14 1 1

Thank you. Where and in which file would I have to put this? The header.liquid file, right?

0 Likes
Highlighted

Success.

Trailblazer
192 33 46

I think shd be the header.On top of the logo you hide.

1 Like
Highlighted
Excursionist
14 1 1

Thanks, had to look around a bit in the file but it worked! 

0 Likes
Highlighted
New Member
1 0 0
Any chance of a screenshot to see exactly where it goes in header.liquid?
0 Likes
Highlighted
Excursionist
14 1 1

Look for the following text in header.liquid in Debut and copy the code above it, there's how it worked for me:

 

 {% comment %}
          Use the uploaded logo from theme settings if enabled.
          Site name gets precedence with H1 tag on homepage, div on other pages.
0 Likes