-
AuthorPosts
-
October 21, 2014 at 5:09 pm #129523
Hi,
for some reason when I put a background pic in the content band (blank – no container) it makes a huge difference regarding the image section that is displayed, depending if its with parallax effect or not. How can I integrate a background pic, with parallax effect but without zooming and loosing quality because of that? It should be displayed exactly as a normal background pic regarding with, only with parallax effect.
Thanks much!October 21, 2014 at 5:11 pm #129528This reply has been marked as private.October 22, 2014 at 4:30 am #129788Hi Anja,
To fix the parallax, You can add this under Custom > CSS in the Customizer.
.x-content-band.bg-image { background-size:contain !important; }
October 24, 2014 at 10:17 am #131548This reply has been marked as private.October 24, 2014 at 12:12 pm #131632Hi Anja,
The above given CSS will force the background to remain inside the content band, however you can use following CSS code instead, which will show the original size of the image:
.x-content-band.bg-image { -webkit-background-size: auto !important; background-size: auto !important; }
To use images with parallax, you can try using the images of double height of the content band.
Thanks!
October 28, 2014 at 6:30 am #133625This reply has been marked as private.October 28, 2014 at 9:39 am #133739Hi Anja,
By default your background-position is set to 50% 50%, but then as soon it loads, it is set to 50% 14px. So the jump comes from the vertical position changing from centered to calculated. You can try using following CSS code to avoid this:
.x-content-band.bg-image.parallax { background-position: 50% 0px; }
Hope this helps. 🙂
Thank you.
October 29, 2014 at 10:13 am #134446Thanks!
Just in case other people have the same problem, it worked with
.x-content-band.bg-image.parallax { background-position: 50% 0px !important; }
🙂
October 29, 2014 at 6:03 pm #134709Hi Anja,
Glad you’ve sorted it out. Just for the background color problem, you can fix it by adding custom CSS:
.x-content-band { border-top: none !important; }
Cheers!
December 8, 2014 at 1:56 pm #160663Hi,
I had the same problem and so I used the “contain” CSS above. However, the image appears a bit too high, leaving a white space in the bottom of the content band (see http://sigmastatus.com/assessment-2/.
Earlier I tried using a vertical position CSS but that messed up the parallax in Chrome and Firefox.
Any way to get the image to position itself right below the menu bar? The image actually begins at the top of the guy’s hat.
Thanks!
December 9, 2014 at 1:27 am #160928Hi Captsalalander,
Thanks for writing in!
In that case, please try using following code instead under Custom > CSS in the Customizer:
#x-content-band-1.bg-image.parallax { background-position: 50% 76px !important; }
Hope this helps. 🙂
Thank you.
December 9, 2014 at 10:35 am #161257Sort of works. The problem is that the gap is different in each browser. To get it to work in Safari, the number has to be higher, which then leaves a white band at the top of the image.
I’m really struggling with this issue. I’ve attempted to crop my images in multiple ways, which never seems to be consistent when put into a background. In all cases, the content band crops off the sides of the image and zooms in. Using the “contain” CSS is the closest I can come to making this work, and now it’s different across browsers.
The other issue is that my other background images are being affected as well. Example: on my homepage I have background images in bands 6 and 8 (http://sigmastatus.com).
What is your suggestion of the best way to approach this? I was able to make homepage bands 6 and 8 look right because the bands were taller, but the “contain” CSS has inserted a white band at the top of those, which screws up their placement. Why doesn’t the band crop the top and bottom of the image instead of the sides?
Thanks for helping with this. It’s the last major issue I have to figure out to complete this site.
While I wait for your response I’ll see if I can crop the images to work with the current “contain” CSS.
December 9, 2014 at 10:56 am #161270PS “Contained” combined with judicious cropping seems to work ok but requires a lot of trial and error, so if you have a suggestion, I’m all ears.
Thanks!
December 9, 2014 at 11:41 pm #161607Hi,
Sorry to hear that you are having difficulty making this work.
The contain code scale the image to the largest size such that both its width and its height can fit inside the content area.
by using it you need to make sure your original image size is bigger or equal with the width of the container to prevent it
from being blurry.Because every background image looks different I am sorry but the only way to make it work is to crop the image and adjust it’s background position to make it look the way you want.
Thanks
December 10, 2014 at 9:47 am #161947Thanks.
-
AuthorPosts