Tagged: x
-
AuthorPosts
-
August 29, 2016 at 1:00 pm #1152131
rangerParticipantI was wondering if you guys had some css rules handy so that I can replace the background image I used in Parallax section with a different image when on mobile (and Parallax is disabled). I was hoping I wouldn’t have to dig through the CSS to figure it out.
Thanks
August 29, 2016 at 1:54 pm #1152206
RupokMemberHi there,
Thanks for writing in. You can use CSS like this :
#x-section-1 { background-image: url(//path/to/your/image.png)!important; }Let’s use the correct section ID and replace the image path with your own uploaded image.
If you still need help; kindly provide your URL and point us the section.
Cheers!
August 29, 2016 at 3:15 pm #1152331
rangerParticipantThanks for the answer, but that doesn’t come close to resolving what I asked about.
It is easy to replace an image via CSS, either through that method or using a user defined class.
However, I want to replace an image only for mobile.
When I have a Parallax section in a browser on desktop and I resize the browser the Parallax effect remains active right down to the smallest width. There are CSS rules in place for disabling Parallax mobile only, and I would love if you guys knew them so I didn’t have to try and hunt them down. I’m actually trying to figure out how since the Chrome Inspector doesn’t work (as noted, Parallax remains active on a desktop browser).
August 29, 2016 at 3:37 pm #1152358
JoaoModeratorHi There,
Please try the code below, it will affect just devices smaller than 480px which should be all the mobiles only.
@media only screen and (max-device-width : 480px) { #x-section-1 { background-image: url(//path/to/your/image.png)!important; } }Hope it helps
Joao
-
AuthorPosts
- <script> jQuery(function($){ $("#no-reply-1152131 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>
