2018-08-17day-24作业

CSS文件编辑京东登录界面

html文件

<!DOCTYPE html>
<html>
    <head>
        <meta charset="UTF-8">
        <title>
            京东-欢迎登录
        </title>
        <!--rel:icon(设置图标)
            type:文件类型 image/x-icon(图片类型,png,ico,x-icon)
        -->
        <link rel="icon" type="image/x-icon" href="img/icon.ico"/>
        <link rel="stylesheet" type="text/css" href="css/京东css.css"/>
    </head>
    <body>
        <!--====1.顶部====-->
        <div id="header">
            <div id="icon">
                <img src="img/logo.png"/>
                <img src="img/l-icon.png"/>
            </div>
            <div>
                <a target="_blank" href="https://surveys.jd.com/index.php?r=survey/index/sid/568245/lang/zh-Hans">登录页面,问卷调查</a>
            </div>
        </div>
        <!--====2.中间====-->
        <div id="ttt"> 
            <!--<img src="img/warning.png"/>-->
            <p style="text-align: center;">依据《网络安全法》,为保障您的账户安全和正常使用,请尽快完成手机号验证! 新版<a target="_blank" href="https://about.jd.com/privacy/">《京东隐私政策》</a>已上线,将更有利于保护您的个人隐私。</p>
        </div>
        <!--中间间-->
        <div id="content">
            <div id="content1">
                <img src="img/bg.png"/>
            </div>
            <div id="cc1">
                <div id="cc11">
                    <p style="text-align: center;">京东不会以任何理由要求您转账汇款,谨防诈骗。</p>
                </div>
                <div id="cc12">
                    <button>扫码登录</button>|
                    <button>账号登录</button>
                </div>
                <div id="info-middle">
                    <!--输入框模块-->
                    <div id="username">
                        <img src="img/pygame.png"/>
                        <input type="text" name="username" id="" value=""  placeholder="邮箱/用户名/已验证手机号"/>
                    </div>
                    <div id="password">
                        <img src="img/password_icon.png"/>
                        <input type="password" name="password" id="" value="" placeholder="密码"/>
                    </div>
                    <a href="https://safe.jd.com/findPwd/index.action">忘记密码</a>
                    <div id="cc13">
                        <button>登&nbsp;&nbsp;&nbsp;&nbsp;录</button>
                    </div>
                <div id="cc14">
                    
                </div>
                </div>
            </div>
            
        </div>
        <!--====3.底部====-->
        <div id="footer">
            <br />
            <div style="text-align: center;" id="ff1">
                <a href="https://www.jd.com/">关于我们</a>&nbsp;&nbsp;|&nbsp;&nbsp;
                <a href="http://about.jd.com/contact">联系我们</a>&nbsp;&nbsp;|&nbsp;&nbsp;
                <a href="http://zhaopin.jd.com/home;jsessionid=A2344F28B41EE1C7DFE4005961C18CEF.s1">人才招聘</a>&nbsp;&nbsp;|&nbsp;&nbsp;
                <a href="https://www.jd.com/">商家入驻</a>&nbsp;&nbsp;|&nbsp;&nbsp;
                <a href="https://www.jd.com/">广告服务</a>&nbsp;&nbsp;|&nbsp;&nbsp;
                <a href="https://app.jd.com/">手机京东</a>&nbsp;&nbsp;|&nbsp;&nbsp;
                <a href="https://club.jd.com/links.aspx">友情链接</a>&nbsp;&nbsp;|&nbsp;&nbsp;
                <a href="https://media.jd.com/">销售联盟</a>&nbsp;&nbsp;|&nbsp;&nbsp;
                <a href="https://sale.jd.com/act/n0hAvqy5CW8.html">京东社区</a>&nbsp;&nbsp;|&nbsp;&nbsp;
                <a href="https://gongyi.jd.com/">京东公益</a>&nbsp;&nbsp;|&nbsp;&nbsp;
                <a href="https://www.joybuy.com/">English&nbsp;Site</a>
            </div>
            <br />
            <div style="text-align: center;" id="ff2">
                <p>Copyright © 2004-2018  京东JD.com 版权所有</p>
            </div>
        </div>
    </body>
</html>

CSS文件

*{
    margin:0 ;
    padding:0;
    position:relative;
}
a{
    text-decoration:none ;
}


/*=====header=====*/
#header{
    width: 100%;
    height: 80px;
    background-color: white;
}
#header a{
    float: left;
    margin-left:600px ;
    margin-top: 55px;
    color: rgb(153,153,153);
    font-size:12px;
    background: url(../img/q-icon.png) no-repeat 0 center;
    padding-left: 20px;
}
#ttt{
    width: 100%;
    height: 40px;
    background-color: rgb(255,248,240);
    /*background: url(../img/warning.png) no-repeat 0 center;*/
