分享好友 资讯首页 资讯分类 切换频道

注册页面css样式

2025-12-23 06:4000

HTML结构示例。

注册页面css样式

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>注册页面</title>
    <link rel="stylesheet" href="styles.css">
</head>
<body>
    <div class="register-container">
        <h2>注册</h2>
        <form>
            <div class="form-group">
                <label for="username">用户名:</label>
                <input type="text" id="username" name="username" required>
            </div>
            <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>
            <button type="submit">注册</button>
        </form>
    </div>
</body>
</html>

CSS样式示例(styles.css):

注册页面css样式

body {
    font-family: Arial, sans-serif;
    background-color: #f4f4f4;
}
.register-container {
    max-width: 400px;
    margin: 50px 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;
}
label {
    display: block;
    margin-bottom: 5px;
}
input[type="text"], input[type="email"], input[type="password"] {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 3px;
}
button[type="submit"] {
    width: 100%;
    padding: 15px;
    background-color: #4CAF50; /Green color */               color: white; /白色字体颜色 */ border: none;  border-radius: 5px;  cursor: pointer;  transition: background-color 0.3s ease;            /注意请确保您的CSS代码符合最佳实践和规范,以提高代码的可读性和可维护性 */ } /注意注释仅为说明用途,实际使用时请移除注释内容并保留有效的CSS代码块
举报
收藏 0
打赏 0
评论 0
短信查话费怎么查联通号码的
联通号码短信查话费,只需发送特定代码至查询号码。操作简单,方便快捷。例如编辑短信“CXYE”至10010,即可查询话费余额。具体查询代码可能有变化,建议以联通最新信息为准。

0评论2026-04-070

 
友情链接