简体   繁体   English

BootStrap导航按钮链接不起作用?

[英]BootStrap Nav Button Link not Working?

The green "Blog" button on the top points to the right location, but when clicked, there is no response. 顶部的绿色“博客”按钮指向正确的位置,但是单击时没有任何响应。 It seems it's not a z-index issue. 看来这不是z-index问题。 It seems to be a conflict with the jQuery nav, but the solution here is very unclear. 这似乎与jQuery nav冲突,但是这里的解决方案还不清楚。

Here is the JS: http://pastebin.com/JuJwKdSZ and JS #2: http://pastebin.com/VDpViTqP 这是JS: http//pastebin.com/JuJwKdSZ和JS#2: http//pastebin.com/VDpViTqP

Here is the HTML: http://pastebin.com/BYuehZnU 这是HTML: http//pastebin.com/BYuehZnU

I think I may have found the answer. 我想我可能已经找到了答案。 It is to do with the plugin you are using: OnePageNav 这与您使用的插件有关: OnePageNav

This handles all clicks on links on the page. 这将处理页面上链接上的所有单击。 There is a filter ability on that plugin though, when you initialize the instance of one page, you can include a filter of a class name and add that class name to your external link like so: 但是,该插件具有过滤器功能,当您初始化一页实例时,可以包括一个类名的过滤器,然后将该类名添加到您的外部链接中,如下所示:

html HTML

<a id="blog" class="btn button navbar-btn white external" href="/blog"><i class="fa fa-pencil"></i> Blog</a>

Change this in the first js file (line 44) 在第一个js文件中进行更改(第44行)

filter: '',

to this 对此

filter: 'external',

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM