How do I add a background image to the Dawn theme?

natart1999
New Member
3 0 0

I want to add the same background image to all pages in the dawn theme. How do I input that code?

Replies 3 (3)
PaulNewton
Shopify Partner
3512 235 688

https://css-tricks.com/almanac/properties/b/background-image/#images

with https://shopify.dev/api/liquid/filters/url-filters#asset_img_url 

body {
  background: url({{ 'logo.png' | asset_img_url: '300x' }});
}

 

There will be tweaking needing depending on the size of the image, need for responsiveness, whether it should be fixed, etc

 

https://css-tricks.com/perfect-full-page-background-image/ 

 

Merchants wanting this customization can contact me at paull.newton+shopifyforums@gmail.com with store url&pass, and use case details.

What important thing did you learn this Black Friday?


Answers powered by coffee Buy Paul a ☕ Coffee for more answers or donate to eff.org

Problem Solved? ✔Accept and Like solutions to help future merchants

Confused? Busy? Buy a custom solution paull.newton+shopifyforum@gmail.com
natart1999
New Member
3 0 0

Sorry I'm completely new to coding. Where would I put this code? Under Layouts or Assets? Or somewhere else? Which section? I tried putting it in theme.liquid but nothing would show up. 

PaulNewton
Shopify Partner
3512 235 688

It's CSS code put it in CSS files ,normally theme.css or custom.css

Always backup your theme before making changes.

What important thing did you learn this Black Friday?


Answers powered by coffee Buy Paul a ☕ Coffee for more answers or donate to eff.org

Problem Solved? ✔Accept and Like solutions to help future merchants

Confused? Busy? Buy a custom solution paull.newton+shopifyforum@gmail.com