• 首页 首页 icon
  • 工具库 工具库 icon
    • IP查询 IP查询 icon
  • 内容库 内容库 icon
    • 快讯库 快讯库 icon
    • 精品库 精品库 icon
    • 问答库 问答库 icon
  • 更多 更多 icon
    • 服务条款 服务条款 icon

web前端登陆注册界面html+css+js

武飞扬头像
橙子不填呢
帮助1

学新通

学新通

 学新通

制作内容:粉丝网页登录注册功能页面

作品风格:主题:以“时代少年团”为爱豆,制作粉丝可以交流、获取爱豆动态、购买爱豆周边的网页。

网站的登录界面:背景是七个爱豆在舞台上的光影图,登陆界面整体色彩为蓝色也是意寓粉丝可以在这样一个蓝色深海般的网站中畅所欲言。页面含有背景音乐 “少年时代”听之舒缓安心会让整个登录过程中的粉丝更加沉浸。

注册界面:整体颜色采用了深沉灰色,结构框架简约大方。

网页界面:整体选择蓝色,页面介绍爱豆团体的口号并在旁边轮播爱豆的美图,右侧依次有其他功能,功能选择背景颜色为橙色使之更加醒目,可让粉丝清晰的找到自己要去的板块。

制作思路:

首先做静态网页再制作动态链接。实现页面,注册至少需要username,password,age,email,phone,利用js实现当用户没有填写任何内容时提醒用户名,密码,年龄,邮箱或手机号不能为空,登陆页面利用js实现当用户没有填写时提醒用户名或密码不能为空,主页利用jquery实现鼠标悬浮更换图片的轮播图效果。

