I need to make the main image on this website change to a background image when viewed on mobile, so that the logo appears in full on the screen. Can you please assist? I have attached a screenshot of how the site looks on mobile.
Thanks! I have input this code but I am still having the same issue. The image looks a bit better on mobile than it was before, but unfortunately the sides of the logo are still slightly cropped.
I have also tried out the following option but that didn’t work either:
Unfortunately, there is no other way with this image, if you have a different image just for mobile screens give me the links and i will create custom CSS just for your mobile phone
Thanks for the code! Unfortunately the problem still isn’t fixed – now when i open the page, this image initially loads as contain, then quickly switches to cover. Is there maybe some other code built in that overrides these settings?
I tried replacing the image file with a vertical image, but that hasn’t solved it either.
Thanks for your patience on this. Unfortunately the code you’ve just provided isn’t working to fix the issue either. I have gone back and re-sized the image to 16:9 to see if that helped, but it’s still not working. New image dimensions are 394x700px, this is the image I am now using:
Previous code is working right now as it should work, under 600px image is changed and your image for mobile devices is displayed, unfortunately, there is no other method code is working, my suggestion is to work with the image, make it a little bit more mobile-friendly, reduce logo width
I have tried to change the logo size and didn’t see any change in how it looks on mobile. So I changed it to a completely different image to test if the image changed.
The files attached show the new mobile test image, and a screenshot showing this image only as a tiny border below the parallax section. The code seems to be defaulting to an overlay of the main parallax image instead of the test image.