CSS3 implements footer fixed at the bottom (always at the bottom no matter how high the page is)

CSS3 implements footer fixed at the bottom (always at the bottom no matter how high the page is)

Preface

Fix the footer area at the bottom. No matter how tall or wide the page is, it will always stay at the bottom, just like the mobile menu.

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title>document</title>

<!-- css -->
<style>
#demo{
 position: fixed;
    left: 0px;
    bottom: 0px;
    width: 100%;
    height: 50px;
    background-color: #eee;
    z-index: 9999;
}
</style>

</head>
<body>
<footer id="demo">I am footer</footer>
</body>
</html>

Summarize

The above is the CSS3 that I introduced to you. I hope it will be helpful to you. If you have any questions, please leave me a message and I will reply to you in time. I would also like to thank everyone for their support of the 123WORDPRESS.COM website!
If you find this article helpful, please feel free to reprint it and please indicate the source. Thank you!

<<:  Detailed explanation of this pointing in JS arrow function

>>:  Building a Redis cluster on Docker

Recommend

How to Monitor Linux Memory Usage Using Bash Script

Preface There are many open source monitoring too...

How to install MySQL 5.7 on Ubuntu and configure the data storage path

1. Install MySQL This article is installed via AP...

ElementUI implements cascading selector

This article example shares the specific code of ...

Jmeter connects to the database process diagram

1. Download the MySQL jdbc driver (mysql-connecto...

How to choose the right MySQL datetime type to store your time

When building a database and writing a program, i...

JavaScript Dom implements the principle and example of carousel

If we want to make a carousel, we must first unde...

Using jQuery to implement the carousel effect

What I bring to you today is to use jQuery to imp...

js to achieve simple magnifying glass effects

This article example shares the specific code of ...

HTML basic syntax is convenient for those who are just starting to learn HTML

1.1 General marking A general tag consists of an ...

Markup language - web application CSS style

Click here to return to the 123WORDPRESS.COM HTML ...

How to implement the singleton pattern in Javascript

Table of contents Overview Code Implementation Si...

Solve the problem of Nginx returning 404 after configuring proxy_pass

Table of contents 1. Troubleshooting and locating...