【发布时间】:2015-07-16 04:27:24
【问题描述】:
如何使用 bootstrap 3 在导航栏上设置 2 个用于移动设计的导航按钮?
在此示例中,左侧按钮(汉堡包)折叠菜单,右侧按钮(放大镜)执行搜索。 https://filmlimani.com/the-dark-knight.html(手机版)
【问题讨论】:
标签: javascript html css twitter-bootstrap-3
如何使用 bootstrap 3 在导航栏上设置 2 个用于移动设计的导航按钮?
在此示例中,左侧按钮(汉堡包)折叠菜单,右侧按钮(放大镜)执行搜索。 https://filmlimani.com/the-dark-knight.html(手机版)
【问题讨论】:
标签: javascript html css twitter-bootstrap-3
您可以将搜索按钮的 HTML 代码粘贴到 <button class="navbar-toggle"... 之前的 <div class="navbar-header">
而且您需要获得图标集(例如FontAwesome)。使用 font-awesome 你的代码将是
<button class="navbar-toggle" type="button">
<i class="fa fa-search"></i>
</button>
然后你需要编辑样式,并为这个按钮设置一个js-function
【讨论】: