What is the best way to eliminate a vertical scroll on a webpage

Struggling to achieve a responsive layout with a dynamic background image, but still dealing with unwanted scrolling. I've experimented with overflow:hidden and different background properties without success.

<div class="wrap">
    <div class="header">
        <div class="logo-container">
            <a href="#"></a>
        </div>
        <div class="nav-container">
            <ul>
                <li>
                    <span>
                        <img src="svg-icons/about-service.svg" alt="">
                        <a href="#">About BuyNow Service</a>
                    </span>
                </li>
                <li>
                    <span>
                        <img src="svg-icons/virt-cards.svg" alt="">
                        <a href="#">Virtual Discount Cards</a>
                    </span>
                </li>
                <li>
                    <span>
                        <img src="svg-icons/buy-now-pay-later.svg" alt="">
                        <a href="#">Buy Now, Pay Later</a>
                    </span>
                </li>
            </ul>
        </div>
        <div class="stores-container">
            <a href="#" class="btn-app-store">                  
            </a>
            <a href="#" class="btn-google-play"></a>
        </div>
    </div>      
</div>

<div class="content">
    <div class="bg-content">
        <div class="content-wrap">
            <div class="content-left">
                <div class="content-title">
                    <h1>Buy Now</h1>
                </div>
                <div class="description">
                    <span>Intelligent Shopping Service</span>
                </div>
                <div class="divider-container">
                    <div class="divider-long"></div>
                    <div class="divider-short"></div>
                </div>
                <ul>
                    <li>
                        <img src="svg-icons/round-icon-no-ads-white.svg" width="50" height="50" alt="">
                        <span>Provides attractive offers from various stores, based on your preferences</span>
                    </li>
                    <li>
                        <img src="svg-icons/round-icon-wallet-white.svg" width="50" height="50" alt="">
                        <span>Allows you to <a href="#">defer payment</a></span>
                    </li>
                    <li>
                        <img src="svg-icons/round-icon-profitable-offers-white.svg" width="50" height="50" alt="">
                        <span>No annoying ads</span>
                    </li>
                </ul>
            </div>
            <div class="content-right">
                <img src="img/phone.png" width="226" height="460" alt="">
            </div>
        </div>
    </div>
</div>


<div>
    <div class='container'>
        <span class='pulse-button'>
            <img src="img/orange-arrow-right.png" width="9" height="13" alt="">
        </span>
    </div>
</div>


<footer>
    <div class="footer">
        <div class="copyright">
            <span>&#9400; BuyNow, 2016. All rights reserved</span>
        </div>
        <div class="partners">
            <img src="img/bag.png" alt="">
            <a href="#">For Partners</a>
        </div>
    </div>
</footer>

CSS:

html {
overflow-x: hidden; }
.wrap {
margin: 0 auto;
max-width: 1024px; }
/* HEADER */
.header {
max-width: 1024px;
display: -webkit-box;
display: -webkit-flex;
display: -ms-flexbox;
display: flex;
padding: 19px 20px; }
@media (max-width: 767px) {
.header {
  -webkit-box-orient: vertical;
  -webkit-box-direction: normal;
  -webkit-flex-direction: column;
      -ms-flex-direction: column;
          flex-direction: column; } }
@media (max-width: 767px) {
.header .logo-container {
  margin: 0 auto 10px; } }
.header .logo-container a {
display: block;
width: 41px;
height: 41px;
background: url("../svg-icons/logo.svg");
background-size: 41px 41px; }
.header .logo-container a:hover {
  opacity: .5;
  -webkit-transition: .3s ease-out;
  transition: .3s ease-out; }
.header .nav-container ul {
margin-left: 1px;
margin-top: 0px; }
.header .nav-container ul li {
  float: left;
  margin-right: 15px; }
  @media (max-width: 767px) {
    .header .nav-container ul li {
      margin-bottom: 10px; } }
  .header .nav-container ul li span img {
    float: left;
    margin-right: 4px;
    opacity: .5; }
    @media (max-width: 767px) {
      .header .nav-container ul li span img {
        margin-right: 10px; } }
  .header .nav-container u...       

I'm using three main blocks: wrap, content, and footer. Despite my efforts, the page still has an unwanted scroll bar. For reference, you can view the current look of the page here:

Answer №1

Experiment with applying overflow hidden directly to the body element.

body{
     margin:0px;
     overflow-y: hidden;
     overflow-x: hidden;
}

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

Why does the content not appear again when switching between tabs?

Hello! I'm facing an issue with toggling between two sets of content on my page. Initially, the correct content shows up, but when I switch tabs, the new content doesn't appear. Furthermore, if I click back to the first tab, that content disappea ...

The animated loading image is taking an eternity to actually load

