I have tried adding a custom image background to all the webpages in my website except the header and footer by:
- Creating a file under snippets folder named background-image.liquid and adding the code below:
<style>
html, body,
[id*='shopify-section']:not([id*='announcement']):not([id*='header']):not([id*='footer']),
[id*='shopify-section']:not([id*='announcement']):not([id*='header']):not([id*='footer'])> [class*='background']{
background: url("https://cdn.shopify.com/s/files/1/0725/0309/9644/files/Textured_background.webp?v=1736680999") !important;
background-size: cover !important;
}
</style>
- The I added a single line of code given below under the body in the theme.liquid file
{% include 'background-image' %}
This code almost worked and as I wanted it is not being applied to the header and footer. But also it is not being applied to some sections like multirows, image banner(with a png image), richtext, collage, featured collection, contact form and mostly all the sections.
website: https://corenhance.store
password: [email removed]
theme: craft
Now I am seeking for a solution for this.
Any kinds of help is appreciable. Thank You ![]()



