以下是一个简单的用户注册页面的 HTML 代码示例:

```html
body {
font-family: Arial, sans-serif;
background-color: #f2f2f2;
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
margin: 0;
}
.registration-form {
background-color: white;
padding: 20px;
border-radius: 5px;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
max-width: 400px;
width: 90%;
}
.form-group {
margin-bottom: 15px;
}
label {
display: block;
font-weight: bold;
margin-bottom: 5px;
}
input[type="text"],
input[type="password"],
input[type="tel"] {
width: 100%;
padding: 10px;
border: 1px solid #ccc;
border-radius: 4px;
box-sizing: border-box;
}
button {
background-color: #4CAF50;
color: white;
padding: 10px 20px;
border: none;
border-radius: 4px;
cursor: pointer;
width: 100%;
}
button:hover {
background-color: #45a049;
}
```
这个注册页面包含了姓名、邮箱、手机号和密码等常见的注册字段。页面使用 CSS 进行了简单的样式美化,使其在手机屏幕上也能很好地显示。当用户填写完所有必填字段并点击"注册"按钮时,浏览器会提交表单数据。您可以根据具体需求进一步完善这个页面的功能和样式。

查看详情

查看详情