MatthijsH Posted November 22, 2022 Share Posted November 22, 2022 Hi there, My goal is to have a fixed background image on my homepage and have the first section slide over it. I got it working on my laptop by using the code below. Unfortunately, when I open the homepage on my phone, the background image does not seem to have the right scale. I've tried a bunch of think, but now I'm stuck. Does anybody know how to fix it? Thank you in advance! 😁 Site url: www.italynotes.com [data-section-id="6361a26d0b428cbd72327846"] .section-background img { display:none; } [data-section-id="6361a26d0b428cbd72327846"] .section-background { background: url('https://images.squarespace-cdn.com/content/v1/6030444c2c8e1b45642b4b42/bf9c2fb8-cdc6-4841-b26f-aa8b9e5b8559/DSCF5035.jpg?format=2500w'); background-attachment: fixed; background-repeat: no-repeat; background-size: cover; background-position: center center; } Link to comment
Solution tuanphan Posted November 25, 2022 Solution Share Posted November 25, 2022 Hi, iOS doesn't support attribute background-attachment: fixed so it will work on Android only No way to fix this. You can consider disable code on mobile. MatthijsH 1 Email me if you have need any help (free, of course.). Answer within 24 hours. Or send to forum message Contact Customer Care - Learn CSS - Buy me a coffee (thank you!) Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment