How To Collapse Divi Mobile Menu Submenus

Поделиться
HTML-код
  • Опубликовано: 19 окт 2020
  • In this tutorial I will show you the best and easiest way to collapse the Divi mobile menu submenus and add toggle icons that look great!
    Blog Post & Snippets: www.peeayecreative.com/how-to...
    A Beautiful Way To Collapse And Style The Divi Mobile Menu
    One of the most common requests from our popular Divi Mobile Menu Styling Tutorial is the ability to collapse the submenu items. So today I am showing you what I believe is the best and easiest way to do this. I’ll also add some great looking toggle icons and show you how to style those as well. This tutorial is best used along with some of our other Divi Menu Tutorials to get a well rounded beautiful Divi mobile menu.
    Add Some JQuery To Collapse The Divi Mobile Menu Submenus
    The idea here is to change the Divi mobile menu from a boring, expanded list to a beautiful compact list. We can do this by adding some jQuery and CSS code. This will not only collapse the mobile Divi menu submenu, but also will add some nice toggles that can be used to indicate to the user that there are more items to show and where to click. This tutorial comes in two parts, one for each type of code. Both of them work together and both are needed to make it work.
    Add Some CSS To Collapse The Divi Mobile Menu Submenus
    The next step is to add the corresponding CSS code. This code works alongside the JQuery and together they create the Divi mobile menu collapsed effect.
    Become a member of our Divi Adventure Club!
    www.peeayecreative.com/produc...
    Join The Divi Teacher Facebook group: / thediviteacher
    Visit our Divi child themes, plugins, tutorials, and courses here: www.peeayecreative.com/
    Thanks for watching!

