Background Image

Highlighted
Tourist
10 0 0

Hi,

 

I'm using the debut theme in my store and after doing some research on the internet I still haven't figured out how I can add a background Image to my store...

 

I've tried this code :

body {  background-image:url('https://www.IMAGE_ADDRESS_HERE.jpg');
}

And it works but it duplicates the image to fill the page...


Hope something could help, I'm not very good at editing so I would appreciate step by step help :)

 

Thanks

 

P.S. I haven't launched my store yet.

0 Likes

to add background images :

first way :line 

<div style="background-image: url('{{ 'logo.png' | asset_img_url: '300x' }}');"> 

 

second ways : 

you could past your links of images like:

<style>
body {
  background-image: url('past here your image url');
}

 

</style>

 

to use dynamic images in shopify

:

{{ image | img_url: "medium" }}

 

get images from assets folder:

{{ 'logo.png' | asset_img_url: '300x' }}

Shopify theme developer and customization

Would like to add new functionality or customize an existing one, please hire us.
If helpful then please Like and Accept Solution .
Email: ashiquehussaincodediary@gmail.com
0 Likes
Tourist
10 0 0

I tried all 3 but like I said I'm kind of a noob with editing so I have no idea if I did it right.

 

Could you be a little more specific ?

0 Likes
New Member
3 0 0
    
<style>
body{
background: url('https://www.w3schools.com/w3css/img_lights.jpg');
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
}
</style>

I hope this helps.

0 Likes