登录界面代码实现如下:

  1.  
    <!DOCTYPE html>
  2.  
    <html lang="en">
  3.  
     
  4.  
    <head>
  5.  
     
  6.  
    <title>TNT登录界面</title>
  7.  
    <style type="text/css">
  8.  
     
  9.  
    body {
  10.  
    margin: 0;
  11.  
    padding: 0;
  12.  
    background: url(image/TNT6.jpg) no-repeat;
  13.  
    background-size: 1600px 800px
  14.  
    }
  15.  
     
  16.  
    .div {
  17.  
    width: 400px;
  18.  
    height: 500px;
  19.  
     
  20.  
    position: absolute;
  21.  
    top: 50%;
  22.  
    left: 50%;
  23.  
    transform: translate(-50%, -50%);
  24.  
    overflow: hidden;
  25.  
    }
  26.  
     
  27.  
    .head-div {
  28.  
    width: 100px;
  29.  
    height: 100px;
  30.  
    border: 1px solid #999;
  31.  
    border-radius: 50%;
  32.  
    margin: 0 auto 10px auto;
  33.  
    background: url(image/TNT1.webp) no-repeat;
  34.  
    background-size: 100px 100px;
  35.  
    }
  36.  
     
  37.  
    .sign-div {
  38.  
    width: 400px;
  39.  
    height: 385px;
  40.  
    text-align: center;
  41.  
    outline: none;
  42.  
    border: 1px solid rgb(94, 92, 233);
  43.  
    border-radius: 8px;
  44.  
    background-color: rgba(172, 235, 243, .2);
  45.  
    box-sizing: border-box;
  46.  
    }
  47.  
     
  48.  
    .sign-div h1 {
  49.  
    margin-bottom: 10px;
  50.  
    color: rgb(29, 26, 26);
  51.  
    }
  52.  
     
  53.  
    input {
  54.  
    width: 250px;
  55.  
    height: 44px;
  56.  
    border: none;
  57.  
     
  58.  
    outline: none;
  59.  
     
  60.  
    box-sizing: border-box;
  61.  
    display: block;
  62.  
    padding: 0 16px;
  63.  
    }
  64.  
     
  65.  
    .input-text {
  66.  
    margin: 5px auto;
  67.  
    border-radius: 16px;
  68.  
    }
  69.  
     
  70.  
    .input-text:hover {
  71.  
    border: 0.5px solid rgb(76, 76, 233);
  72.  
    transition: 0.5s;
  73.  
    border-radius: 4px;
  74.  
    }
  75.  
     
  76.  
    .input-btn {
  77.  
    margin: 30px auto 20px;
  78.  
    border-radius: 44px;
  79.  
    cursor: pointer;
  80.  
    background-color: rgba(84, 175, 249, 0.8);
  81.  
    }
  82.  
     
  83.  
    .input-btn:hover {
  84.  
    color: #fff;
  85.  
    font-size: 16;
  86.  
    border-radius: 4px;
  87.  
    transition: 0.5s;
  88.  
    background-color: rgba(10, 138, 243, 0.8);
  89.  
    }
  90.  
     
  91.  
    .sign-div a {
  92.  
    text-decoration: none;
  93.  
    color: rgb(92, 61, 112);
  94.  
    font-size: 14px;
  95.  
    padding: 10px;
  96.  
    transition: 0.8s;
  97.  
    display: block;
  98.  
    }
  99.  
     
  100.  
    a:hover {
  101.  
    color: #FFF;
  102.  
    background: rgba(0, 0, 0, .3);
  103.  
    border-radius: 8px;
  104.  
    }
  105.  
    </style>
  106.  
     
  107.  
    </head>
  108.  
     
  109.  
    <body>
  110.  
    <audio controls="controls" autoplay="true" look="-1">
  111.  
    <source src="image/少年时代.mp3"/>
  112.  
    </audio>
  113.  
     
  114.  
     
  115.  
     
  116.  
     
  117.  
    <div class="div">
  118.  
    <div class="head-div"></div>
  119.  
    <div class="sign-div">
  120.  
    <form class="" action="#" method="POST">
  121.  
    <h1>登录</h1>
  122.  
    <input class="input-text" type="text" name="username" placeholder="帐号">
  123.  
    <input class="input-text" type="password" name="password" id="L_pwd" placeholder="密码">
  124.  
    <a href="注册.html" target="_blank" >注册</a>
  125.  
    <a href="简介.html" target="_blank" >TNT简介</a>
  126.  
    <input type="button" class="input-btn" id="L_login" value="登录" onclick=javascrtpt:jump1()>
  127.  
    <!-- <input class="input-btn" type="submit" value="登录"> -->
  128.  
    <a href="#" target="_blank">忘记密码?</a>
  129.  
    </form>
  130.  
    </div>
  131.  
    </div>
  132.  
    <script>
  133.  
     
  134.  
    L_pwd.onchange = function(){
  135.  
    var L_pwd = this.value;
  136.  
    // var reg = /^(?![0-9] $)(?![a-zA-Z] $)[0-9A-Za-z]{6,}$/;
  137.  
    // if(!reg.test(L_pwd)){
  138.  
    // alert("密码长度要大于6位,由数字和字母组成,请重新输入!");
  139.  
    // return false;
  140.  
    // }
  141.  
    }
  142.  
     
  143.  
     
  144.  
    var password=localStorage.getItem("password");
  145.  
    console.log("pwd:" password);
  146.  
     
  147.  
    function jump1(){
  148.  
     
  149.  
    console.log( document.getElementById("L_pwd").value);
  150.  
     
  151.  
    var Password = document.getElementById("L_pwd");
  152.  
     
  153.  
    if( password==document.getElementById("L_pwd").value){
  154.  
    alert("登录成功!");
  155.  
    window.location.href="简介.html";
  156.  
    }
  157.  
    else if( Password.value =="") {
  158.  
    alert("密码不能为空!");
  159.  
    return false;
  160.  
    }
  161.  
    else{
  162.  
    alert("邮箱或密码错误!");
  163.  
    return false;
  164.  
    }
  165.  
    }
  166.  
     
  167.  
    </script>
  168.  
    </body>
  169.  
    </html>
学新通

在网页制作过程中,我收获了很多技能和经验,同时也遇到了一些挑战和不足:

收获:

1. 掌握了HTML、CSS和JavaScript等前端技术,可以制作简单到较复杂的静态网页。

2. 学习了如何利用开发工具和调试工具,编写高效且易于维护的代码。

3. 熟悉了页面排版和布局技术,例如使用盒模型、Flexbox和Grid等技术。

4. 学会了通过细致的页面设计和规范的代码规范编写,提高用户体验和网站的质量。

不足:

1. 编写代码时候没有考虑到兼容性,导致一些浏览器上会出现一些排版或样式错误。

2. 没有对前端框架和流行库有足够的了解,限制了我制作复杂页面和交互的能力。

3. 页面的SEO优化不足。

4. 认为自己给页面添加越多的特性和动画效果越好,实际上可能会让用户体验变得更差,需要更好地权衡。

总体来说,网页制作的过程让我学到了很多,但也发现自己的不足,以后需要更加努力地学习和实践。

代码包下载

这篇好文章是转载于:编程之路

  • 版权申明: 本站部分内容来自互联网,仅供学习及演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,请提供相关证据及您的身份证明,我们将在收到邮件后48小时内删除。
  • 本站站名: 编程之路
  • 本文地址: /boutique/detail/tanhhaebhf
系列文章
更多 icon
同类精品
更多 icon
继续加载