Site logo

[Resolved] fixed background image in mobile is not shown

Home Forums Support [Resolved] fixed background image in mobile is not shown

Home Forums Support fixed background image in mobile is not shown

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #1807169
    Heinrich

    hi team,

    in a container, when i change a mobile background image to “fixed” it is not longer visible in mobile. ich change back to “scroll” it is visible again.
    how to solve this?

    #1807227
    David
    Staff
    Customer Support

    Hi there,

    a lot of mobile devices will NOT support fixed background images as it requires a lot of processing power and therefore consumes a lot of battery. So the device disables the fixed background… and on iOS there is a many year old Bug that causes the image to be rescaled to a huge size.

    The fix is to disable the fixed background images on touch devices using some CSS:

    @media (pointer: coarse) {
        .gb-container {
            background-attachment: inital !important;
        }
    }
    #1807523
    Heinrich

    hi david, good to know. as a solution, can i handle this with advanced background in gpp? fixed for desktop and scroll for mobile? so i don`t need your css-code?

    #1807532
    David
    Staff
    Customer Support

    With GenerateBlocks Pro you can use the Advanced Background option and set a different background-attachment for Mobile.

    #1807534
    Heinrich

    tks

    #1807607
    David
    Staff
    Customer Support

    You’re welcome

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