Once I incorporated Bootstrap into my project, I noticed a noticeable white space between the div elements

Welcome to My Code Playground

I was sailing smoothly with my project until I decided to include Bootstrap.

Seems like there's something missing in the details, so here I am reaching out. If you spot the issue, please feel free to correct my code.

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="UTF-8">
        <meta name="viewport" content="width=device-width, initial-scale=1.0">
        <link href="https://cdn.jsdelivr.net/npm/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-GLhlTQ8iRABdZLl6O3oVMWSktQOp6b7In1Zl3/Jr59b6EGGoI1aFkw7cmDA6j6gD" crossorigin="anonymous">
        <script src="https://cdn.jsdelivr.net/npm/bootstrap/dist/js/bootstrap.bundle.min.js" integrity="sha384-w76AqPfDkMBDXo30jS1Sgez6pr3x5MlQ1ZAGC+nuZB+EYdgRZgiwxhTBTkF7CXvN" crossorigin="anonymous"></script>
        <link rel="stylesheet" href="style.css">
        <script src="main.js" defer></script>
        <title>Test Home</title>
    </head>
    <body>
        <div class="hero">
            <video autoplay loop muted plays-inline class="back-video">
                <source src="Wolf.mp4" type="video/mp4">
            </video>
            <nav>
                <img src="Wild logo2.png" class="logo">
                <div class="menu-btn">
                    <div class="menu-btn_lines"></div>
                </div>
                <ul class="menu-items">
                    <li><a href="#">HOME</a></li>
                    <li><a href="#mission-id">MISSIONS</a></li>
                    <li><a href="#">COURSE</a></li>
                    <li><a href="#">CONTACT</a></li>
                    <li><a type="submit" class="cta" href="#"><button>LogIn</button></a></li>
                </ul>
            </nav> 
           <div class="content">
            <h1>WILDPRO</h1>
            <a href="#">READ</a>
           </div>
        </div>
        
        <!-- More HTML Content Here -->

    </body>
</html>

CSS Essentials

The CSS code appears to be acting up with positioning or similar issues.

This is a Sneak Peek at My Project

Click for Image Details

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@100;500&display=swap');
*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

/* CSS Styles Continue... */

Answer №1

Ensure that you add the class "m-0" to the p tag inside div.banner as shown below:

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@100;500&display=swap');
      * {
        margin: 0;
        padding: 0;
        box-sizing: border-box;
        font-family: 'Poppins', sans-serif;
      }
      li, a, button {
        font-family: "Montserrat", sans-serif;
        font-weight: 500;
        font-size: 16px;
        text-decoration: none;
      }
      /* Other CSS properties */
    
<head>
      <meta charset="UTF-8">
      <meta name="viewport" content="width=device-width, initial-scale=1.0">
      <link href="https://cdn.jsdelivr.net/npm/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-GLhlTQ8iRABdZLl6O3oVMWSktQOp6b7In1Zl3/Jr59b6EGGoI1aFkw7cmDA6j6gD" crossorigin="anonymous">
      <script src="https://cdn.jsdelivr.net/npm/bootstrap/dist/js/bootstrap.bundle.min.js" integrity="sha384-w76AqPfDkMBDXo30jS1Sgez6pr3x5MlQ1ZAGC+nuZB+EYdgRZgiwxhTBTkF7CXvN" crossorigin="anonymous"></script>
      <link rel="stylesheet" href="style.css">
      <script src="main.js" defer></script>
      <title>test home</title>
    </head>
    <body>
      <div class="hero">
        <!-- Hero section content -->
      </div>
      <div class="banner">
        <!-- Banner section content -->
      </div>
      <div id="mission-id" class="mission">
        <!-- Mission section content -->
      </div>
    </body>

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

Stop horizontal overflow of content

This unique Vuetify demo on CodePen showcases a two-column layout. The first column contains a <v-list> enclosed in a green <v-alert>. By clicking the "toggle text" button, you can switch the title of the first list item between short and long ...

Changing the order of a list in TypeScript according to a property called 'rank'

I am currently working on a function to rearrange a list based on their rank property. Let's consider the following example: (my object also contains other properties) var array=[ {id:1,rank:2}, {id:18,rank:1}, {id:53,rank:3}, {id:3,rank:5}, {id:19,r ...

Is there a way to invert the order of elements in a scrollable container in Google Chrome?

The code snippet provided creates the desired effect, but unfortunately, it only seems to function properly in Firefox and Edge. In Chrome, while the elements are stacked correctly, there is no horizontal scroll bar, making the rightmost items hidden and i ...

