html登录页面代码
body {
background-color: #f0f0f0;
font-family: Arial
sans-serif;
}
.container {
width: 400px;
margin: 0 auto;
margin-top: 100px;
background-color: #fff;
padding: 20px;
border-radius: 5px;
}
h2 {
text-align: center;
margin-bottom: 20px;
}
input[type="text"]
input[type="password"] {
width: *;
padding: 12px;
border: 1px solid #ccc;
border-radius: 4px;
box-sizing: border-box;
margin-bottom: 15px;
}
button[type="submit"] {
background-color: #4CAF50;
color: #fff;
padding: 12px 20px;
border: none;
border-radius: 4px;
cursor: pointer;
width: *;
}
button[type="submit"]:hover {
background-color: #45a049;
}
.error {
color: red;
margin-bottom: 15px;
}
Login
if(isset($_GET['error'])) {
echo $_GET['error'];
}
?>
The code above is a basic HTML login page. Let's go through it step by step:
1. The doctype declaration is specified at the very beginning: ``. This specifies that the document conforms to the HTML5 standard.
2. The `` element encloses the entire HTML document.
3. The `` section contains metadata and links to external resources. In this case
the page title is set to "Login Page" using the `