different image for mobile and Desktop

different image for mobile and Desktop

ai41
Explorer
76 0 19

i want to use two different photo for mobile and Desktop , i used image banner , but i face this problem in mobile screen, that the image for mobile not showing full 

could you please help me to solve it 

 

URL: saintalen.com

 

 

 

 

 

 

 

ai41_0-1733401821155.png

 

 

 

 

Replies 6 (6)

steve_michael2
Navigator
445 38 61

Hi @ai41 ,

1. Go to Online Store -> Theme -> Edit code.
2. Open your theme.css / based.css file and paste the code in the bottom of the file.

@media screen and (max-width: 749px) {
    .banner--stacked.banner--adapt:not(.banner--mobile-bottom) .banner__content {
        position: static; !important
    }
   .banner--mobile-bottom .banner__media, .banner--stacked:not(.banner--mobile-bottom) .banner__media {
        position: static !important;
    }
}

 

If my reply is helpful, kindly click like and mark it as an accepted solution.

If you are happy with my help, you can help me buy a COFFEE

Thanks!

 

steve_michael2
Navigator
445 38 61

Hi @ai41 ,

The issue you were facing on the mobile screen has been resolved. I provided the code, and now the image appears full on the mobile screen.

ai41
Explorer
76 0 19

it did not work

 

steve_michael2
Navigator
445 38 61

Hi @ai41 

steve_michael2_0-1733409415049.png

 

ai41
Explorer
76 0 19

YEAH ITS WORKING , BUT NOT USING YOUR CODE , I FINDOUT WAY , THANK YOU

Made4uo-Ribe
Shopify Partner
10196 2420 3064

Hi @ai41 

Try this one. 

  1. From your Shopify admin dashboard, click on "Online Store" and then "Themes".
  2. Find the theme that you want to edit and click on "Actions" and then "Edit code".
  3. In the "Assets" folder, click on "base.css, style.css or theme.css" file, depending on which file your theme uses to store its CSS styles. At the bottom of the file, add the following CSS code:

 

@media only screen and (max-width: 749px){
div#Banner-template--18388846379263__image_banner_eDbLHP .media > img {
    object-fit: fill;
}
}

 

  • And Save.
  • Result:
  • Made4uoRibe_0-1733405767756.png

     

 

 Your Feedback Matters! Please mark the solution and give likes to posts that helped you. Your appreciation fuels our motivation to assist you better! 

If this fixed your issue, Likes and Accept as Solution are highly appreciated. Coffee tips fuel my dedication.
Get experienced Shopify developers at affordable rates—visit Made4Uo.com for a quick quote!
Need THEME UPDATES but have custom codes? No worries, for an affordable price.