BOOTSTRAP opening

Hey guys. I am working on the assignments for the first modules. To do so, I need to use bootstrap, but cannot get it to open/work. I’ve been looking at some videos on youtube but haven’t found anything to help me get it to work. If anyone could help I’d greatly appreciate it.

Using Bootstrap is not a requirement for any of the projects. Where are you coding it, locally or on Codepen?


HTML for local development:

Click me
<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <link
      href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/css/bootstrap.min.css"
      rel="stylesheet"
      integrity="sha384-1BmE4kWBq78iYhFldvKuhfTAU6auU8tT94WrHftjDbrCEXSU1oBoqyl2QvZ6jIW3"
      crossorigin="anonymous"
    />
    <link rel="stylesheet" href="style.css" />
  </head>
  <body>
    <!-- Keep the script at the bottom after your HTML -->
    <script
      src="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/js/bootstrap.bundle.min.js"
      integrity="sha384-ka7Sk0Gln4gmtz2MlQnikT1wXgYsOg+OMhuP+IlRH9sENBO0LRn5q+8nbTov4+1p"
      crossorigin="anonymous"
    ></script>
  </body>
</html>

On Codepen you can just add the links at the top of the HTML page (or you can use the settings, look at the docs).

<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-1BmE4kWBq78iYhFldvKuhfTAU6auU8tT94WrHftjDbrCEXSU1oBoqyl2QvZ6jIW3" crossorigin="anonymous">
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/js/bootstrap.bundle.min.js" integrity="sha384-ka7Sk0Gln4gmtz2MlQnikT1wXgYsOg+OMhuP+IlRH9sENBO0LRn5q+8nbTov4+1p" crossorigin="anonymous"></script>

Thank you so much. I found codepen. I am using that now. I just set up an account. It said we could use bootstrap so I thought that was the one we were supposed to use. I was confused, because I couldn’t figure that out.

Thanks again. Much help!!!

You certainly can use Bootstrap if you want but it isn’t a requirement.

I would however suggest trying your hand at writing your own CSS first to learn it and not start out depending on a CSS framework. You will learn a lot more writing your own CSS at this point in the learning process.

Good luck with your projects and happy coding.