容器流体增加了不必要的边际差距

时间:2017-04-06 12:28:50

标签: html css twitter-bootstrap

我正在使用bootstrap来设计网页。

enter image description here

正如您所看到的那样,导航栏和图像之间存在不必要的差距。您看到的图像是div的背景图像,它是容器流体

这是我的 html 代码:

chatgroup

这是我的css:

    <!DOCTYPE html>
<html>

<head>
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
    <meta charset="utf-8">
    <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
    <link href="https://fonts.googleapis.com/css?family=Graduate" rel="stylesheet">

    <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.0/jquery.min.js"></script>
    <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
    <!--Custom Stylesheets and Scripts -->
    <link rel="stylesheet" href="resources/css/index.css">
    <link rel="stylesheet" href="resources/css/app.css"> </head>

<body>
    <div class="navigation-bar">
        <nav class="navbar navbar-default navbar-static-top ">
            <div class="container">
                <div class="navbar-header">
                    <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar"> <span class="sr-only">Toggle navigation</span> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> </button>
                    <a class="navbar-brand" href="#"></a>
                </div>
                <div id="navbar" class="navbar-collapse collapse">
                    <ul class="nav navbar-nav navbar-right">
                        <li class="dropdown "> <a href="#" class="dropdown-toggle " data-toggle="dropdown" role="button" aria-expanded="false">Home<span class="caret"></span></a>
                            <ul class="dropdown-menu" role="menu">
                                <li><a href="#">Van Boening Sets World Record</a></li>
                            </ul>
                        </li>
                        <li class="dropdown "> <a href="#" class="dropdown-toggle " data-toggle="dropdown" role="button" aria-expanded="false">Tour Info<span class="caret"></span></a>
                            <ul class="dropdown-menu" role="menu">
                                <li><a href="#">How it Works</a></li>
                                <li><a href="#">Games Played</a></li>
                                <li><a href="#">How to get your room playing</a></li>
                                <li><a href="#">Become an event coordinator</a></li>
                                <li><a href="#">Mission and Goals</a></li>
                            </ul>
                        </li>
                        <li class="dropdown "> <a href="#" class="dropdown-toggle " data-toggle="dropdown" role="button" aria-expanded="false">Rules<span class="caret"></span></a>
                            <ul class="dropdown-menu" role="menu">
                                <li><a href="#">Rules</a></li>
                                <li><a href="#">Scoring</a></li>
                                <li><a href="#">Faq</a></li>
                            </ul>
                        </li>
                        <li class="dropdown"> <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false">Events<span class="caret"></span></a>
                            <ul class="dropdown-menu" role="menu">
                                <li><a href="#">Action</a></li>
                                <li><a href="#">Another action</a></li>
                                <li><a href="#">Something else here</a></li>
                            </ul>
                        </li>
                        <li class="dropdown"> <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false">Players<span class="caret"></span></a>
                            <ul class="dropdown-menu" role="menu">
                                <li><a href="#">BTRT Members</a></li>
                                <li><a href="#">Rankings</a></li>
                                <li><a href="#">Player Search</a></li>
                                <li><a href="#">Tour Records</a></li>
                            </ul>
                        </li>
                        <li class="dropdown"> <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false">Store<span class="caret"></span></a>
                            <ul class="dropdown-menu" role="menu">
                                <li><a href="#">BTRT Members</a></li>
                                <li><a href="#">Rankings</a></li>
                                <li><a href="#">Player Search</a></li>
                                <li><a href="#">Tour Records</a></li>
                            </ul>
                        </li>
                        <li class="dropdown"> <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false">Blog<span class="caret"></span></a>
                            <ul class="dropdown-menu" role="menu">
                                <li><a href="#">BTRT Blog</a></li>
                                <li><a href="#">Free Stuff</a></li>
                                <li><a href="#">Pete's Journey</a></li>
                            </ul>
                        </li>
                        <li><a href="#">Contact</a></li>
                    </ul>
                </div>
            </div>
        </nav>
    </div>
    <!--End of Navigation bar-->
    <div class="container-fluid landing-content">


    </div>
</body>

</html>

有人可以告诉我如何消除这种差距吗?

0 个答案:

没有答案