当我单击导航栏上的主页按钮时,我的自定义wordpress主题无法给出任何响应,比如打开主页。 请在此链接上查看我自己的主题以获取更多信息。 它的主页按钮截图如下:
这里导航栏的css样式:
.navbar-header { position: relative; } .navbar-brand { float: left; padding: 15px 15px; font-size: 18px; line-height: 20px; height: 50px; }我一直试图解决它,但仍然没有运气
When I click a home button on navigation bar in my custom wordpress theme cannot give any response like open the home page. Please check my own theme on this link to further info. Its home button screenshot below:
Here css style for navigation bar:
.navbar-header { position: relative; } .navbar-brand { float: left; padding: 15px 15px; font-size: 18px; line-height: 20px; height: 50px; }I have been trying to fix it but still not luck
最满意答案
问题是div“navbar-collapse”是全宽并且位于按钮顶部。 因此,当您尝试单击按钮时,实际上会单击“navbar-collapse”。
要快速修复,您可以:
给“navbar-collapse”一个宽度并将其设置为“margin:0 auto;”。 然后它将不再覆盖您的按钮。要么
增加“navbar-header”的z-index - > z-index 21将在你的情况下做The problem ist that the div "navbar-collapse" is full width and sitting on top of the button. Therefore when you're trying to click the button you actually click "navbar-collapse".
For a quick fix you could:
give "navbar-collapse" a width and set it to "margin: 0 auto;". It will then no longer overlay your button.or
increase the z-index of "navbar-header" --> z-index 21 will do in your case更多推荐
发布评论