Utilizing JQuery AJAX and PHP for Data Encoding

My webpage is encoded in HTML with the charset ISO-8859-2. All content on the page adheres to this charset and appears correctly. However, I am facing an issue when making an Ajax call to a PHP server. When I send the character á and receive the same valu ...

I'm wondering why this isn't working properly and not displaying the closing form tag

What could be the reason for this not functioning properly? The tag appears to close on its own and the closed tag is not being displayed. As a result, the if(isset($_POST['payoneer-btn'])) statement is not triggering. https://i.stack.imgur.com/ ...

Strategies for handling user typos in a JavaScript prompt

Hi there! Just wanted to say that I'm new to this website, so please forgive any posting mistakes I might make. I'm currently taking a web technology class where we're learning JavaScript. In a previous lesson, we covered HTML5 and CSS. Our ...

Looking to tally up the rows in a joined table using Sequelize?

In my current project, I am utilizing the sequelize library to interact with a sqlserver database. The database consists of two tables: data: columns - id, name, team, type history:columns - id, node, date, status, data_id (foreignkey) In terms of their ...

How can I create an HTML select dropdown menu with a maximum height of 100% and a dynamic size?

The dropdown menu I created using an HTML select tag contains a total of 152 options. However, the large number of options causes some of them to be out of view on most monitors when the size is set to 152. I attempted to limit the number of displayed opti ...

Using JavaScript to manipulate HTML content that has been dynamically injected using AJAX

I am in the process of developing a portfolio website where I want to fetch partial HTML files using an AJAX request. Here is the basic structure of the HTML: <div id="portfolio"> // Content will be replaced here </div> <a ...

Having difficulty implementing a personalized color scheme for the mui component

Attempting to set the background color as midnightBlue but encountering an error: Error: Cannot read properties of undefined (reading '100') Upon reviewing the syntax, no errors were found. Perhaps this issue stems from a dependency problem? ...

What is the method for determining the numerical worth of the px containers?

https://i.stack.imgur.com/0K2TD.png Total width of the bar is set to 500px, with the red box at a width of 150px, the yellow box at 200px, and the green box at 50px. CSS Styles: .box { float:left; width:150px; box-shadow:3px 3p ...

Edit content on the fly using ajax (add information to database)

I have a question that pertains to both UX and technical aspects. I am currently creating a list using ajax and PHP. I am unsure whether it is advisable to manipulate the DOM before the backend processes are complete. What potential issues could arise if ...

Leveraging JQuery for form submission

My webpage contains a form with the following structure: <form action="/" method="post"> <select id="SelectedMonth" name="SelectedMonth"> <option>7/1/2017</option> <option>6/1/2017</option> </select> </form> ...

JavaScript or jQuery for filtering table rows

I have limited experience with JavaScript and jQuery, but I am working with a table containing various entries. My goal is to implement a filtering system using a list on the left side of the table. Here is an example I put together: http://jsfiddle.net/B ...

The angular 5 application encountered an issue where it was unable to access the property 'singlePost' due to a null value, resulting

When using the once method to fetch data from the Firebase database, everything works correctly. However, when I try to use the on method, I encounter an error that says: ERROR TypeError: Cannot read property 'singlePost' of null. How can I prope ...

Dealing with errors in a sequelize ORM query: Tips and tricks

Currently, I am implementing Sequelize ORM in my Node/Express project using Typescript. Within the database, there is a 'users' table with a unique column for 'email'. As part of my development process, I am creating a signIn API and ...

Retrieve the unique identifier of the dynamically created button

I have been struggling to retrieve the ID of a dynamically generated button. I attempted to access the specific button ID and utilize it for beforeSend:function(id). However, my efforts were not fruitful. <?php session_start(); require_once "../aut ...

What causes the slash URL to behave differently than other URLs when running through the middleware of NodeJS?

When I type http://localhost:3000/product into the browser, why do I see output for both '/' and '/product'? Take a look at this code snippet below. const express = require('express'); const app = express(); // http://loca ...

Traditional method of choosing a value within a <select> dropdown menu

Check out this example of a static dropdown menu: <select style="width:100px" name="drink_type"> <option value="Water">Water</option> <option value="Soda">Soda</option> <option value="Milk">Milk</option> < ...

Which codec strings are considered valid for the web codecs API?

I am searching for a definitive list of valid strings that can be passed as the `codec` parameter in `VideoEncoder.isConfigSupported({ codec, width, height })`, but I have been unable to find a clear answer so far: The TS declaration file states that it m ...