My website is loaded with heavy front-end features and I'm using a loading gif to help with the loading process. However, I've noticed that in Safari, there is a delay before the gif loads after the background does, which takes away from the inte ...

Create a canvas and include input boxes in an HTML document

I'm attempting to create a canvas line diagonally above two textboxes that are also positioned diagonally (similar to Samsung's pattern passcode) when a button is clicked, but I am facing difficulties in achieving this. I have attempted to solve ...

Expansive Bootstrap division

I am seeking assistance in achieving a Bootstrap layout similar to the image provided below. My difficulty lies in ensuring that the yellow bar spans the full width of the Bootstrap container without disrupting the stacking order of columns on mobile view. ...

Challenges with placement of Div elements

Check out my jsFiddle example here: http://jsfiddle.net/pqCGd/. Within the jsFiddle, you will find a large messages div that contains multiple message divs. In this example, I have manually provided an example of a message div instead of using auto-genera ...

What is the best way to adjust the font size for a bootstrap-select dropdown menu?

I attempted to create a new CSS class to customize the appearance of the dropdown menu, but unfortunately, it doesn't seem to be taking effect. #form.py class fundForm(forms.Form): fund = forms.ChoiceField(choices=FUND, required=True, widget=for ...

At a specific point in the route, all CSS and JS links in Node.js vanish

Hey everyone, I'm facing a strange issue where the CSS styling and JS code are not loading when I access the route http://localhost:5000/posts/edit/<%=idofblog%>. As a result, my webpage looks very unattractive, and I'm not sure what's ...

Tips for keeping a dynamic height div in place without affecting surrounding elements

HTML: <div id="autocomplete" hidden></div> <input type = "button" id = "search" value = "Search"> The autocomplete div contains dynamically generated input tags created by jQuery. These input tags cause the button to be shifted down the ...

Minimize white spaces when validating input fields in a form using Javascript

I'm currently facing a challenge with JavaScript, specifically regarding achieving five tasks without using jQuery. Despite trying various RegExp codes, none have successfully worked for me so far. Let's begin with the first task (number 1): El ...

Is it possible to reset the value of an input field with type "number" similar to how it can be done with type "search"?

My Bootstrap 4 form includes various types of inputs, some for numbers, some for text, and others for email. I have managed to style the text inputs to display a cancel button inside with the following code: input[type="search"]::-webkit-search- ...

Disappearing table borders in print view on Firefox

I have been working on creating a printable table that displays correctly in Chrome. However, when viewed in Firefox, the table borders are not showing up. <body> <table> <tbody> <tr> ...

Issue with Expo Google Places Autocomplete: ListView not clickable

I am currently encountering an issue with the GooglePlacesAutocomplete feature. When I input the address query, such as "São C," the 'listView' returns options like "São Caetano, São Paulo ...", however, when I attempt to select an option from ...

Utilizing JavaScript to retrieve input names from arrays

This is the HTML form that I am currently working with: <form action="#" method="post"> <table> <tr> <td><label>Product:<label> <input type="text" /></td> <td><label>Price:<label> ...

Utilizing the NG-CLASS directive within a material table to target a specific 'row' element for styling in CSS

I have a table with various columns, one of which is a status field. I am looking to display colored badges in that column based on the status of each record, which can be "Completed", "Deleted", or "Canceled". I have attempted to use ng-class to dynamical ...

Unusual conduct exhibited by jQuery's css() function for setting the width

My goal is to retrieve the width of the initial .imagen element and apply it to the img within .imagen. HTML: <div class="imagen"> <div class="normal"> <img> </div> <div class="hover"> <img> ...

Ways to incorporate line spacing using CSS

Is there a way to adjust the spacing between the drop down boxes in the sidebar so that they align neatly with the questions in my section? select { font-family: 'Courier New', monospace; color: black; font-weight: bold; font-size: 3 ...

Tap on the image to enlarge

I have a question regarding using thumbnails from Bootstrap. I am trying to create functionality where when I click on a thumbnail, the picture with its original sizes appears and then disappears when clicked anywhere else on the page. Below is an exampl ...

Fiddle demonstrates HTML functionality, while local testing is unsuccessful

Currently, I am in the process of creating an image slider and attempting to run it on my personal computer. However, upon doing so, I have encountered a problem where the page is not rendering correctly. Additionally, I receive an ActiveX warning message ...

View pictures on Angular without an internet connection

As I work on an Angular application, I am faced with a challenge in the app.component.ts file. The application should detect when a user loses internet connection while on a certain page, and in response I want to display a component featuring an error mes ...

`toggle between classes when navigating pages results in a brief white flicker`

I've developed a single page app where each page is initially set to display:none. To show pages, I add a class called .current-page: .current-page{ display:block; } So in order to switch between pages, I simply toggleClass('current-page&a ...