Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

184
Views
Betheme mobile hamburger menu

so I have a page on my website that use anchor links that can be accessed in menu but on mobile when I click on a category (anchor link) the menu isn't closing automatically, I need to close manually by pressing on hamburger menu again.

This this is all my code from menu.js:

https://pastebin.com/hTL6wx2Q

This doMenu function :


            if( ( window.innerWidth >= options.mobileInit ) || ( ! options.responsive ) ){
                
                // desktop --------------------------------

                $( '> li, ul:not(.mfn-megamenu) li', menu ).hover(function() {
                    
                    $(this).stop(true,true).addClass( options.hoverClass );
                    
                    $(this).children( 'ul' ).stop(true,true).fadeIn( options.delay );
                    
                    
                }, function(){
                    
                    $(this).stop(true,true).removeClass( options.hoverClass );
                    
                    $(this).children( 'ul' ).stop(true,true).fadeOut( options.delay );  
                    
                });
                
            } else {

                // mobile ---------------------------------
                
                $( 'li', menu ).unbind('hover');
                
                $( 'li > .menu-toggle', menu ).off('click').on('click', function(){
    
                    var el = $(this).closest('li');
                    
                    if( el.hasClass( options.hoverClass ) ){
    
                        el.removeClass( options.hoverClass )
                            .children('ul').stop(true,true).fadeOut( options.delay );           
                        
                    } else {
        
                        el.addClass( options.hoverClass )
                            .children('ul').stop(true,true).fadeIn( options.delay );    
    
                    }
                    
                });
                
            }
            
        };
about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!