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 hamburger menu icon appears as letter "a"

Discussion in 'Basic Support Forum' started by ThemeUser, Apr 29, 2020.

  1. ThemeUser

    ThemeUser Member
    Divi Ultimate Child Theme Divi Powerful Child Theme Divi Ultimate Archive Plugin Divi Ultimate Blog Plugin Divi Ultimate Header Plugin Divi Ultimate Footer Plugin

    I don't know if you can offer a solution to this, but there is an issue with Divi's font-icon hamburger menu displaying improperly when users are on a slow cellular connection such as 3G. What happens is that the hamburger does not initially display. Instead, a lowercase "a" appears, and then eventually the hamburger replaces it.

    So, I would like to substitute the font icon with a .png to avoid the letter "a" appearing. But, when I tried to do that, I could not scale down the .png to the correct size (29px x 19px for a phone). I tried various instances of "width" and "max-width", with and without "!important", but could not get the hamburger .png to size correctly.

    If you are able to help, could you tell me what is missing in my code below?


    I changed CSS from this...

    @media only screen and (max-width: 767px) {
    .mobile_menu_bar:before {
    font-size: 45px;
    margin-left: -6px;
    }
    }


    To this...

    @media only screen and (max-width: 767px) {
    .mobile_menu_bar:before {
    content: url("/wp-content/uploads/hamburger.png") !important;
    margin-left: -6px;
    }
    }


    (Please note that I omitted any "height" and "width" settings from the second piece of code above, as they did not have any effect on the hamburger.png.

    I would prefer to send you a PM with the URL, as this is a client site in progress. Thanks for your understanding.
     

    Attached Files:

    1. PRO MEMBER PERKS Divi Block Pro - Premade slide in bar design for your Divi site without using any plugins:View Demo
  2. Divi.Help Pro Support

    Divi.Help Pro Support Administrator
    Staff Member

  3. ThemeUser

    ThemeUser Member
    Divi Ultimate Child Theme Divi Powerful Child Theme Divi Ultimate Archive Plugin Divi Ultimate Blog Plugin Divi Ultimate Header Plugin Divi Ultimate Footer Plugin

    Wow! That was an incredibly fast response which gave me all the code I needed to get this header back on track. Many thanks!
     
    1. PRO MEMBER PERKS Divi Block Pro - Premade content toggle design for your Divi site without using any plugins:View Demo
  4. ThemeUser

    ThemeUser Member
    Divi Ultimate Child Theme Divi Powerful Child Theme Divi Ultimate Archive Plugin Divi Ultimate Blog Plugin Divi Ultimate Header Plugin Divi Ultimate Footer Plugin

    I am very sorry to trouble you with this, but the hamburger PNG has suddenly disappeared from the site without me changing any CSS. The PNG also has not been modified or deleted. I have also tried deactivating plugins, and updating to the latest Divi, but that does not work either. Is there any code which you might add which would ensure that the hamburger PNG is always displayed?

    I have sent you a PM with the URL for this client site.

    Here is the code that was working before:


    /*--------Hamburger--------*/

    /*---Tablet---*/
    @media only screen and (min-width: 768px) and (max-width: 980px) {
    /*Hamburger PNG*/
    .mobile_menu_bar:before {
    content: ''!important;
    margin-left: 32px;
    margin-top: -20px;
    width: 34px!important;
    height: 20px!important;
    display: block!important;
    background-image: url("/wp-content/uploads/hamburger.png")!important;
    background-size: contain;
    background-repeat: no-repeat;
    top: 36px;
    }
    /*Close X FONT*/
    .mobile_menu_bar:after {
    font-size: 50px;
    padding-left: 73px !important;
    }
    }

    /*---Phone---*/
    @media only screen and (max-width: 767px) {
    /*Hamburger PNG*/
    .mobile_menu_bar:before {
    content: ''!important;
    margin-left: 2px;
    margin-top: -19px;
    width: 29px!important;
    height: 19px!important;
    display: block!important;
    background-image: url("/wp-content/uploads/hamburger.png")!important;
    background-size: contain;
    background-repeat: no-repeat;
    top: 32px;
    }
    /*Close X FONT*/
    .mobile_menu_bar:after {
    font-size: 45px;
    padding-left: 33px !important;
    }
    }



    Thanks again for your fantastic support.
     
  5. ThemeUser

    ThemeUser Member
    Divi Ultimate Child Theme Divi Powerful Child Theme Divi Ultimate Archive Plugin Divi Ultimate Blog Plugin Divi Ultimate Header Plugin Divi Ultimate Footer Plugin

    An update:

    I was able to troubleshoot this.

    The problem with the code suddenly not working was due to a setting with the SG Optimizer plugin. When the plugin's "Combine CSS Files" setting was turned off, the problem disappeared.

    Sorry for the confusion.
     
    Divi.Help Pro Support likes this.
    1. PRO MEMBER PERKS Divi Block Pro - Premade dynamic background hover design for your Divi site without using any plugins:View Demo