1. PROMO Subscribe our All Access Pass @ 75% OFF & access all our 16+ premium Divi extensions: Divi Block Pro, Carousel Toolkit, etc.LEARN MORE
Dismiss Notice
NEW Divi.Help Pro Carousel AI Toolkit - Magically turn your Divi design into carousel, simply by using our online toolkit. No plugins needed. Now it works with Divi 5 as well!Try our carousel AI toolkit
BEST Divi Block - A revolutionary drag & drop tool to easily mix & match 960+ premade blocks (Light & Dark) to kick start your Divi site design. Special module designs are included as well. Also newly added AI generator & color. Now it works with Divi 5 as well!
Learn More About Divi BlockFree Version ~ 340+ Free Blocks

Accordion module shortens the parallax background image height.

Discussion in 'Free Divi Community Forum' started by sunbow, Apr 25, 2020.

  1. sunbow

    sunbow New Member

    Hi!

    I'm developing a website with a large static background image defined in the Divi theme builder's global body. The image's parallax option is 'CSS', but same problem occurs with True parallax option.

    On a page with an accordion module, the background image is cut on the top each time a lower item is selected and a white stripes appears on top of the page.

    For some unexpected reasons the default "height:100%" of the et_parallax_bg class is overridden by calling the style function to change the image's height with a pixel value that changes for each accordion's item.

    Anybody has an idea where in the code this style function is called by?

    I'm not a specialist of PHP and web... But can do anything you want with C++ and a MCU.
     
    1. PRO MEMBER PERKS Divi Ultimate Archive Plugin - Replace the default archive "Older Entries" with beautiful pagination:Learn More
  2. Divi.Help

    Divi.Help Administrator
    Staff Member

    Not quite sure what you meant. Kindly share your URL.
     
  3. sunbow

    sunbow New Member

    I have some more information: The problem is not directly linked to the accordion or toggle module (yes, it is also concerned, as I think any module that implies a section's height adjustment over a parallax background defined in a higher order section)...
    It is bound to the dynamic resizing of the section containing the module: When the section is resized, specially when it is shortened, it changes the 'height' property of the .et_parallax_bg class as explained above, and it cuts the top of the image.
    If you impose a minimum height in pixels for the section, with a higher value than the longest possible deployment, the problem disappears.
    The workaround is obvious: impose the height: 100% of the class with an !important tag:

    .et_parallax_bg{
    height:100%;!important
    }

    And this value isn't overridden by the function call.
    As I have a solution, I won't jam my website to make a demonstration... But it's easy to check: My template is a child clone of Divi 4.4.4 with no customization except the definition of the background image and post-content row in the global body layout.

    Hope it helps.
     
    1. PRO MEMBER PERKS Divi.Help Header AI Generator - Try the power of AI to generate a custom Divi header for you:Try Now
  4. Divi.Help

    Divi.Help Administrator
    Staff Member

    Got it. Just tested on my side & your solution does fix the issue. But that only apply for the CSS parallax, not True parallax.

    If you want, you may report it to official Divi support & see if they can fix their parallax issue on dynamic section height : https://www.elegantthemes.com/members-area/help/