如何在导航栏中居中 glyphicon
how to center glyphicon in a navbar
我想在导航栏中的左侧、右侧和中心位置放置 3 个图标
左右两个在正确的位置,但中心 link 不在中心而是向左,即与左字形连续
知道如何居中吗?
<div class="navbar navbar-default navbar-fixed-bottom">
<div class="container">
<a href="/left_link" class="btn btn-info btn-lg pull-left hidelink">
<span class="glyphicon glyphicon-log-out"></span> Left
</a>
<a href="/center_link" class="btn btn-info btn-lg hidelink">
<span class="glyphicon glyphicon-log-out"></span> Center
</a>
<a href="/right_link" class="btn btn-info btn-lg pull-right hidelink">
<span class="glyphicon glyphicon-log-out"></span> Right
</a>
</div>
</div>
将 text-center
class 添加到您的容器 div:
<div class="container text-center">
我想在导航栏中的左侧、右侧和中心位置放置 3 个图标 左右两个在正确的位置,但中心 link 不在中心而是向左,即与左字形连续 知道如何居中吗?
<div class="navbar navbar-default navbar-fixed-bottom">
<div class="container">
<a href="/left_link" class="btn btn-info btn-lg pull-left hidelink">
<span class="glyphicon glyphicon-log-out"></span> Left
</a>
<a href="/center_link" class="btn btn-info btn-lg hidelink">
<span class="glyphicon glyphicon-log-out"></span> Center
</a>
<a href="/right_link" class="btn btn-info btn-lg pull-right hidelink">
<span class="glyphicon glyphicon-log-out"></span> Right
</a>
</div>
</div>
将 text-center
class 添加到您的容器 div:
<div class="container text-center">