web前段作业2

笔记

小米

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=l, initial-scale=1.0">
    <title>Document</title>
    <style>
        * {
            margin: 0;
            padding: 0;
        }
        .top {
            width: 1240px;
            height: 140px;
            background-color: black;
        }
        .top1 {
            width: 1240px;
            height: 40px;
            background-color: rgb(47, 46, 46);
        }
        .top2 {
            width: 1240px;
            height: 100px;
            background-color: white;
            position: relative;
        }
        .bottom {
            display: inline-block;
            width: 1240px;
            height: 670px;
            background-color: white;
        }
        .bottom1 {
            width: 1240px;
            height: 460px;
            background-color: rgb(185, 130, 130);
        }
        .bottom2 {
            display: block;
            width: 1240px;
            height: 170px;
            background-color: white;
        }
        .top11 {
            display: inline-block;
            width: 770px;
            height: 40px;
            background-color: rgb(47, 46, 46);
            float: left;
        }
        .top14 {
            display: inline-block;
            width: 262x;
            height: 40px;
            background-color: rgb(240, 8, 8);  
            float: right;   
        }
        
        .top12 {
            display: inline-block;
            width: 142px;
            height: 40px;
            background-color: rgb(47, 46, 46);
            float: left;
        }
        .top13 {
            display: inline-block;
            width: 120px;
            height: 40px;
            background-color:rgb(85, 81, 81);   
            float: right; 
        }
        a {
            color: rgb(212, 206, 206);
            text-decoration: none;
            font-size: 12px;
            line-height: 40px;
            text-align: center;
            padding-left: 6px;
           
        }
        .sep {
            color: rgb(92, 94, 96);
        }
        qq {
            color: black;
        }
        .top21 {
            display: inline-block;
            width: 62px;
            height: 56px;
            background-image: url(./R-C\(1\).png);
            size: 62px;
            border: 6px;
            position: relative;
            top:16px;
        }
        .top22 {
            display: inline-block;
            width: 850px;
            height: 100px;
            position: absolute;
            top: 27px;
            left: 250px;
        }
        .q21 {
            font-size: 18px;
            color: black;
            
        }
        .top23 {
            display: inline-block;
            width: 296px;
            height: 50px;
            background-color: white;
            position: absolute;
            top:30px;
            left: 926px;
        }
        input {
            width: 296px;
            height: 50px;
            
        }
        .bottom11 {
            display: inline-block;
            width: 234px;
            height: 460px;
            background-color: rgb(142, 138, 138);
        }
        .bottom12 {
            position:relative;
            display: inline-block;
            width: 1006px;
            height: 460px;
            background-color: rgb(112, 76, 76);
            float: right;
        }
        li {
            display: block;
            width: 80px;
            height: 40px;
            margin-top: 6px;
            margin-left: 30px;
            color: white    ;
        }
        .ee {
            display: inline;
            float: right;
            color: white;
            padding-right: 20px;
            padding-top: 4px;
        }
        .r1 {
            display: inline-block;
            color: white;
            position: absolute;
            top: 200px;
            left: 20px;
            font-size: 40px;
        }
        .r2 {
            display: inline-block;
            color: white;
            position:absolute;
            top: 200px;
            left: 935px;
            font-size: 40px;
        }
        .bottom21 {
            display: inline-block;
            width: 234px;
            height: 170px;
            background-color: rgb(102, 95, 95);
            margin-top: 15px;
        }
        .bottom22 {
            display: flex;
            width: 978px;
            height: 170px;
            background-color: white;
            float: right;
            margin-left: 14px;
            justify-content: space-between;
            margin: 0 auto;
        }
        .b6 {
            display: inline;
            width: 76px;
            height: 83px;
            color: white;
            float: left;
            border: 1px solid white;
            text-align: center;
        }
        .bottom221 {
            display: inline-block;
            width: 316px;
            height: 170px;
            background-color: rgb(237, 236, 236);
            margin-top: 15px;
        }
        .bottom222 {
            display: inline-block;
            width: 316px;
            height: 170px;
            margin-top: 15px;
            background-color: rgb(237, 236, 236);
        }
        .bottom223 {
            display: inline-block;
            width: 316px;
            height: 170px;
            background-color: rgb(237, 236, 236);
            margin-top: 15px;
        }
        .p1 {
            display: inline-block;
            width: 9.2px;
            height: 9.2px;
            border-radius: 9.2px;
            border: 2px solid rgb(225, 222, 222);
            z-index: 1;
         }
        .p1:hover {
            background-color: white;
         }
         .p11 {
             width: 120px;
             height: 9.2px;
             position: absolute;
             bottom: 50px;
             right: 5px;
         }
    </style>
