商城登陆注册页面html
时间: 2023-12-08 10:38:16 浏览: 57
以下是一个简单的商城登录注册页面的HTML代码,包括登录表单、注册表单和一些基本的样式:
```html
<!DOCTYPE html>
<html>
<head>
<title>商城登录注册页面</title>
<style>
body {
background-color: #f2f2f2;
font-family: Arial, sans-serif;
}
h1 {
text-align: center;
margin-top: 50px;
}
form {
background-color: #fff;
border-radius: 5px;
box-shadow: 0 0 10px rgba(0,0,0,0.3);
padding: 20px;
margin: 0 auto;
max-width: 400px;
}
input[type="text"], input[type="password"] {
width: 100%;
padding: 10px;
margin-bottom: 20px;
border: none;
border-radius: 3px;
box-shadow: 0 0 5px rgba(0,0,0,0.1);
font-size: 16px;
}
input[type="submit"] {
background-color: #4CAF50;
color: #fff;
border: none;
border-radius: 3px;
padding: 10px;
font-size: 16px;
cursor: pointer;
}
input[type="submit"]:hover {
background-color: #3e8e41;
}
</style>
</head>
<body>
<h1>商城登录注册页面</h1>
<form id="login-form">
<h2>登录</h2>
<label for="username">用户名:</label>
<input type="text" id="username" name="username" required>
<label for="password">密码:</label>
<input type="password" id="password" name="password" required>
<input type="submit" value="登录">
</form>
<form id="register-form">
<h2>注册</h2>
<label for="new-username">用户名:</label>
<input type="text" id="new-username" name="new-username" required>
<label for="new-password">密码:</label>
<input type="password" id="new-password" name="new-password" required>
<label for="confirm-password">确认密码:</label>
<input type="password" id="confirm-password" name="confirm-password" required>
<input type="submit" value="注册">
</form>
</body>
</html>
```
该页面包含两个表单,一个是登录表单,一个是注册表单。登录表单包含用户名和密码两个输入框,以及一个登录按钮。注册表单包含新用户名、新密码和确认密码三个输入框,以及一个注册按钮。表单的样式使用了一些基本的CSS样式,包括背景颜色、字体、边框、圆角、阴影等。