Bootstrap 3 Jumbotron неправильно расположен - PullRequest
0 голосов
/ 01 ноября 2019

Я сделал некоторые изменения в своем коде, и теперь я не могу понять, что я сделал неправильно, но теперь мой Bootstrap 3 jumbotron полностью выключен. Я не знаю почему, но мои HTML-файлы также продолжают повреждаться, теряя всю работу, на которую я потратил часы. У меня есть notepad ++ и atom, и я использую оба, полагаю, в этом может быть проблема.

Как мне заставить мой jumbotron работать снова, как раньше, и что стало причиной его сбоя?

Мой HTML-код после того, как я его изменил:

<!DOCTYPE html>
<html>
   <head>
      <title>Bootstrap 3</title>
      <html lang="en-US">
         <meta charset="UTF-8">
         <!-- Latest compiled and minified CSS -->
         <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
         <!-- jQuery library -->
         <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
         <!-- Latest compiled JavaScript -->
         <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
         <meta name="viewport" content="width=device-width, intial-scale=1.0">
         <link href="designstyles.css" rel="stylesheet">
   </head>
   <body>
   <div class="navbar navbar-inverse navbar-fixed-top"> <!-- creating a black navbar-->
   <!-- this container class keeps things contained, brand will stay at top-->
   <div class="container">
   <div class="navbar-header">
   <a href="#" class="navbar-brand">Cryptocurrency Guidance</a>
   <!--button-->  <button class="navbar-toggle" data-toggle="collapse" data-target=".navHeaderCollapse">
   <!-- three spans for bars stacked on eachother for hamburger icon-->
   <span class="icon-bar"></span>
   <span class="icon-bar"></span>
   <span class="icon-bar"></span>
   </button>
   <!--closing div for navbar-header-->
   </div>
   <!-- starting div for the navbar to collapse-->
   <div class="collapse navbar-collapse navHeaderCollapse"> <!--target-->
   <ul class="nav navbar-nav navbar-right">
   <!-- sets styling and pos to right -->
   <li class="active"><a href="#">Home</a></li>
   <li><a href="guide.html">My Bitcoin Guide</a></li> <!-- link guide html page here -->
   <li class="dropdown">
   <a href="#" class="dropdown-toggle" data-toggle="dropdown">Social Media<b class="caret"></b></a>
   <ul class="dropdown-menu">
   <li><a href="#">Twitter</a></li>
   <li><a href="#">Facebook</a></li>
   <li><a href="#">Placeholder</a></li>
   <li><a href="#">Instagram</a></li>
   </ul>
   </li>
   <li><a href="#">About</a></li>
   <li><a href="#">Contact</a></li>
   </ul>
   </div>
   </div> <!-- container ending div closing-->
   </div> <!--  starting nav bar div closing-->
   <div class="container">
   <div class="jumbotron text-center">
   <div class="page-header">
   <h1>Bitcoin</h1>
   </div>
   <p>A peer to peer electronic <span class="importance">cash</span> system</p>
   <a href="https://bitcoin.org/bitcoin.pdf" class="btn btn-default">Read whitepaper</a>
   <a class="btn btn-info">Tweet it</a>
   </div>
   </div>
   <div class="container"> <!-- starting carousel container -->
   <div id="myCarousel" class="carousel slide" data-ride="carousel">
   <!-- Indicators -->
   <ol class="carousel-indicators">
   <li data-target="#myCarousel" data-slide-to="0" class="active"></li>
   <li data-target="#myCarousel" data-slide-to="1"></li>
   <li data-target="#myCarousel" data-slide-to="2"></li>
   </ol>
   <!-- Wrapper for slides -->
   <div class="carousel-inner">
   <div class="item active">
   <img src="bitcoinwhitepaper.jpg" alt="bitcoin" style="width:100%;">
   </div>
   <div class="item">
   <img src="bitcoin.jpg" alt="bitcoinwhitepaper" style="width:100%;">
   </div>
   <div class="item">
   <img src="blockchain.png" alt="blockchain" style="width:100%;">
   </div>
   </div>
   <!-- Left and right controls -->
   <a class="left carousel-control" href="#myCarousel" data-slide="prev">
   <span class="glyphicon glyphicon-chevron-left"></span>
   <span class="sr-only">Previous</span>
   </a>
   <a class="right carousel-control" href="#myCarousel" data-slide="next">
   <span class="glyphicon glyphicon-chevron-right"></span>
   <span class="sr-only">Next</span>
   </a>
   </div>
   </div>  <!-- ending carousel container -->
   <div class="container">
   <div class="row">
   <div class="col-md-3">
   <h3><a href="#">Loren Ipsum</a></h3>
   <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum</p>
   <a class="btn btn-default">Read more</a>
   </div>
   <div class="col-md-3">
   <h3><a href="#">Loren Ipsum</a></h3>
   <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum</p>
   <a class="btn btn-default">Read more</a>
   </div>
   <div class="col-md-3">
   <h3><a href="#">Loren Ipsum</a></h3>
   <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum</p>
   <a class="btn btn-default">Read more</a>
   </div>
   <div class="col-md-3">
   <h3><a href="#">Loren Ipsum</a></h3>
   <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum</p>
   <a class="btn btn-default">Read more</a>
   </div>
   </div>
   </div>
   <div class="container">
   <div class="aligncolumn">
   <!-- thumbnail -->
   <div class = "row">
   <div class = "col-sm-6 col-md-3">
   <div class = "thumbnail">
   <img src = "300x200.jpg" alt = "Generic placeholder thumbnail">
   </div>
   <div class = "caption">
   <h3>Thumbnail label</h3>
   <p>Some sample text. Some sample text.</p>
   <p>
   <a href = "#" class = "btn btn-primary" role = "button">
   Button
   </a>
   <a href = "#" class = "btn btn-default" role = "button">
   Button
   </a>
   </p>
   </div>
   </div>
   <div class = "col-sm-6 col-md-3">
   <div class = "thumbnail">
   <img src = "300x200.jpg" alt = "Generic placeholder thumbnail">
   </div>
   <div class = "caption">
   <h3>Thumbnail label</h3>
   <p>Some sample text. Some sample text.</p>
   <p>
   <a href = "#" class = "btn btn-primary" role = "button">
   Button
   </a>
   <a href = "#" class = "btn btn-default" role = "button">
   Button
   </a>
   </p>
   </div>
   </div>
   <div class = "col-sm-6 col-md-3">
   <div class = "thumbnail">
   <img src = "300x200.jpg" alt = "Generic placeholder thumbnail">
   </div>
   <div class = "caption">
   <h3>Thumbnail label</h3>
   <p>Some sample text. Some sample text.</p>
   <p>
   <a href = "#" class = "btn btn-primary" role = "button">
   Button
   </a>
   <a href = "#" class = "btn btn-default" role =" button">
   Button
   </a>
   </p>
   </div>
   </div>
   <div class = "col-sm-6 col-md-3">
   <div class = "thumbnail">
   <img src = "300x200.jpg" alt = "Generic placeholder thumbnail">
   </div>
   <div class = "caption">
   <h3>Thumbnail label</h3>
   <p>Some sample text. Some sample text.</p>
   <p>
   <a href = "#" class = "btn btn-primary" role = "button">
   Button
   </a>
   <a href = "#" class = "btn btn-default" role = "button">
   Button
   </a>
   </p>
   </div>
   </div>
   </div>
   </div>
   </div>
   </div>
   <!-- navbar navbar default navbar-fixed-bottom footer-->
   <div class="footer">
   <div class="navbar navbar-default navbar-fixed-bottom">
   <div class="container">
   <p class="navbar-text pull-left">Site build by Chris R</p>
   <a href="https://www.youtube.com/channel/UC_4p45CXlEXSYaPMIF80QlA?view_as=subscriber" class="navbar-btn btn-danger btn pull-right">Subscribe on YouTube</a>
   </div>
   </div>
   </div>

