Problem with Grid and Boostrap

So im trying to follow this guy’s course, wrote all exact same codes, but i dont receive same thing as him, mine is completely messed up when i do preview. Anyone help?
This is a link of a guy im following: https://scrimba.com/c/c2gd3T2
Here’s my html code:

<!doctype html>
<html>
<head>
    <title>Test Project</title>
    <meta http-equiv="content-type" type="text/html">
    <meta charset="UTF-8">
    <meta name="viewport"content="width=device-width, initial-scale=1.0">
<meta name="viewport"content="height=device-height, initial-scale=1.0">
    <meta name="author" content="Ismar">
    <meta name="generator" content="Brackets">
    <meta name="description" content="Some description">
    <meta name="keywords" conent="HTML,CSS,JavaScript,PHP">
    <link rel="stylesheet" type="text/css" href="Test.css">
    <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous">
    </head>
<body>
    <h1 class="text-center">Test Project</h1>
    
    <div class="container-fluid">
  <h1 class="text-center">Hello world</h1>

  
        <!-- Grid -->
        <h1 class="title">CSS Grid</h1>
        <div class="wrapper">
        <div class="header">Header</div>
        <div class="menu">Menu</div>
        <div class="content">Content</div>
        <div class="footer">Footer</div>
        </div>
       
        <!-- Bootstrap -->
        <h1 class="title">Boostrap</h1>
        <div class="row">
        <div class="col-xs-12 header">Header</div>
        <div class="col-xs-4 menu">Menu</div>
        <div class="col-xs-8 content">Content</div>
        <div class="col-xs-12 footer">Footer</div>
        </div>
    
        
        
        
        
        </div>
    
<script src="https://code.jquery.com/jquery-3.2.1.slim.min.js" integrity="sha384-KJ3o2DKtIkvYIK3UENzmM7KCkRr/rE9/Qpg6aAZGJwFDMVNA/GpGFF93hXpG5KkN" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.12.9/umd/popper.min.js" integrity="sha384-ApNbgh9B+Y1QKtv3Rn7W3mgPxhU9K/ScQsAP7hUibX39j7fakFPskvXusvfa0b4Q" crossorigin="anonymous"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/js/bootstrap.min.js" integrity="sha384-JZR6Spejh4U02d8jOt6vLEHfe/JQGiRRSQQxSfFWpi1MquVdAyjUar5+76PVCmYl" crossorigin="anonymous"></script>
    </body>
</html>

My CSS:


.wrapper {display: grid; grid-template-columns: repeat(12, 1fr);
grid-template-rows: 40px 100px 40px;}

.header {grid-column: span 12;}

.menu {grid-column: span 4;}

.content {grid-column: span 8;}

.footer {grid-column: span 12;}

@media screen and (max-width: 480px) {
    .header {grid-column: span 6;}
    .menu {grid-row: 1; grid-column: span 6;}
    .content {grid-column: span 12;}
}

Here’s a pic of what i get: https://imgur.com/a/P14UP

Is it something to do with Brackets? Should i change text editor, if i do can you recommend me any?

First through is, which version of bootstrap is he using?
Most courses are written for bootstrap 3.3.7 (Maybe something else but 3 is the major version) and you are using bootstrap 4.

Edit: Just checked and they are in fact using 3.3.7 and not 4.

Damn didnt notice that. Thanks

1 Like