html - 我正在使用 bootstrap v4.5,由于某种原因,当我使用 jumbotron 时,它会占据页面的整个宽度。我没有使用 jumbotron-fluid
问题描述
我正在使用 bootstrap v4.5,由于某种原因,当我使用 jumbotron 时,它会占据页面的整个宽度。我没有使用jumbotron-fluid。有人可以让我知道我做错了什么吗?
这是我的代码。
<div class="jumbotron part2">
<h1 class="display-4">My Website</h1>
<p class="lead">This is a simple hero unit, a simple jumbotron-style component for calling extra attention to featured content or information.</p>
<hr class="my-4">
<p>It uses utility classes for typography and spacing to space content out within the larger container.</p>
<a class="btn btn-primary btn-lg" href="#" role="button">Learn more</a>
</div>
<script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo"
crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js" integrity="sha384-ZMP7rVo3mIykV+2+9J3UJ46jBk0WLaUAdn689aCwoqbBJiSnjAK/l8WvCWPIPm49"
crossorigin="anonymous"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js" integrity="sha384-ChfqqxuZUCnJSK3+MXmPNIyE6ZbWh2IMqE241rYiqJxyMiZ6OW/JmZQ5stwEULTy"
crossorigin="anonymous"></script>
</body>
</html>
jumbotron流体。
解决方案
推荐阅读
- javascript - Javascript条件隐藏和显示
- bash - SSH 时传递 bash 变量
- javascript - 在 Javascript 中获得 16 个可用位
- ibm-cloud-infrastructure - 如何使用 Softlayer 下达升级防火墙订单
- scala - 使用命令行在 Lunix 中下载 scowl
- android - 如何混淆 Android 库模块
- image-processing - 为什么在对医学图像进行微调时,浅层 DL 模型优于深层模型?
- powershell - 如何检查 VMHost 是否配置了 Syslog 转发
- ruby - Docker 使用 ruby 运行失败
- typo3 - TYPO3 抛出异常但未在 FE/BE 中显示