wordpress手机菜单点击后关闭[关闭](wordpress Mobile Menu not hidden after click [closed])

编程入门 行业动态 更新时间:2024-10-27 16:32:35
wordpress手机菜单点击后关闭[关闭](wordpress Mobile Menu not hidden after click [closed])

我做了一个带有一些链接的单页设计。

当我在智能手机上浏览网站时,使用按钮打开主菜单并单击链接(滚动到同一页面),移动菜单不会隐藏,而是放在内容的右侧网站上。

这是链接http://www.sarahspancakecafe.com.sg/

如何解决?

干杯

I made a one-page design with some links.

When I browse the site on my smartphone, open the main menu with the button and click on a link (which scrolls to the same page), the mobile menu isn’t hidden but placed on the right site of the content.

this is link http://www.sarahspancakecafe.com.sg/

How to fix that?

Cheers

最满意答案

尝试这个

$(document).ready(function(){ $('.menu-item-object-custom a').click(function(){ $('.navbar-header button').click(); }); });

我在你的网站上试了一下它似乎运作良好。

Try this

$(document).ready(function(){ $('.menu-item-object-custom a').click(function(){ $('.navbar-header button').click(); }); });

I tried it on your site and it seemed to work well.

更多推荐

本文发布于:2023-07-28 04:31:00,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1300380.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:菜单   手机   Mobile   wordpress   click

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!