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

Solved Header 12. Change background color on Scroll. Works but displays changed color on page load.

Discussion in 'Basic Support Forum' started by Darick Dunaway, Jul 25, 2020.

  1. Darick Dunaway

    Darick Dunaway New Member

    Hello thanks for all your help and I have another question. Using header 12 I want to change the color of the background when I scroll. I have implemented this and it works as intended besides when the page loads. The changed color is already displaying. If I scroll down and scroll back up the menu changes in the way it's intended just not on the original page load. I have added a link below and have pasted in the code that i have edited. Thanks!

    https://www.smartdata.net/

    Code added to header 12 code section:

    .pa-header {
    background: transparent;
    -webkit-transition: background-color 1s ease-out;
    -moz-transition: background-color 1s ease-out;
    -o-transition: background-color 1s ease-out;
    transition: background-color 1s ease-out;
    }

    .pa-fixed-header {
    background-color: rgba(0,0,0,0.8);
    -webkit-transition: background-color 1s ease-out;
    -moz-transition: background-color 1s ease-out;
    -o-transition: background-color 1s ease-out;
    transition: background-color 1s ease-out;
    }
     
    1. PRO MEMBER PERKS Divi Ultimate Archive Plugin - Replace the default archive "Older Entries" with beautiful pagination:Learn More
  2. Divi.Help Pro Support

    Divi.Help Pro Support Administrator
    Staff Member

    Not sure which plugin you're using for the fixed header. They somehow indicated it as 'fixed' on page load.

    If you choose to use our sticky feature instead, go to the Section Settings > Advanced > CSS Class & add free-sticky free-sticky-mobile-show

    As for the CSS, use the below:
    Code:
    Log In or Sign Up to view this code.
     
  3. Darick Dunaway

    Darick Dunaway New Member

    While that worked in not having the menu background display black. The menu is now loading in its own section above the page sections, it is not loading overtop of the section below like before. Check link now https://www.smartdata.net/ Thanks very much and sorry for the confusion
     
    1. PRO MEMBER PERKS Divi.Help Pro Layout Packs - Agency Divi layout pack featuring unique comment design on single blog post page:View Demo
  4. Divi.Help Pro Support

    Divi.Help Pro Support Administrator
    Staff Member

    Try to add the below CSS as well & see if it works:
    Code:
    Log In or Sign Up to view this code.
     
  5. Darick Dunaway

    Darick Dunaway New Member

    That worked perfectly! Thanks again so much for the help you guys are the best!
     
    1. PRO MEMBER PERKS Divi Ultimate Blog Plugin - Easily set awesome default design for your Divi single blog page:Learn More