Tagged: 

Viewing 22 posts - 1 through 22 (of 22 total)
  • Author
    Posts
  • #769473

    Hi,

    I was wondering if it was possible to highlight the current parent menu in the mobile menu. E.g. I open the menu that says ‘About’ and the submenus shows. The About will then be highlighted with an underline to show that this is the menu in which you are currently looking at submenus. The same thing happens if I open up one of the submenus that is a parent menu. Hope it makes sense.

    Best regards,
    M

    #769614

    Hey m9491,
    Please try adding this to quick css:

    @media only screen and (max-width: 767px)  {
    .current-menu-ancestor.menu-item-has-children.menu-item-top-level a avia-menu-text{
    text-decoration:underline!important;
    }
    }

    Let me know if this works for you.

    Best regards,
    Jordan Shannon

    #769824

    Thanks for the answer. Unfortunately, it didn’t work. Can it be done with a CSS only, or do I need to change something in the avia.js file? I’ve been looking there too in the if-sentence that opens the submenus.

    #769830

    Hi,

    Try using this css code:

    @media only screen and (max-width:767px) {
      #mobile-advanced .current-menu-ancestor > a > span.avia-menu-text {
        text-decoration: underline;
      }
    }

    Let us know if this helps :)

    Best regards,
    Nikko

    #769832

    There was an underline on the first item whether or not the submenu was open. But not on the rest of the parent menus (see image).

    Also adding a login, just in case.

    #769848

    Hi,

    Please remove the code I gave. That’s not possible with css, that will need a jquery script. I’ll try to make one.

    Best regards,
    Nikko

    #769852

    I’ve removed the CSS now.

    #769880

    Hi,

    Thanks for removing it and providing the login details, I added this code at the bottom of functions.php:

    function add_custom_script(){
    ?>
    <script>
    $(window).load(function () {
      $('#mobile-advanced > li > a').on('click', function() {
       $(this).toggleClass('menu_underline');	  
      });
    });
    </script>
    <?php
    }
    add_action('wp_footer', 'add_custom_script');

    was planning to integrate it with your other js code but doesn’t work, I just made a separate one (which can be used by others). And on Quick CSS, located in Enfold > General Styling, I added this css code a the bottom:

    #mobile-advanced a.menu_underline {
        text-decoration: underline;
    }

    it should be good. I also noticed the hamburger menu is a bit out of place, do you want us to help with that also?

    Best regards,
    Nikko

    #769894

    Hi again,

    Thanks for the code! It works perfectly on 1st level parent menus. Is it possible to do the same on the parent menus on the other levels? Or is it easy enough to add in the jQuery code you added?

    If you have time you are much welcome to look at the hamburger icon’s position. I’ve added the icon where the original icon used to be, but when you make the browser window smaller/bigger it doesn’t stay in place and I don’t know why it’s doing that. I’ve used this styling:

    #hamburger-icon {
    width:45px;
    height:45px;
    position:absolute;
    display:block;

    top: 60px !important;
    right: 20px !important;

    z-index: 99999999;
    }

    #769900

    Hi,

    For the hamburger icon try to change this:

    top: 60px !important;

    to:

    top: 100px !important;

    just adjust it a bit.

    As for the code I gave try to change this:

    $('#mobile-advanced > li > a').on('click', function() {

    to this one:

    $('#mobile-advanced li > a').on('click', function() {

    Hope this helps :)

    Best regards,
    Nikko

    #769908

    That works wonderful. Thank you!

    Just one last question. When I open the mobile menu, the footer sometimes/sometimes not shows in addition to the menu. Is this a bug or is there a way to make sure the footer is not showing when I open the mobile menu?

    #770547

    Hi,

    I’m not sure I understand your last question, could you post a screenshot of the problem please?

    Best regards,
    Rikard

    #770965

    The footer is still showing, when I open the mobile menu. See attached image.
    We wish to only be able to see the menu when clicking on the hamburger icon.

    #772406

    Hi,

    Sorry for late response, can you try to add this code at the bottom of functions.php:

    add_action('avia_builder_mode', "builder_set_debug");
    function builder_set_debug() {
        return "debug";
    }

    The reason it’s not working on homepage is because the structure is a bit changed, with the code added it will show the shortcodes used and might show us what the problem is. Let us know if you have added this :)

    Best regards,
    Nikko

    #772458

    Hi Nikko,

    I’ve added the code to the functions.php now.

    Best regards,
    M

    #775961

    Hi,

    please keep everything up to date inside your backend, especially the theme.
    Please deactivate all plugins one by one to check which one is causing this issue and let us know if this solves the problem. If it doesn’t then any customizations you’ve done are causing this issue, so remove all of them to check if this is true.

    Best regards,
    Andy

    #779242

    Hi Andy,

    Thanks for the tip! I checked the plugins and it turns out it’s the wp-Typography plugin that is causing the trouble. Do you have any plugins like this that you suggest to use with Enfold?

    Best regards,
    M

    #779330

    Hi,

    I’m guessing that it adds fonts to your site? If you need to add fonts then you can refer to this: http://kriesi.at/documentation/enfold/register-additional-google-fonts-for-theme-options/, or add them using CSS.

    Best regards,
    Rikard

    #779343

    Oh, sorry. It helps dividing long words with hyphens, whenever needed. It’s like Hyphenator, but a little more advanced.
    https://wordpress.org/plugins/hyphenator/
    https://wordpress.org/plugins/wp-typography/

    #779416

    Hi,

    best to talk with plugin’s author if this plugin is conflicting with Enfold. If he can’t help you, I would search for another plugin.

    Best regards,
    Andy

    #779892

    Hi again,

    Thank you for your help. It’s very much appreciated!
    I will see if I can get into contact with the plugin’s author.

    Best regards,
    M

    #780277

    Hi,

    Ok, thanks for the feedback. Please let us know if you should need any further help on the topic.

    Best regards,
    Rikard

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