HTML代码。

<!DOCTYPE html>
<html>
<head>
<title>邮箱注册页面</title>
<link rel="stylesheet" type="text/css" href="styles.css">
</head>
<body>
<div class="container">
<h2>邮箱注册</h2>
<form action="register.php" method="post">
<div class="form-group">
<label for="email">邮箱地址:</label>
<input type="email" id="email" name="email" required>
</div>
<div class="form-group">
<label for="password">密码:</label>
<input type="password" id="password" name="password" required>
</div>
<div class="form-group">
<label for="confirm_password">确认密码:</label>
<input type="password" id="confirm_password" name="confirm_password" required>
</div>
<div class="form-group">
<input type="submit" value="注册">
</div>
</form>
</div>
</body>
</html>CSS代码(在styles.css文件中):
body {
font-family: Arial, sans-serif;
background-color: #f0f0f0;
}
.container {
max-width: 400px;
margin: 0 auto;
padding: 20px;
background-color: #fff;
border-radius: 5px;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}
h2 {
text-align: center;
}
form {
display: flex;
flex-direction: column;
}
.form-group {
margin-bottom: 20px;
}代码只是一个简单的示例,你可以根据自己的需求进行修改和扩展,在实际开发中,还需要考虑安全性、数据验证等方面的问题,还需要编写后端代码来处理用户提交的数据。





