Hi there,
Next to my logo, I would like to add a custom icon to my header.
I am using the Crave Theme. How can I do this please?
Hi there,
Next to my logo, I would like to add a custom icon to my header.
I am using the Crave Theme. How can I do this please?
@DGQs , Can you kindly share your store url and icon you want to add ?
Hi @DGQs ,
Please follow the steps to display the icon in the header.
-Prepare the icon in svg or png format.
-Upload the icon to the Shopify store: Admin > Settings > Files.
-Then modify the header file header.liquid in Sections : Online Store > Themes > Actions > Edit code.
-Add the HTML next to the logo code. For example:
{{ 'logo' | image_tag }}
-Replace ‘your-icon.png’ with the actual filename of your uploaded icon.
-Add the code below to theme.css or theme.scss.liquid
.custom-header-icon {
width: 30px;
margin-left: 10px;
}
-Save the changes.
If you need further assistance, feel free to reach out!
If this solution works for you, please like the post and mark it as a solution!
Regards,
Sweans
Hi Sweans, thank you so much already for this. It’s not going smoothly just yet. I get the following notification. I was confused about where to place the first code within the right file. what do you mean with ‘next to the logo code’?
This is the code that I posted at the bottom of the header.liquid in sections:
The error is on the picture