/*  display: inline;*/
    
}


#icon{
    float: left;
    position: relative;
    margin-left:100px ;
    
}
#ttt p{
    line-height: 40px;
    font-size:12px ;
    color: rgb(153,153,153);
}
#ttt a{
     color: rgb(51,51,51);
     
}
#ttt a:hover{
    text-decoration: underline;
    color:red;
}
/*=====content=====*/
#content{
    width: 100%;
    height: 473px;
    background-color:rgb(221,46,19);
}
#content1{
    position: relative;
    float: left;
    /*margin-left: 200px;
    margin-top: 50px;*/
    /*background-color: #FF0000;*/
    width: 200px;
    height:300px;
    
}
#cc1{
    float: right;
    width: 350px;
    height: 440px;
    background-color: antiquewhite;
    margin-right: 135px;
    margin-top: 10px;
}
#cc11{
    position: relative;
    float: left;
    height: 40px;
    width: 350px;
    background-color: rgb(255,248,240); 
    line-height: 40px;
    font-size:12px ;
    
}
#cc11 p{
    color: rgb(153,153,153);
}
#cc12{
    float: left;
    width: 350px;
    height: 55px;
    background-color: #FFFFFF;
    text-align: center;
    border-bottom:1 solid rgb(153,153,153);
}
#cc12 button{
    background-color: rgba(0,0,0,0);
    font-size: 20px;
    color: rgb(180,180,180);
    width: 160px;
    height: 55px;
    border: 0;
    border-bottom: 1px solid rgb(153,153,153);
}
#cc12 button:focus{
    outline: none;
    color: red;
}
#cc13{
    float: left;
    margin-left:22px ;
    margin-top:220px ;
}
#cc13 button{
    font-size: 20px;
    color: white;
    background-color: rgb(228,57,60);
    width: 304px;
    height: 35px;
    border: 1px solid rgb(203,42,45);
}
#cc13 button:focus{
    color: darkblue;
}
#cc13 button:hover{
    background-color: #FFFF00;
}
/*=======================================================*/
#cc14{
    margin-top:288px ;
    width: 350px;
    height: 57px;
    background-color: rgb(252,252,252);
    border-top:1px solid rgb(244,244,244) ;
}


/*=============================================================*/
/*登录框的中部*/
#info-middle{
    float: left;
    height: 288px;
    width: 350px;
    background-color: white
}
/*用户名和密码输入*/
#username, #password{
    background-color: white;
    width: auto;
    height: 40px;
    
    position: absolute;
    left: 20px; 
    right: 20px;
    top: 40px;
    
    border: 1px solid rgb(180,180,180);
    
}

#password{
    top: 110px;
}
#info-middle img{
    float: left;
    height: 100%;
    border-right: 1px solid rgb(180,180,180);
}
#info-middle input{
    border: 0;
    float: left;
    
    height: 100%;
    width: 80%;
    
    padding-left: 15px;
}
/*设置成为焦点的状态的样式*/
#info-middle input:focus{
    outline: none;
}

/*忘记密码*/
#info-middle a{
    /*float: right;*/
    
    position: absolute;
    top: 180px;
    right: 20px;
    
    font-size: 12px;
    color: rgba(180, 180, 180,1);
}
#info-middle a:hover{
    color: red;
    text-decoration: underline;
}


/*=====footer=====*/
#footer{
    width: 100%;
    height: 86px;
    background-color:white;
    color: rgb(102,102,102);
    font-size: 12px;
}
#ff1 a{
    color: rgb(102,102,102);
    font-size: 12px;
}
#ff1 a:hover{
    text-decoration: underline;
    color: red;
}

其中html文件为整体的div框架,css文件为各个div的属性
效果图


image.png

其中仍有一些图标未完成,会在后续的作业中完成其相同的任务目标