</head>
<body>
    <div class="top">
        <div class="top1">
            <div class="top11">
                <a href="qq">小米官网</a>
                <span class="sep">|</span>
                <a href="qq">小米商城</a>
                <span class="sep">|</span>
                <a href="qq">小米澎湃OS</a>
                <span class="sep">|</span>
                <a href="qq">loT</a>
                <span class="sep">|</span>
                <a href="qq">云服务</a>
                <span class="sep">|</span>
                <a href="qq">天星科技</a>
                <span class="sep">|</span>
                <a href="qq">有品</a>
                <span class="sep">|</span>
                <a href="qq">小爱开放平台</a>
                <span class="sep">|</span>
                <a href="qq">资质证照</a>
                <span class="sep">|</span>
                <a href="qq">协议规则</a>
                <span class="sep">|</span>
                <a href="qq">下载app</a>
                <span class="sep">|</span>
                <a href="qq">Select Locaktion</Select></a>
            </div>
            <div class="top14">
                <div class="top12">
                    <a href="qq">登录</a>
                    <span class="sep">|</span>
                    <a href="qq">注册</a>
                    <span class="sep">|</span>
                    <a  id="qq">消息通知</a>
                </div>
                <div class="top13">
                    <a href="ww">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;购物车(0)</a>
                </div>
            </div>
        </div>
        <div class="top2">
            <div class="top21"></div>
            <div class="top22">
                <a href="" class="q21">Xiaomo手机</a>
                <a href="" class="q21">Redmi手机</a>
                <a href="" class="q21">电视</a>
                <a href="" class="q21">笔记本</a>
                <a href="" class="q21">平板</a>
                <a href="" class="q21">家电</a>
                <a href="" class="q21">路由器</a>
                <a href="" class="q21">服务中心</a>
                <a href="" class="q21">社区</a>
            </div>
            <div class="top23" ><input type="txet" placeholder="手机" ></div>
        </div>
    </div>
    <div class="bottom">
        <div class="bottom1">
            <div class="bottom11">
                <ul>
                    <span class="ee">&gt;</span>
                    <li>手机</li>
                    <span class="ee">&gt;</span>
                    <li>电视</li>
                    <span class="ee">&gt;</span>
                    <li>家电</li>
                    <span class="ee">&gt;</span>
                    <li>笔记本平板</li>
                    <span class="ee">&gt;</span>
                    <li>出行穿戴</li>
                    <span class="ee">&gt;</span>
                    <li>耳机音像</li>
                    <span class="ee">&gt;</span>
                    <li>健康儿童</li>
                    <span class="ee">&gt;</span>
                    <li>生活箱包</li>
                    <span class="ee">&gt;</span>
                    <li>智能路由器</li>
                    <span class="ee">&gt;</span>
                    <li>电源配件</li>
                    
                </ul>
            </div>
            <div class="bottom12">
                <span class="r1">&lt;</span>
                <span class="r2">&gt;</span>
                <div class="p11">
                    <div class="p1"></div>
                    <div class="p1"></div>
                    <div class="p1"></div>
                    <div class="p1"></div>
                    <div class="p1"></div>
                    <div class="p1"></div>
                </div>
            </div>
        </div>
        <div class="bottom2">
            <div class="bottom21">
                <div class="b6">保障服务</div>
                <div class="b6">企业团购</div>
                <div class="b6">F码通道</div>
                <div class="b6">米粉卡</div>
                <div class="b6">以旧换新</div>
                <div class="b6">话费充值</div>
            </div>
            <div class="bottom22">
                <div class="bottom221"></div>
                <div class="bottom222"></div>
                <div class="bottom223"></div>
            </div>
        </div>
    </div>
</body>
</html>

倒计时

<!DOCT-YPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    
    <span>离2024年7月3日还有:</span>
    <span id="d">0</span>天
    <span id="h">0</span>小时
    <span id="m">0</span>分钟
    <span id="s">0</span>秒
   
    <script>
    let date = new Date('2024-07-03T00:00:00');

    function update() {
        let now_date = new Date();
        let distance = date - now_date;
        let day = Math.floor(distance / (1000 * 60 * 60 * 24));
        let hour = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
        let minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
        let seconds = Math.floor((distance % (1000 * 60)) / 1000);

        document.getElementById('d').textContent = day;
        document.getElementById('h').textContent = hour;
        document.getElementById('m').textContent = minutes;
        document.getElementById('s').textContent = seconds;
    }
    update();
    setInterval(update,1000);
    </script> 
</body>
</html>

  • 2
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
个人网页是指一个个人展示自己信息和作品的网站,通常用来展示个人的专业技能、工作经历、项目经验、个人作品等内容。对于web前端作业的个人网页来说,一般需要考虑以下几个方面。 首先,设计界面。一个好的个人网页需要有清晰、美观的界面设计,包括网页的布局、颜色搭配、字体选择等。界面设计要符合个人风格,并且要注重用户体验,保证用户能够方便地浏览信息。 其次,编写网页代码。作为web前端作业,个人网页需要用HTML、CSS和JavaScript等前端技术来编写。通过合理的标签和样式设置,来实现网页的各种功能,包括导航栏、轮播图、响应式布局等。 另外,需要考虑网页的信息展示。个人网页的目的是展示个人信息和作品,因此需要合理地组织内容,包括个人简介、技能展示、工作经历、项目经验、作品展示等。可以通过分块、分类和标签等方式使信息更易于理解和浏览,同时也可以增加交互效果,使网页更具吸引力。 最后,要保证个人网页的兼容性和性能。考虑到不同浏览器和设备的差异,需要进行浏览器兼容性测试,以确保网页在各种环境下良好运行。同时还要考虑网页加载速度,尽量减少文件大小和请求次数,提高网页性能。 综上所述,web前端作业的个人网页是一个展示个人信息和作品的网站,需要考虑界面设计、编写网页代码、信息展示和兼容性性能等方面。通过合理的设计和编写,打造一个令人满意的个人网页。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值