Upload SVG file to header logo on craft theme

Solved

Upload SVG file to header logo on craft theme

Kimwaxler
Tourist
9 1 0

Hello.

I don't know what I am doing here😫

It seems like wants to work but image doesn't show there.

スクリーンショット 2025-01-19 17.06.37.pngスクリーンショット 2025-01-19 17.06.51.png

Accepted Solution (1)
Kimwaxler
Tourist
9 1 0

This is an accepted solution.

Hi, thank you to the people who help me with this. I figure it out. It's solved! Thank you😉

View solution in original post

Replies 7 (7)

Supporter
Excursionist
62 1 4

hi @Kimwaxler Have you upload the image with the same name as logo.svg and why are you adding the logo through code.

Kimwaxler
Tourist
9 1 0

I tried to upload from the theme setting but It failed to upload an SVG file.

htmlBurger
Shopify Partner
83 7 20

Hello,

 

Please try changing the <img> line with this:

<img src="{{ 'logo.svg' | asset_url }}"/>

 

This will load the logo.svg file from the main assets folder using the correct path.


Let me know if it worked.

Found this helpful? Like and accept as solution to help others too!
htmlBurger – Founded in 2007, Shopify experts for 10+ years.
Custom themes, UI/UX design, ongoing maintenance & support.
Let's talk: ecom@htmlburger.com
Kimwaxler
Tourist
9 1 0

Hi, thank you for your help.

It still doesn't work 😢

 

Supporter
Excursionist
62 1 4

can you add me as collaborator so I can see the problem. 

Kimwaxler
Tourist
9 1 0

Hi, actually, I was able to upload it, but now I have a problem: It is a little small for me.

Kimwaxler
Tourist
9 1 0

This is an accepted solution.

Hi, thank you to the people who help me with this. I figure it out. It's solved! Thank you😉