Design Prototyping in the Browser Page Layout Defining Content Areas

Thomas Barkel
PRO
Thomas Barkel
Pro Student 7,222 Points

non responsive CSS

Hello, Changes that I make to the custom CSS are not displaying on the page. Is it because Bootstrap 4 was in Beta during the shooting of this course? Below is my code

HTML-

<!DOCTYPE html>
<html lang="en">
  <head>
    <!-- Required meta tags -->
    <title>Designer Finder</title>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">

    <!-- Bootstrap CSS -->
    <link rel="stylesheet" href="css/bootstrap.min.css">
    <link rel="stylesheet" href="css/style.css">
  </head>
  <body>

    <div class="container">

    <header class="d-flex justify-content-between flex-wrap">
    <h1>Designer Finder</h1>  
       <nav>
          <ul class="nav"></ul>
              <li class="nav-item">
                <a class="nav-link" href="#">Home</a>
              </li>
                 <li class="nav-item">
              <a class="nav-link" href="#">Artists</a>
            </li>
                 <li class="nav-item">
              <a class="nav-link" href="#">About</a>
            </li>
                 <li class="nav-item">
              <a class="nav-link" href="#">Logout</a>
            </li>
        </nav>
    </header>

    <section class="featured"></section>

    <section class="row">
    <div class="col-lg-4" "profile-info">
      <img class="float-left" src="nickpettit.jpg" alt="Photograph of Nick Pettit">
        <h2>Nick Pettit</h2>
        <p class="text-muted">Orlando, FL</p>
       </div>  
        <div class="col-lg-5">
      <p>Hi, my name is Nick! I'm a teacher at Treehouse and I enjoy designing websites.</p>
        </div>
        <div class="col-lg-3">
          <p><a class="btn btn-block btn-primary" href="#">Send Message</a></p>
      </div> 
    </section>

    <section class="gallery">
      <a href="#"><img src="#"></a>
      <a href="#"><img src="#"></a>
      <a href="#"><img src="#"></a>
      <a href="#"><img src="#"></a>
      <a href="#"><img src="#"></a>
      <a href="#"><img src="#"></a>
      <a href="#"><img src="#"></a>
      <a href="#"><img src="#"></a>
      <a href="#"><img src="#"></a>
      </section>

    <footer></footer>

</div> <!-- END container -->

    <script src="js/jquery-3.2.1.slim.min.js"></script>
    <script src="js/popper.min.js"></script>
    <script src="js/bootstrap.min.js"></script>
  </body>
</html>

CSS

header {
  padding: 2rem 0;
} 

.featured {
  height: 500px;
  background: #F99;
  margin-bottom: 2rem;
} 

.profile-info img {
  max-width: 6rem;
  max-height: 6rem;
  border-radius: 1rem;
  margin: -0.5rem 1rem 0 0;
} 

1 Answer

Could it be that your custom css file has been named something other than style.css or is perhaps in the wrong directory? For example if you have in your head a link to style.css but the css file you're editing is called custom.css it will not work. Likewise if your reference to the css file is set to the same directory as the HTML files (src="style.css") but it should be one or more directories lower (src="/css/style.css") then that would also cause the css to not render.