admin管理员组文章数量:1395436
Using Avada theme and not sure what version of Bootstrap they have integrated, but on mobile when I open a modal it scrolls the page to the top. I've tried a few solutions from the wild, but none have worked so far.
Using Avada theme and not sure what version of Bootstrap they have integrated, but on mobile when I open a modal it scrolls the page to the top. I've tried a few solutions from the wild, but none have worked so far.
Share Improve this question edited Jun 15, 2018 at 4:01 wazz 5,0885 gold badges22 silver badges36 bronze badges asked Jun 1, 2018 at 15:10 NotaGuruAtAllNotaGuruAtAll 5338 silver badges21 bronze badges1 Answer
Reset to default 11I just experienced the same issue on Avada 5.5.2. Here is the exact question my coworker emailed me this morning.
I'm working on the *******. website. The modal windows work as they should on desktop. However on mobile, when a modal link is clicked the modal window pops up just fine, but it also scrolls the page back to top. Avada includes a # in the href line when using these bootstrap functions, and won't let me remove it.
So, here's what I tried, without success: ....
After going in a lot of incorrect directions, the solution that worked for me was one simple css tweak. Add the code below labeled "solution" to your child theme, or directly into your Avada Options as done in the screenshot.
fusion-10.min.css
The style sheet fusion builder creates is forcing fixed positioning.
.ua-mobile .modal-open {
position: fixed;
overflow: hidden;
}
Solution
Override the fusion style sheet as such.
.ua-mobile .modal-open {
position: relative;
}
本文标签: javascriptAvada WP ThemeBootstrap Modals Cause Page to Scroll to Top on MobileStack Overflow
版权声明:本文标题:javascript - Avada WP ThemeBootstrap Modals Cause Page to Scroll to Top on Mobile - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1744088291a2588945.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论