2

我正在将我的网站更新为 bootstrap 3,我遇到了一个问题,我添加了导航栏和标题,但是当我尝试添加 jumbotron 时,它出现在 bs-header dono 下,为什么它会检查所有内容,如果我的 div 已关闭如果有人能告诉我我做错了什么,他们就是母猪?

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="">
    <meta name="author" content="HyperGainZ">

    <title> My Mod Pack &middot; MMP </title>

    <!-- Bootstrap core CSS -->
    <link href="assets/css/bootstrap-simplex.css" rel="stylesheet">
    <link href="assets/css/bootstrap-simplex.min.css" rel="stylesheet">

    <!-- Documentation extras -->
    <link href="assets/css/docs-index.css" rel="stylesheet">
    <link href="assets/css/pygments-manni.css" rel="stylesheet">

    <!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
    <!--[if lt IE 9]>
    <script src="../../assets/js/html5shiv.js"></script>
    <script src="../../assets/js/respond.min.js"></script>
    <![endif]-->

    <!-- Favicons -->
    <link rel="apple-touch-icon-precomposed" sizes="144x144" href="../assets/ico/apple-touch-icon-144.png">
    <link rel="apple-touch-icon-precomposed" sizes="114x114" href="../assets/ico/apple-touch-icon-114.png">
        <link rel="apple-touch-icon-precomposed" sizes="72x72" href="../assets/ico/apple-touch-icon-72.png">
                        <link rel="apple-touch-icon-precomposed" href="../assets/ico/apple-touch-icon-57.png">
                            <link rel="shortcut icon" href="../assets/ico/favicon.png">

</head>

<body>

<div class="navbar navbar-default navbar-fixed-top">
    <div class="container">
        <div class="navbar-header">
            <a href="../" class="navbar-brand">MMP</a>
                <button class="navbar-toggle" type="button" data-toggle="collapse" data-target="#navbar-main">
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                    <span class="icon-bar"></span>
                </button>
        </div>
        <div class="navbar-collapse collapse" id="navbar-main">
            <ul class="nav navbar-nav">
                <li class="active">
                <a href="/">Home</a>
                </li>
                <li class="dropdown">
                    <a class="dropdown-toggle" data-toggle="dropdown" href="#" id="download">Dropdown <span class="caret"></span></a>
                    <ul class="dropdown-menu" aria-labelledby="download">
                        <li><a tabindex="-1" href="#">1</a></li>
                        <li><a tabindex="-1" href="#">2</a></li>
                        <li class="divider"></li>
                        <li><a tabindex="-1" href="#">3</a></li>
                        <li><a tabindex="-1" href="#">4</a></li>
                    </ul>
                </li>
            </ul>
            <ul class="nav navbar-nav navbar-right">
                <li><a href="#">Sign Up</a></li>
                <li class="divider"></li>
                <li><a href="#">Sign In</a></li>
            </ul>
        </div>    
    </div>
    <div class="bs-header" id="content">
        <div class="container">
            <br />
                <img src="assets/img/index.jpeg" class="img-circle" width="125px" height="125px"alt="Sevadus" align="left">
                <h1>MMP</h1>
                <p class="lead">My Mod Pack</p></img>
                <div id="carbonads-container">
                    <div class="carbonad">
                        <div id="azcarbon">                     
                            <h4>Site Version : <span class="badge badge-success">Alpha</span></h4>
                            <h4>Head Of Project : <span class="badge badge-info">HyperGainZ</span></h4>
                            <h4>acepting Beta's : <span class="badge badge-success">Yes</span></h4>
                            <h4>Public Launcher : <span class="badge badge-primary">Not Yet</span></h4>                     
                        </div>
                    </div>
                </div>
        </div>
    </div>
</div>

    <div class="container">
        <div class="row">
            <div class="col-lg-12 jumbotron">
                <h1>Pack Assembler</h1>
                <p>Managing Mods, Packs, and Servers easily and efficiently.</p>
                <p>
                <a href="#" class="btn btn-primary btn-large">Get Started <i class="icon-double-angle-right"></i></a>
                </p>
            </div>
        </div>
    </div>




    <!-- Placed at the end of the document so the pages load faster -->
    <script src="assets/js/jquery.js"></script>
    <script src="assets/js/bootstrap.min.js"></script>

</body>

4

1 回答 1

2

因为您包含.bs-header在其中,所以.navbar-fixed-top您需要使用等于导航栏静态高度的顶部填充,在body.

引导文档

固定导航栏将覆盖您的其他内容,除非您在 . 提示:默认情况下,导航栏的高度为 50px。

于 2013-10-06T14:08:50.827 回答