©著作权归作者所有,转载或内容合作请联系作者
  • 序言:七十年代末,一起剥皮案震惊了整个滨河市,随后出现的几起案子,更是在滨河造成了极大的恐慌,老刑警刘岩,带你破解...
    沈念sama阅读 219,539评论 6 508
  • 序言:滨河连续发生了三起死亡事件,死亡现场离奇诡异,居然都是意外死亡,警方通过查阅死者的电脑和手机,发现死者居然都...
    沈念sama阅读 93,594评论 3 396
  • 文/潘晓璐 我一进店门,熙熙楼的掌柜王于贵愁眉苦脸地迎上来,“玉大人,你说我怎么就摊上这事。” “怎么了?”我有些...
    开封第一讲书人阅读 165,871评论 0 356
  • 文/不坏的土叔 我叫张陵,是天一观的道长。 经常有香客问我,道长,这世上最难降的妖魔是什么? 我笑而不...
    开封第一讲书人阅读 58,963评论 1 295
  • 正文 为了忘掉前任,我火速办了婚礼,结果婚礼上,老公的妹妹穿的比我还像新娘。我一直安慰自己,他们只是感情好,可当我...
    茶点故事阅读 67,984评论 6 393
  • 文/花漫 我一把揭开白布。 她就那样静静地躺着,像睡着了一般。 火红的嫁衣衬着肌肤如雪。 梳的纹丝不乱的头发上,一...
    开封第一讲书人阅读 51,763评论 1 307
  • 那天,我揣着相机与录音,去河边找鬼。 笑死,一个胖子当着我的面吹牛,可吹牛的内容都是我干的。 我是一名探鬼主播,决...
    沈念sama阅读 40,468评论 3 420
  • 文/苍兰香墨 我猛地睁开眼,长吁一口气:“原来是场噩梦啊……” “哼!你这毒妇竟也来了?” 一声冷哼从身侧响起,我...
    开封第一讲书人阅读 39,357评论 0 276
  • 序言:老挝万荣一对情侣失踪,失踪者是张志新(化名)和其女友刘颖,没想到半个月后,有当地人在树林里发现了一具尸体,经...
    沈念sama阅读 45,850评论 1 317
  • 正文 独居荒郊野岭守林人离奇死亡,尸身上长有42处带血的脓包…… 初始之章·张勋 以下内容为张勋视角 年9月15日...
    茶点故事阅读 38,002评论 3 338
  • 正文 我和宋清朗相恋三年,在试婚纱的时候发现自己被绿了。 大学时的朋友给我发了我未婚夫和他白月光在一起吃饭的照片。...
    茶点故事阅读 40,144评论 1 351
  • 序言:一个原本活蹦乱跳的男人离奇死亡,死状恐怖,灵堂内的尸体忽然破棺而出,到底是诈尸还是另有隐情,我是刑警宁泽,带...
    沈念sama阅读 35,823评论 5 346
  • 正文 年R本政府宣布,位于F岛的核电站,受9级特大地震影响,放射性物质发生泄漏。R本人自食恶果不足惜,却给世界环境...
    茶点故事阅读 41,483评论 3 331
  • 文/蒙蒙 一、第九天 我趴在偏房一处隐蔽的房顶上张望。 院中可真热闹,春花似锦、人声如沸。这庄子的主人今日做“春日...
    开封第一讲书人阅读 32,026评论 0 22
  • 文/苍兰香墨 我抬头看了看天上的太阳。三九已至,却和暖如春,着一层夹袄步出监牢的瞬间,已是汗流浃背。 一阵脚步声响...
    开封第一讲书人阅读 33,150评论 1 272
  • 我被黑心中介骗来泰国打工, 没想到刚下飞机就差点儿被人妖公主榨干…… 1. 我叫王不留,地道东北人。 一个月前我还...
    沈念sama阅读 48,415评论 3 373
  • 正文 我出身青楼,却偏偏与公主长得像,于是被迫代替她去往敌国和亲。 传闻我的和亲对象是个残疾皇子,可洞房花烛夜当晚...
    茶点故事阅读 45,092评论 2 355

推荐阅读更多精彩内容

  • 第一部分 HTML&CSS整理答案 1. 什么是HTML5? 答:HTML5是最新的HTML标准。 注意:讲述HT...
    kismetajun阅读 27,490评论 1 45
  • 1、通过CocoaPods安装项目名称项目信息 AFNetworking网络请求组件 FMDB本地数据库组件 SD...
    阳明先生_X自主阅读 15,982评论 3 119
  • 远在异乡的你,相思之绪早已荡漾了吧!彻夜难眠的你,辗转反侧依旧未敢拨通那11个数字吧!失意挫败的你,定然企盼着...
    竹影轩阅读 478评论 0 0
  • 一集一集的追完《琅琊榜》,一分钟都没有快进,终成继《步步惊心》后又一个执念。 怪我入戏太过执念太深难以割舍。 --...
    千山行歌阅读 1,119评论 5 23
  • 美好的人生不外乎顺从本心去生活。跟随自己的感觉,做想做的事,爱想爱的人。 我也不止一次地埋怨过老天,以前觉得老天对...
    梦幻热恋阅读 229评论 0 1