Мой HTML-код до того, как я его изменил, который работает:

<!DOCTYPE html>
<html>
  <head>
  <title>Bootstrap 3</title>
  <html lang="en-US">
  <meta charset="UTF-8">
     <!-- Latest compiled and minified CSS -->
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">

<!-- jQuery library -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>

<!-- Latest compiled JavaScript -->
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
    <meta name="viewport" content="width=device-width, intial-scale=1.0">
    <link href="designstyles.css" rel="stylesheet">
</head>
<body>
  <div class="navbar navbar-inverse navbar-static-top"> <!-- creating a black navbar-->
    <!-- this container class keeps things contained, brand will stay at top-->
      <div class="container">
        <div class="navbar-header">
          <a href="#" class="navbar-brand">Enthusiastic Builds</a>
      <!--button-->  <button class="navbar-toggle" data-toggle="collapse" data-target=".navHeaderCollapse">
           <!-- three spans for bars stacked on eachother for hamburger icon-->
          <span class="icon-bar"></span>
          <span class="icon-bar"></span>
          <span class="icon-bar"></span>

        </button>
        <!--closing div for navbar-header-->
        </div>
         <!-- starting div for the navbar to collapse-->
        <div class="collapse navbar-collapse navHeaderCollapse"> <!--target-->

          <ul class="nav navbar-nav navbar-right">
                  <!-- sets styling and pos to right -->
            <li class="active"><a href="#">Home</a></li>
            <li><a href="#">Blog</a></li>
            <li class="dropdown">
              <a href="#" class="dropdown-toggle" data-toggle="dropdown">Social Media<b class="caret"></b></a>
              <ul class="dropdown-menu">
                <li><a href="#">Twitter</a></li>
                <li><a href="#">Facebook</a></li>
                <li><a href="#">Instagram</a></li>
                <li><a href="#">Instagram</a></li>


              </ul>

            </li>
            <li><a href="#">About</a></li>
            <li><a href="#">Contact</a></li>



          </ul>

        </div>


      </div> <!-- container ending div closing-->

  </div> <!--  starting nav bar div closing-->

  <div class="container">
    <div class="jumbotron text-center">
      <div class="page-header">
      <h1>Gaming Build</h1>
    </div>
      <p>Build the <span class="importance">ultimate</span> quality gaming budget build.</p>
      <a class="btn btn-default">Watch now</a>
      <a class="btn btn-info">Tweet it</a>
    </div>

  </div>
  <div class="container">
    <h2>Dumby Text</h2>
    <div id="myCarousel" class="carousel slide" data-ride="carousel">
      <!-- Indicators -->
      <ol class="carousel-indicators">
        <li data-target="#myCarousel" data-slide-to="0" class="active"></li>
        <li data-target="#myCarousel" data-slide-to="1"></li>
        <li data-target="#myCarousel" data-slide-to="2"></li>
      </ol>

      <!-- Wrapper for slides -->
      <div class="carousel-inner">
        <div class="item active">
          <img src="la.jpg" alt="Los Angeles" style="width:100%;">
        </div>

        <div class="item">
          <img src="chicago.png" alt="Chicago" style="width:100%;">
        </div>

        <div class="item">
          <img src="ny.jpg" alt="New york" style="width:100%;">
        </div>
      </div>

      <!-- Left and right controls -->
      <a class="left carousel-control" href="#myCarousel" data-slide="prev">
        <span class="glyphicon glyphicon-chevron-left"></span>
        <span class="sr-only">Previous</span>
      </a>
      <a class="right carousel-control" href="#myCarousel" data-slide="next">
        <span class="glyphicon glyphicon-chevron-right"></span>
        <span class="sr-only">Next</span>
      </a>
    </div>
  </div>
