Home › Forums › WoodMart support forum › WHERE IS IT TO ADD A CLOSE BUTTON IN THE MOBILE MENU?
WHERE IS IT TO ADD A CLOSE BUTTON IN THE MOBILE MENU?
- This topic has 10 replies, 2 voices, and was last updated 4 years, 4 months ago by
Artem Temos.
-
AuthorPosts
-
October 10, 2020 at 2:35 pm #232267
pepeluParticipantDear Friends,
I need the mobile menu to have a close button because in very low resolutions, it occupies the entire screen and when it opens, there is no close button and I cannot close it.
This is vital for me because all the important themes have it.Please answer all my questions in order:
1º How can I add a close button to the mobile menu?
2º If this option does not exist, please, could you tell me what php code to add to functions.php to achieve this?It is vital for me
Thank you so muchOctober 12, 2020 at 6:17 am #232494
Artem TemosKeymasterHello,
Add the following code to the file
woodmart/inc/template-tags.php
http://prntscr.com/uxid83echo '<div class="widget-heading"><a href="#" class="close-side-widget wd-cross-button wd-with-text-left"></a></div>';
and put this code to the custom JS section on document ready in Theme Settings
jQuery('.mobile-nav .close-side-widget').on('click', function(){ jQuery('.mobile-nav').removeClass('act-mobile-menu'); jQuery('.woodmart-close-side').removeClass('woodmart-close-side-opened'); jQuery('.mobile-nav .searchform input[type=text]').blur(); });
Regards
October 12, 2020 at 2:05 pm #232635
pepeluParticipantDear Friend, Why don’t you include this in your next update? Every time I update, I should put this back in the .php file
Likewise, I am going to create the best online dropshipping and ecommerce digital course for more than 1000 students, and I am thinking of recommending your theme, but I cannot be telling students to place this code every time they update the theme, understand?
This would be crazy!
October 12, 2020 at 2:14 pm #232640
Artem TemosKeymasterWe will consider adding this in our future updates but can’t guarantee that it will be implemented very soon.
October 12, 2020 at 2:14 pm #232641
pepeluParticipantDear Friend, Your code does not work, I have followed your instructions perfectly, and this does not close the menu. You can see it here: https://joseldiaz.com/sli/
Could you tell me the correct code?
And also, Why don’t you include this in your next update? Every time I update, I should put this back in the .php file
Likewise, I am going to create the best online dropshipping and ecommerce digital course for more than 1000 students, and I am thinking of recommending your theme, but I cannot be telling students to place this code every time they update the theme, understand?
This would be crazy!
October 12, 2020 at 2:15 pm #232642
Artem TemosKeymasterWe see that you have added some wrong JS code that breaks other scripts on your website https://gyazo.com/db4acce36939e842d33481d8d3c5633d
October 12, 2020 at 2:38 pm #232658
pepeluParticipantDear Friend, I have not added any of that !!! I have only added the piece of code that you have given me.
Maybe your code has created a conflict in another line above !!Do you think I know something about php?
How can you think that I have added that to the template and accuse me of it?
Can you tell me how to fix it completely?
October 12, 2020 at 2:45 pm #232663
Artem TemosKeymasterWe don’t know who added that code but it causes JS errors on your website. You need to remove it from the custom JS section or whatever else you have it.
October 12, 2020 at 3:04 pm #232683
pepeluParticipantExcuse me dear friend, now I understood that you were referring to the code inserted in custom JS and not to the code of a .php template when I saw the row with number 7485
Now I could see a code inserted in custom JS, and that code was perhaps added by my partner who was looking at some parallax options, but I did not think that he would add any code or that he would know how to do this.
Thanks for telling me better, now it works perfectly. But could you tell me how to add a text to the left of the close icon with the word “CLOSE”?
This would be perfect.
I really appreciate your support system, you really are fantastic and I am very happy, and I will recommend your theme.
Thank you very much my dear support friends
October 12, 2020 at 3:29 pm #232686
pepeluParticipantI already managed to put the word CLOSE
Thank you very much for your great help and service
October 13, 2020 at 6:02 am #232802
Artem TemosKeymasterGreat, we are glad that you sorted it out!
-
AuthorPosts
- You must be logged in to create new topics. Login / Register