Комментарии • 163

  • @BennyHozjan
    @BennyHozjan 3 года назад +3

    Great Tutorial... you're the first one with this kind of tutorial where the collapsible is working too for mega menus! Well done Nelson... really well done. Thanks for this

  • @eq091801
    @eq091801 2 года назад +1

    Another amazing tutorial. This was very helpful for me while building a menu on a recent project. Your tutorials on working with divi and customizing with css are the best.

    • @PeeAyeCreative
      @PeeAyeCreative  2 года назад

      Thanks Edgar, I'm so glad you like the tutorials!

  • @mariajandersen5387
    @mariajandersen5387 2 года назад

    Loved this! So easy and fast!! Thank you

  • @xizzeewebdesign4951
    @xizzeewebdesign4951 7 месяцев назад

    Exactly what I needed. Thanks for sharing the code and demonstrating exactly where to put it. It worked perfectly on the first try.

  • @newhampshirelivefreeandexp4463
    @newhampshirelivefreeandexp4463 2 года назад

    Thank you for this video! It was not something I was looking forward to but your video made it a cinch!

  • @alyonarutzen2563
    @alyonarutzen2563 Год назад +1

    So helpful, easy and fast!! Really well done. Thank you!

  • @brianressler569
    @brianressler569 2 года назад +1

    Needed some tweaking having not followed the other tutorials, where it would change the icon of the mobile menu button itself when opened for instance, but it did the trick in the end thanks man

  • @samsignal-js6ng
    @samsignal-js6ng Год назад +1

    this is the only video that solved the actual issues thanks so much bro you are the best

  • @napcousa
    @napcousa 2 месяца назад +1

    Thanks for posting, very helpful and easy to follow!

  • @marciaturley2850
    @marciaturley2850 Год назад +1

    You're so talented. It was a great tutorial. Thank you so much.

  • @samfabio
    @samfabio 3 года назад +1

    That was amazing bro! Thanks and keep going

  • @flaviocavaleri749
    @flaviocavaleri749 Год назад +1

    Thank you Nelson. Perfect for me!!

  • @MrMattuko
    @MrMattuko 3 месяца назад +1

    AWESOME MAN! Thanks a lot ! Its a Great Tutorial

    • @PeeAyeCreative
      @PeeAyeCreative  3 месяца назад

      You're welcome, so glad you liked it!

  • @AsitAithal
    @AsitAithal Год назад

    Thanks for saving my day!

  • @todowebsalta
    @todowebsalta Год назад +1

    Excelent as always. A very useful tutorial for the collapsible menu. Marcelo from Argentina.😃

  • @shukrullah1981
    @shukrullah1981 2 года назад +1

    Super helpful. I saw similar things from other RUclipsrs but unfortunately, none of them is working luckily yours is working fine. Highly appreciated your efficient video I become your subscriber and I did like it. comments, follow, and all notifications.

    • @PeeAyeCreative
      @PeeAyeCreative  2 года назад

      That's great 👍 I'm so glad it works for you and I hope you enjoy all of our tutorials!

  • @gusyacoub7495
    @gusyacoub7495 Год назад +1

    Thank you SO much!!! This is exactly what I was looking for.

  • @twsuicy
    @twsuicy 2 года назад

    O M G. This has to be heard and go viral. You literally save my life Nelson, thanks a million!

  • @alpasc
    @alpasc Год назад

    Thanks you soooooooooooooooooo much ! not the first time that you save me with your tricks... i just put your website in my favs ;-)

  • @user-xx1mg7ib8x
    @user-xx1mg7ib8x 2 месяца назад +1

    Brilliant! I'm new to WordPress and Divi and this is really easy to follow, thank you.

    • @PeeAyeCreative
      @PeeAyeCreative  2 месяца назад

      That's great, welcome! I'm glad it was easy to follow!

  • @abelbeyene7573
    @abelbeyene7573 Год назад +1

    Great tutorial thank you!

  • @DocWilsonDesign
    @DocWilsonDesign 2 года назад

    Really nice tuts, thanks so much for the share!

  • @nenadvracaric2994
    @nenadvracaric2994 2 года назад +1

    THANK YOU good man for this video and all other great knowledge you share!

  • @mmdwebsites6847
    @mmdwebsites6847 3 года назад +1

    This is so nice because i had a diferent code from before but this would not work while using the DIVI THEME BUILDER and this worked perfectly, thank you so much...

    • @PeeAyeCreative
      @PeeAyeCreative  3 года назад

      That's great, so glad you can use this for the Menu module also!

  • @EhsaasSchlorship
    @EhsaasSchlorship Год назад

    Amazing Channel Outstanding information provider. and also tell makhan method.

  • @moussamhanna
    @moussamhanna Год назад +1

    thank you for this amazing tutorial

  • @jamilajones6383
    @jamilajones6383 3 года назад +1

    Thanks so much for this, really really helpful

  • @jesslynthessner1467
    @jesslynthessner1467 Год назад +1

    great tutorial. thank you

  • @lovepixelagency
    @lovepixelagency 3 года назад +1

    Worked like a charm!

  • @pihl8661
    @pihl8661 3 года назад

    Thanks! Worked great.

  • @chiranjivichaudhary8707
    @chiranjivichaudhary8707 Год назад +1

    wow, thanks for video, this tutorial help me lots.

  • @gurushankar2004
    @gurushankar2004 2 года назад +1

    Thank you so much. Do provide more such tutorials.

  • @leandrogcosta
    @leandrogcosta 8 месяцев назад +1

    Great! Congratulations on your interest in teaching

  • @glyndonsanders8432
    @glyndonsanders8432 2 года назад

    good day. This tutorial is very helpful but I want to ask is there a way to apply this one to a vertical menu that serves a side bar or can we apply this to the side bar itself?

  • @MasterTecnologi
    @MasterTecnologi 2 года назад

    Excelente tutorial

  • @astousylla6412
    @astousylla6412 3 года назад +1

    Great tutorial thank you

  • @kismelwin6664
    @kismelwin6664 2 года назад +1

    THANK U SO MUCH!

  • @lauretomben298
    @lauretomben298 3 года назад +1

    Thank you so much !

  • @fishionboy9911
    @fishionboy9911 3 года назад +1

    Awesome! Thanks

  • @MitchRue
    @MitchRue 3 года назад +1

    YOU ARE A TRUE HERO!

  • @neidacollege-narendradefen5664
    @neidacollege-narendradefen5664 Год назад +1

    Thank you

  • @NaysTutor
    @NaysTutor Год назад

    thank you!

  • @YounEnvouteuse
    @YounEnvouteuse 2 года назад +1

    thanks you so much !

  • @fahadkhalid2120
    @fahadkhalid2120 3 года назад +1

    it worked, thanks

  • @ScottFichter
    @ScottFichter 2 года назад +1

    Thank you!!!!!!!

  • @user-uk6se2rk4s
    @user-uk6se2rk4s 3 года назад +1

    just awesome!

  • @sonatonifans
    @sonatonifans 3 года назад +1

    Thank you sooooooo much

  • @TheKrazyKat01
    @TheKrazyKat01 2 года назад

    Is it possible to add a transition when opening the parent? So it doesn’t open instantly but more smoothly?

  • @filipsil8262
    @filipsil8262 11 месяцев назад

    worked thanks

  • @Mralienlaf
    @Mralienlaf 2 года назад +1

    ESPECTACULAR

  • @yabadabaduunggawa966
    @yabadabaduunggawa966 Год назад

    Hi. How to make this work properly with gtranslate plugin? When i set gtranslate to show along with the menu, the gtranslate dropdown list wont show. Thanks

  • @izkuhl
    @izkuhl 3 года назад +1

    finally a good tut

  • @edwardcraven9114
    @edwardcraven9114 3 года назад

    Great tutorial, thanks. All of my submenu text is right aligned. How do I move it to the centre or left align it? Thanks

    • @PeeAyeCreative
      @PeeAyeCreative  3 года назад

      Hi Edward, for styling the mobile menu we have a separate tutorial, I suggest checking that out: ruclips.net/video/0MST8hJ8m0Q/видео.html

  • @abmarketing8952
    @abmarketing8952 Год назад

    How would you change the new submenu dropdown icon? The one with the green arrow. Is it custom code? Can't find directly in the theme builder

    • @PeeAyeCreative
      @PeeAyeCreative  Год назад

      That's an ETModules icon (the Divi font family) and the icon is in the CSS code, so you can easily change it there.

  • @spitsparrow
    @spitsparrow Год назад

    I used the snippets and it all works well. But is the menu item that now has collapsed sub menus is always bold and the little arrow next to it is green. I need to change both these things. I would like the menu item to not be bold and the colour of the icon to not be green. I cant find in the code where to change it

  • @alyonarutzen2563
    @alyonarutzen2563 Год назад

    Danke!

  • @phaj7676
    @phaj7676 Год назад

    How can i slide-in my hanburguer menu in desktop for divi with css

  • @AdvanceWebSolutions
    @AdvanceWebSolutions 3 года назад +1

    Great tutorial a lifesaver thank you. How would you do this though if you're using the Divi theme builder, it doesn't seem to work for that thanks!

    • @PeeAyeCreative
      @PeeAyeCreative  3 года назад

      What do you mean?

    • @doeyehof
      @doeyehof Год назад

      @@PeeAyeCreative it only works for the original menu not the theme builder menu.... and I know why because I use an vertical menu from you other tutorial

  • @leninrodriguez4765
    @leninrodriguez4765 2 года назад

    Hello, good day, I wanted to comment, I used the code and it works perfectly, except for a small problem, the menu appears only on the pages but it does not appear on the posts, I am using the divi constructor to apply a sidebar in all the posts, I don’t know if that’s the problem, but before adding the code that didn’t happen, any solution, thank you very much

  • @sohaibromi2671
    @sohaibromi2671 3 года назад +1

    Thanks, buddy. It's helpful for me

    • @PeeAyeCreative
      @PeeAyeCreative  3 года назад +1

      You're welcome, I'm glad it is helpful!

  • @christianhimmer
    @christianhimmer 3 года назад +1

    Thanks as always dude ... Can you do a tutorial for the logo on menu???

    • @PeeAyeCreative
      @PeeAyeCreative  3 года назад

      Thanks Christian! What would you like to see about the logo?

    • @PeeAyeCreative
      @PeeAyeCreative  3 года назад

      That's a good idea, I'll see what I can do!

  • @rahatali2335
    @rahatali2335 4 месяца назад

    Thank you soo much, Sir.
    Actually I am having same issue what Elementor. When I refresh or load any page, the dropdown menu expends for a sec, and collapse automatically. I tried many things but couldn't fixed. Will this work with Elementor?

    • @PeeAyeCreative
      @PeeAyeCreative  4 месяца назад

      I don't know about other builders but I'm sure a similar principle would work although with different selectors.

  • @danielvanginkel7081
    @danielvanginkel7081 3 года назад +2

    Great tutorial! One question I keep running into though: where do the lines underneath each list item in the menu come from? I can't seem to get rid of those lines. Does anyone know?

    • @tommymiller1180
      @tommymiller1180 2 года назад

      Hi Daniel, I have the same issue. I can't see any down arrows, just grey lines in the centre of the menu item. did you find a solution for this? Thanks

    • @PeeAyeCreative
      @PeeAyeCreative  2 года назад

      It is a border bottom on the list items "li"

  • @maccatabay270
    @maccatabay270 Год назад

    i tried this and it works. the problem here is that when you click the entire row with dropdown other that the icon, it closes. any ide why?

  • @badura72
    @badura72 3 года назад

    Thanks! Worked fine and helped a lot...but :-) I've got two (not one) little down arrows...tested it on serveral installations. Do you have any idea why? Thx

    • @BennyHozjan
      @BennyHozjan 3 года назад +3

      because there is a missing \ means it should be \33 or \4d instead of 4d for example

    • @badura72
      @badura72 3 года назад +1

      @@BennyHozjan Thx!

    • @PeeAyeCreative
      @PeeAyeCreative  3 года назад +1

      Yeah that is a common bug with pasting code into Divi.

    • @BennyElimelech
      @BennyElimelech 3 года назад +1

      When i changed content: '32'; to \32, and content: '33'; to \33 it fixed for both directions tnxx

  • @ninadebey2185
    @ninadebey2185 3 года назад +1

    merci !!!!!!!!!!!!!!

  • @sihamcosmeticsbio2947
    @sihamcosmeticsbio2947 3 года назад +1

    Merci je viens de faire parfait

  • @InsideSchoolForum
    @InsideSchoolForum 3 года назад

    I really need your help, sir. I did use your snippet and everything was working well until a few days ago the mobile menu and logo stop showing. I have tried all I can to make it to work but I can not do it. Can you please help me with a fix to it. The menu is working well on pc but not on mobile.

    • @PeeAyeCreative
      @PeeAyeCreative  3 года назад

      I'm guess the issue is related to the recent WordPress 5.6 update. Be sure to update Divi and report any bugs to Elegant Themes.

    • @InsideSchoolForum
      @InsideSchoolForum 3 года назад

      @@PeeAyeCreative ok sir. I will check right a way for an update

  • @BennyElimelech
    @BennyElimelech 3 года назад

    Hello very good tutorial thank you man:)
    i try to fix that code to my site from right to left letters... and its getting big mess// the arrows are on the letters on the right side.
    how can i fix the arrows to be on the left side? is there an easy way for that in divi?

  • @lydiapalazzolo
    @lydiapalazzolo 3 года назад +1

    I entered the CSS and it worked but the arrows in the menu didn't appear. Instead, I see light grey slivers you can barely see. How do I edit the icons (arrows/grey slivers) in the menu if the arrows didn't show up or if they aren't arrows after entering the code?
    Great tutorial by the way and many thanks!

    • @laembajadatiendamexicana998
      @laembajadatiendamexicana998 3 года назад +1

      Did you get any answer? It happens the same to me.

    • @JuAkiraLia
      @JuAkiraLia 3 года назад

      Same here

    • @PeeAyeCreative
      @PeeAyeCreative  3 года назад

      Hi Lydia, in general if you can ask code related questions on our blog it would really help me out and you will get a better response. Thanks!

  • @mustafak4378
    @mustafak4378 2 года назад +1

    How can i make the submenu expand on mobile by pressing on a menu item with a custom link of # instead of pressing the icon??

    • @ericjunge
      @ericjunge 2 года назад

      Same question here - I have a customer that does not like the icon expansion and wants the submenu to expand when you click on the top menu item. Thanks in advance

    • @mustafak4378
      @mustafak4378 2 года назад

      @@ericjunge I have found a trick solution for this myself. Not sure if it’s the right way to do it, but it works. I’ll post it here later today.

  • @sauravramofficial
    @sauravramofficial 3 года назад

    it worked but mine is shoeing 2 drop icon instead of 1 ..something like this vv instead of just v

    • @PeeAyeCreative
      @PeeAyeCreative  3 года назад +1

      Okay did you check if Divi is stripping out the \ forward slash in the code? You can see about that in the blog comments.

  • @AlotoSumi
    @AlotoSumi 2 года назад

    how to use the Et module font ? to change the signs to + -
    please

    • @PeeAyeCreative
      @PeeAyeCreative  2 года назад

      You can use any of them here: www.elegantthemes.com/blog/resources/elegant-icon-font

    • @AlotoSumi
      @AlotoSumi 2 года назад

      @@PeeAyeCreative my menu is collasping but the icon is not showing . just a white circle . could you please help me ?

    • @AlotoSumi
      @AlotoSumi 2 года назад

      and when i try to upload the fonts , they arent premitting because of the security reasons

  • @renes3654
    @renes3654 2 года назад +3

    Amazing Tutorial, everything works perfectly fine!
    But, do you have a solution for the parent menu items ? The child menu items only open, when I hit the toggle. When I click on the menu item (parent) itself, the menu just closes. Would be great if the child items would also open if you click on the parent item text.
    Hope it’s understandable 😂

    • @jamesdowling6957
      @jamesdowling6957 Год назад

      I had the same problem. Codes here helped fix it for me and menus working good on mobile now, for anyone else in the same situation. ruclips.net/video/3IQ-b2bEqyg/видео.html

    • @jakubkrivohlavy9012
      @jakubkrivohlavy9012 Год назад

      Yea.. And the submenu should stay open, if i am on some submenu page.

  • @regiestry6575
    @regiestry6575 Год назад

    Hi, is there a way to make the parent link, clickable too? thanks!

    • @PeeAyeCreative
      @PeeAyeCreative  Год назад

      It already is clickable, I have not altered that in this tutorial.

    • @regiestry6575
      @regiestry6575 Год назад

      @@PeeAyeCreative thanks, but I'm confused it's not working on me.
      I mean instead of just clicking on the icon on the left, I can also click on the label of the parent link, then it should do dropdown the submenu.

  • @XxWacadexX
    @XxWacadexX Год назад

    doesnt work on my site.

  • @nbroberts97
    @nbroberts97 2 года назад

    ugh i wish divi had an option to change header format based on device

  • @SINGRAISOREN-tm3uo
    @SINGRAISOREN-tm3uo 11 месяцев назад

    What is collapse minu mean

    • @PeeAyeCreative
      @PeeAyeCreative  11 месяцев назад

      Check the video and you will see! 🙂

  • @Jordi_SP
    @Jordi_SP Год назад

    ¿por qué me sale el título del vídeo y descripción en español, si el vídeo es de un inglés de habla inglesa? youtube es un puto troll...

  • @emmtalarico3491
    @emmtalarico3491 25 дней назад

    damn as a developer - this solution sucks. I get its meant for common folk and it works well in that use case. This clearly is a blind spot for divi.

    • @PeeAyeCreative
      @PeeAyeCreative  24 дня назад

      I'm not sure how this solution would differ for developers vs common folks. It's also not a blind spot, they are fully aware of these things.

    • @emmtalarico3491
      @emmtalarico3491 24 дня назад

      @@PeeAyeCreativegood devs are going to write a child theme function or a plugin extension to cover this and likely would avoid using jQuery or recommend that the client uses native Gutenberg instead. A good dev isn't going to inject code into the browser even if its just css. You can be aware of a problem and not care about correcting it and that is a blind spot. Hope that helps!