Tagged: x
-
AuthorPosts
-
June 10, 2016 at 2:56 am #1035485
codecompanyParticipantI cant seem to get my mobile menu to close after clicking on a link. I tried some of the js I found on here but no luck. I did you this code so that I have all my link hrefs correct http://theme.co/x/member/forums/topic/nav-bar-not-fully-working-on-1-page-scrolling/#post-45754 but now all the links are highlighted when you are in full screen as the beginning of the each urls are all the same.
June 10, 2016 at 5:01 am #1035629
LelyModeratorHi There,
Please check this link for some guide:https://community.theme.co/kb/how-to-setup-one-page-navigation/
Make sure that under Page Settings > One Page Navigation: You have selected your menu under the dropdown. This will prevent multiple links to be highlighted. Then check the code suggested here:https://community.theme.co/forums/topic/mobile-menu-doesnt-close-when-selecting-scroll-link/#post-229038 to close it for mobile.Hope this helps.
June 10, 2016 at 12:27 pm #1036165
codecompanyParticipantHey Thank you works great on my computer, however it doesn’t seem to work on my phone. Also I tried to add a line that will also close the menu if the body is clicked. I tried variances of the following with no luck: .entry-content .content .x-main .full
June 10, 2016 at 6:14 pm #1036561
JadeModeratorHi there,
Kindly provide is with your site’s URL so that we could check it. Thanks!
June 10, 2016 at 6:19 pm #1036568
codecompanyParticipantThis reply has been marked as private.June 11, 2016 at 1:01 am #1036978
Rue NelModeratorHello There,
Thanks for providing the url of your site. I have tested your site on my mobile phone and I could not replicate the issue. Would you mind clearing your mobile phone’s browser cache? And if you are using CloudFlare or may have installed a caching plugin like WordFence, W3 Total Cache or WP Super Cache, please keep in mind that after doing every updates or making any changes, always remember to clear all caches when updating so that the code from the latest release is always in use. This will help you to avoid any potential errors.
Please let us know how it goes.
June 11, 2016 at 1:15 pm #1037509
codecompanyParticipantHello I cleared my phones cache, as well as tried it on my ipad that I haven’t used on the site yet. And the menu still does not close when a link is clicked. I am not using CloudFlare or have any caching plugins installed.
June 11, 2016 at 9:36 pm #1037822
Rue NelModeratorHello There,
You have implemented the one page navigation incorrectly. You should create two separate menus. One menu should be your primary menu and the other one is exclusively for your one page navigation menu. Right now, the menu items are being highlighted. This menu should only be used exclusively for the homepage or your one page nagivation. To know more about how to implement one page navigation menu, please check out our knowledge base here: https://community.theme.co/kb/how-to-setup-one-page-navigation/
Hope this helps.
June 11, 2016 at 10:05 pm #1037831
codecompanyParticipantHello,
I changed the menu so that I do not have the problem with the links staying highlighted. But the menu still does not collapse on my mobile devices, it does on my desktop but not on mobile.
June 12, 2016 at 1:29 am #1037977
Rue NelModeratorHi There,
To resolve the mobile menu issue, please update the JS code and make use of this code instead:
(function($) { $('.x-navbar .x-nav-wrap.mobile a, .entry-content .content').on('click touchstart', function() { $('.x-btn-navbar').toggleClass('collapsed'); }) })(jQuery);Please let us know if this works out for you.
June 12, 2016 at 11:17 am #1038316
codecompanyParticipantHello,
It does the same, it works on my computer but not on my mobile devices.
June 12, 2016 at 7:25 pm #1038694
Rue NelModeratorHello There,
I do not see the code on the page. All I see is your old code that you have added. If you already removed it, could you please add it back again so that we could thoroughly test it. And by the way, before testing it in your mobile phone, please clear your phone’s browser cache or use Chrome’s incognito mode or Safari’s private browsing mode.
Please let us know how it goes.
June 12, 2016 at 10:41 pm #1038948
codecompanyParticipantSorry I put the code back in.
June 13, 2016 at 1:57 am #1039117
Rue NelModeratorHello There,
Could please update the JS code and test again?
(function($) { $(window).load(function(){ $('.x-navbar .x-nav-wrap.mobile a, .entry-content .content').on('click touchend', function() { $('.x-btn-navbar').trigger('click'); }) }); })(jQuery);Please let us know if this works out for you.
June 13, 2016 at 3:43 pm #1040284
codecompanyParticipantAWESOME!! Works perfect. Thank you
-
AuthorPosts
- <script> jQuery(function($){ $("#no-reply-1035485 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>
