Bug discovered in Chrome causing elements to shift position after pinch zooming

Hey there, I'm facing an issue on my website. When the footer is set to position absolute and the content is smaller, it doesn't push the footer to the end as expected. I've implemented some techniques to address this, but I'm not sure if they're ideal.

You can view the site here

The problem only occurs in the mobile version of Chrome when pinch zooming on the footer object. You can see the issue in this video.

Here is the code snippet:

It's built using HTML5 & CSS3 with Bootstrap 4.2.1:

https://pastebin.com/q01VHqiN

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Testing page</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0, shrink-to-fit=no">
    <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.2.1/css/bootstrap.min.css" integrity="sha384-GJzZqFGwb1QTTN6wy59ffF1BuGJpLSa9DkKMp0DgiMDm4iYMj70gZWKYbI706tWS" crossorigin="anonymous">
    <script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
    <style>
        body {
            background-color: dimgray;
        }
        img[alt="www.000webhost.com"] {
            display:none;
        div.row [class*="col-12"] {
            margin-bottom: 1rem;
        }
        div.nomarginbottom {
            margin-bottom: 0 !important;
        }
        .display-5 {
            font-size: 2.5rem;
            font-weight: 300;
            line-height: 1.2;
        }
        /*footer on the bottom */
        html {
            height:100%;
        }
        body {
            min-height:100%;
            position:relative;
        }
        body::after {
            content:'';
            display:block;
            height:100px;
        }
        .footer-bottom {
            position:absolute;
            bottom:0;
            width:100%;
        }

        /* smaller letters on smaller screen - footer */
        @media (max-width: 741px) {
            .footer {
                font-size: 100%;
            }
        }
        @media (max-width: 600px) {
            .footer {
                font-size: 80%;
            }
        }
    </style>
</head>
<body>

    <div class="pt-0 box jumbotron jumbotron-fluid text-center">    
        <h1 class="display-3">Test</h1>
    </div>


    <div class="container-fluid text-center text-white">

        <div class="row text-center mb-4 d-none d-lg-block">
            <div class="col-12">
                <h1>Web developer in 2019 &lt;b&gt;like&lt;/b&gt;...</h1>
            </div>
        </div>

        <div class="row text-center mb-5">
            <div class="col-12">
                <h2>Happy New CODE!</h2>
            </div>
        </div>

        <div class="row footer-bottom mt-5">
            <div class="col-12 footer bg-dark p-3 lead mb-0">The site was created by Jan Kustra, the executive of: XeDA+ Department of Websites.</div>
        </div>
    </div>

    <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.6/umd/popper.min.js" integrity="sha384-wHAiFfRlMFy6i5SRaxvfOCifBUQy1xHdJ/yoi7FRNXMRBu5WHdZYu1hA6ZOblgut" crossorigin="anonymous"></script>
    <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.2.1/js/bootstrap.min.js" integrity="sha384-B0UglyR+jN6CkvvICOB2joaf5I4l3gm9GU6Hc1og6Ls7i6U/mkkaduKaBhlAXv9k" crossorigin="anonymous"></script>
</body>
</html>

Answer №1

Consider incorporating left: 0; right: 0; or overflow-x: hidden; into the footer div and populate your page with content, as this could be beneficial. Another suggestion is to utilize the <footer> tag for better structure.

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

Expanding the link directory

I am struggling with accessing the "file.php" in the "folder1" directory from the "site" directory. The href path I'm using is: href = "folder1/file.php" However, it redirects me to: href = "folder1/folder1/file.php" Additionally, when try ...

Changing the scrolling behavior of an iframe

I'm attempting to update the layout of to resemble . To achieve this, I've created a page with an iframe. However, I'm facing an issue with the iframe scroll function, as it does not match the desired design. I've experimented with t ...

Understanding the structure of html elements

Within my downloaded HTML files, I consistently have key executives mentioned at the beginning of each file (like "Dror Ben Asher" in the code snippet below): <DIV id=article_participants class="content_part hid"> <P>Redhill Biopharma Ltd. (NA ...

Looking to extract specific information from a webpage using VBA

I'm trying to extract the text 'Catalog Manager/ Sales' & 'EOL (product/component)' from the view source tab using VBA. Here is an excerpt of the view source code: <tr> <td nowrap="true" valign="top" width="165px" cl ...

What's the best way to ensure that the button stays on the right side of the Bootstrap 4 card header, no matter the device or

Here is my code for a refresh button in the header of a Bootstrap 4 card: <div class="animated fadeIn"> <div class="row"> <div class="col-lg-12"> <div class="card"> <div class="card-header"> ...

Changing class in jQuery ignores CSS style

I have a id="header" div that initially has css rule: padding: 25px 0;. I want to decrease the padding of this div when scrolling down the page. $(document).ready(function() { var headerID = $("#header"); $(this).scroll(function() { if (!$(this).s ...

Error: Trying to access 'items' property of an undefined variable leads to a TypeError

I am currently working on creating a webpage with Angular 8 that fetches data from a REST API in JSON format by passing the request ID. My goal is to display this data in an HTML table that I have created. However, I encountered the following error: Typ ...

What could be causing my Bootstrap 4 Carousel to not appear on my site?

I followed all the steps to include the Bootstrap 4 carousel code correctly, including adding the necessary libraries and plugins at the end. While the navbar is functioning properly, I am puzzled as to why the carousel is not displaying. Is there somethin ...

Change a variable on the fly without needing to reload the page

<!DOCTYPE html> <!-- To update your slot machine images without refreshing the page, you can use JavaScript to dynamically change the images on click. Here's a simple example using JavaScript: <html> <head> <title& ...

How can Jquery output only the selected HTML element and not its descendants?

Here is the HTML code I am currently working with: <ul id="seasonsDropDown"> <li>FALL 2013 HAUTE COUTURE <ul class="designers"> <li>Alexander Wang</li> <li>BCBG MAX Azria</li> <li> ...

Mobile version experiencing issue with Navbar not collapsing

The dropdown navigation bar on the mobile version of my website is not functioning properly. Despite several attempts, I have been unable to figure out a way to make it work effectively. <!DOCTYPE html> <html lang="en"> <head> & ...

"Improve text visibility on your website with Google PageSpeed's 'Ensure text remains visible' feature, potentially saving you

Click here for the image reference showing the 0ms potential saving message I'm having trouble with a warning in Google PageSpeed and I've tried everything. This is the code I'm using to define the font-family: @font-face { font-family: ...

What HTML element identifies the beginning of a particular section?

It has been suggested that Google frowns upon using identical content across multiple websites. Is there a method to mark or label a section of content with its "source"? For example, an attribute might look like this: <div original-content="http://s ...

What is the best way to disable all fields in one click using AngularJS?

I have created this HTML code that allows all fields to become editable when the "edit" button is clicked. However, I only want a specific row within the table to be editable, not the entire table. Here is the HTML code snippet: <tr ng-repeat="employe ...

Moving the sidebar from the app component to a separate component in Angular results in a situation where the sidebar does not maintain full height when the page is scrolled down

Within my Angular application, I have implemented a sidebar as a separate component. Previously, the content of the sidebar was housed within the main app component's HTML page, and it functioned properly by taking up the full height of the page when ...

Backdrop in Bootstrap Modal Does Not Fully Cover Buttons and Input Fields

Currently, I am working with mysql and php on a user.php page that caters to user interactions. The main content in the center <div> is dynamically updated through php whenever a link on the same page is clicked. To elaborate, when a user clicks on a ...

Unable to display images - PhoneGap

I am experiencing an issue where images that are being dynamically added to my HTML display correctly in Firefox, but on all the Android devices I have tested, the images do not appear. Instead, a box with their alt text is shown. HTML: <div class="ui ...

A guide on linking to different sections on your webpage with Framework7

Exploring the traditional method of linking to specific sections on a webpage, where the anchor tag points to an element's ID within the page. Here is an example: <div class="main" id="section1"> <h2>Section 1</h2& ...

Slide content towards the left to uncover the option to delete

Is there a way to achieve this task? Here is what I'm currently working on: https://jsfiddle.net/Lg0wyt9u/967/ <li> <div class='type'><i class='fa fa-arrow-circle-right'>I</i></div> & ...

Customizing the HTMLElement class to modify particular attributes

Is there a way to modify the behavior of an HTMLElement's scrollTop property by adding some extra logic before updating the actual value? The common approach seems to be deleting the original property and using Object.defineProperty(): delete element. ...