Viewing 13 posts - 1 through 13 (of 13 total)
  • Author
    Posts
  • #372965

    Hi,

    I am having trouble creating a mobile friendly custom background image. The image does not fully appear on a mobile friendly device, but looks fine on a computer. I am not sure if I need to add a custom id attribute to my color section, but can you take a look at the link I provided and provide any assistance.

    Thanks in advance as I have been stumped on this one for a while.

    #373043

    Hey jolamptey!

    You can add following code to Quick CSS in Enfold theme options under General Styling tab

    @media only screen and (max-width: 480px) {
    .home div#av_section_1 { background-size: contain; }}

    Image would be responsive but that would cause a big white space

    Regards,
    Yigit

    #374365

    Hi Yigit,

    Thanks for the prompt response. I entered the information you provided, however nothing has changed when I look at it from a mobile device. The picture is not responsive. Am I doing something wrong?

    #374744

    Hi Yigit,

    I just realized that I was putting the code you provided me into the Google Analytics section instead of the Quick CSS section. I have now corrected that and see the white space you are referring to. Is there any way to avoid that white space?

    My goal was to create a homepage like the following: http://morikami.org with Enfold. Is it possible to do this?

    I am even willing to remove the background image on the mobile view if thats possible? If you could provide me the quick css to do that I would appreciate it.

    Thanks for any help you can provide.

    #374887

    Hey!

    You can remove the background on mobile device with this:

    @media only screen and (max-width: 480px) {
    .home div#av_section_1 { background: none !important; }}

    Regards,
    Ismael

    #374946

    Thanks Ismael, anyway you can help provide me a css entry to remove invisible padding of 640px on the homepage? I was able to remove it in Google Inspector element, however I am not sure how to translate this over to my css file.

    #375074

    Hi!

    Have you removed it already? I cannot see 640px of padding on your home page. If you have not removed it already, please post a screenshot and show

    Cheers!
    Yigit

    #599938

    Hmm I’m having the same issue but when I tried your code it wasn’t working for me.
    The image is perfect on the desktop but the top and sides get cut off on mobile – help!

    #600960

    Hi!


    @rkb317
    : Did you use the color section element? Please provide a link to the page in question. Note that the background size property will be set to “cover” if the “Background Repeat” option is set to “Stretch to Fit”. This means that the image will cover the whole container but it may cut off parts of the image to keep its aspect ratio. http://www.w3schools.com/cssref/css3_pr_background-size.asp

    Regards,
    Ismael

    #601974

    Thanks for the response – yes I did use the color section element…? See link below – can I just add code to just make the image responsive?

    #603719

    Hi!

    try to control the image with this code inside your Quick CSS field:

    .av-parallax-inner.main_color.avia-full-stretch {
    background-position: -45px -27px !important;
    background-size: 105% 88% !important;
    }
    

    If you want to control it on mobile devices then add some media queries to the code:

    @media screen only and (max-width: 767px) {
    .av-parallax-inner.main_color.avia-full-stretch {
    background-position: -45px -27px !important;
    background-size: 105% 88% !important;
    }
    }
    

    and adjust max-width value as needed.

    Cheers!
    Andy

    #751077

    How would you do this to other pages besides the home page?

    #753277

    Hi,

    The code Andy given should be working on other pages as well, it would only apply to homepage if you can see this in the code .home.

    Best regards,
    Nikko

Viewing 13 posts - 1 through 13 (of 13 total)
  • You must be logged in to reply to this topic.