bootstrap navbar品牌标志居中

时间:2018-02-23 20:19:06

标签: html css twitter-bootstrap navbar center

我想在引导导航栏的中间放置一个徽标。 问题是我无法看到导航栏上显示的图像。



.navbar-brand {
    float: none;
    padding: 15px 15px;
    font-size: 18px;
    line-height: 20px;
    text-align: center;
    position: absolute;
}

<nav class="navbar navbar-inverse navbar-fixed-top">
        <div class="navbar-header">
            <center><a class="navbar-brand" src="https://images.vexels.com/media/users/3/144035/isolated/preview/dfc22fb3041ef07d658d11613e149963-flat-surfboard-icon-by-vexels.png"></a></center>
            <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
            </button>
        </div>
        <div class="navbar-collapse collapse">
            <ul class="nav navbar-nav">
                <li class="active"><a href="~/Home/index">Home</a></li>
                <li><a href="~/Contact/index">Contact</a></li>
                <li><a href="~/Nieuwsbrief/create">Nieuwsbrief</a></li>
            </ul>
        </div>
    </nav>
&#13;
&#13;
&#13;

0 个答案:

没有答案