<div class="container">
  <div class="row">
    <div class="col-md-3">
      <h3><a href="#">Loren Ipsum</a></h3>
      <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum</p>
      <a class="btn btn-default">Read more</a>
    </div>
    <div class="col-md-3">
        <h3><a href="#">Loren Ipsum</a></h3>
      <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum</p>
      <a class="btn btn-default">Read more</a>
    </div>
    <div class="col-md-3">
  <h3><a href="#">Loren Ipsum</a></h3>
  <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum</p>
      <a class="btn btn-default">Read more</a>
    </div>
  </div>
</div>

<!-- navbar navbar default navbar-fixed-bottom footer-->
  <div class="navbar navbar-default navbar-fixed-bottom">

<div class="container">
  <p class="navbar-text pull-left">Site build by Chris</p>
  <a href="#" class="navbar-btn btn-danger btn pull-right">Subscribe on You-Tube</a>
  </div>



1 Ответ

0 голосов
/ 01 ноября 2019

Я бы предложил инструмент под названием split diff link для атома - он звучит как идеальный инструмент для такого типа проблем. Я использую его, когда мне нужно сравнить различия между двумя файлами.

до
после

Из того, что я могу сказать - кажется, что jumbotron работает.

  • Может быть, другие части влияют на страницу?
  • Может быть, CSS не отображается?
  • Может быть, есть проблема с JavaScript?
Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...