codebg.png
bg.png
bg1.png
bg2.png
clear.png
l-icon.png
logo.png
password_icon.png
pwd-icons-new.png
pygame.png
q-icon.png
qq.png
right.png
warning.png
weixin.png
xx.png
index-CSS
/*==============(通用)================*/
*{
/*消除默認的margin*/
margin: 0;
/*消除默認padding*/
padding: 0;
/*讓所有標簽的子標簽都相對自己定位*/
position: relative;
}
/*===============頂部=================*/
#header{
height: 130px;
/*background-color: seagreen;*/
}
/*====頂部的頂部====*/
#header #top{
height: 80px;
background-color: white;
}
#header #top div{
width: 292px;
height: 60px;
/*相對定位-會讓標簽脫流*/
position: absolute;
left: 188px;
/*垂直居中*/
top: 50%;
margin-top: -30px;
line-height: 60px;
}
#header #top #survey{
/*布局*/
position: absolute;
right: 187px;
bottom: 10px;
/*設置字體*/
color: rgb(180, 180, 180);
font-size: 12px;
/*去掉下劃線*/
text-decoration: none;
/*添加背景圖
* background:url(圖片地址) repeat/no-repeat x y 背景顏色
* x,y: x坐標和y坐標對應的值叭爱,除了可以設置數(shù)字值以外,和可以設置center,讓背景圖在x方向和y方向居中
*/
padding-left: 23px;
background:url(../img/q-icon.png) no-repeat 0 center white;
}
#header #top #survey:hover{
color: red;
text-decoration: underline;
}
/*====頂部的底部====*/
#header #bottom{
height: 50px;
background-color: rgb(255, 246, 236);
}
#header #bottom p{
/*垂直方向居中*/
height: 50px;
line-height: 50px;
/*水平方向居中*/
text-align: center;
/*設置字體*/
color: rgb(180, 180, 180);
font-size: 12px;
}
#header #bottom p img{
/*垂直居中*/
height: 25px;
position: absolute;
top: 50%;
margin-top: -12px;
line-height: 25px;
}
#header #bottom p a{
color: rgb(30, 30, 30);
/*去掉下劃線*/
text-decoration: none;
}
#header #bottom p a:hover{
/*添加下劃線*/
text-decoration: underline;
}
/*===============中間=================*/
#content{
height: 470px;
/*<!--77,157,254-->*/
background: url(../img/bg2.png) no-repeat 15% center rgb(77, 157, 254);
}
/*====登錄界面=======*/
#content #login_page{
width: 350px;
height: 400px;
background-color: white;
/*定位*/
position: absolute;
right:200px;
top: 15px;
}
/*--提示塊--*/
#content #login_page #div1{
height: 40px;
background-color: rgb(255, 246,236);
}
#content #login_page #div1 img{
height: 16px;
position: absolute;
top: 50%;
margin-top: -8px;
line-height: 16px;
}
#content #login_page #div1 p{
/*垂直方向居中*/
height: 40px;
line-height: 40px;
/*水平方向居中*/
text-align: center;
font-size: 12px;
color: rgb(180, 180, 180);
}
/*--選中登錄方式--*/
#content #login_page #div2{
height: 60px;
/*background-color: chartreuse;*/
color: rgba(220, 220, 220, 0.6);
/*設置字體粗細:取值范圍是100-900*/
font-weight: 100;
}
#content #login_page #div2 button{
width: 48%;
height: 100%;
border: 0;
font-size: 18px;
color: rgb(60, 60, 60);
}
/*設置按鈕成為焦點的狀態(tài)*/
#content #login_page #div2 button:focus{
color: red;
/*按鈕成為焦點默認的邊框效果是outline*/
outline: 0;
}
/*--信息收集塊--*/
#content #login_page #div3{
height: 250px;
/*設置邊框*/
border-top: solid rgba(220, 220, 220, 0.6) 1px;
border-bottom: solid rgba(220, 220, 220, 0.6) 1px;
}
#content #login_page #div3 div{
width: 300px;
height: 40px;
margin-left: 25px;
margin-top: 23px;
border: solid rgb(170, 170, 170) 1px;
}
#content #login_page #div3 #username{
margin-top: 35px;
}
/*圖片*/
#content #login_page #div3 div img{
width: 40px;
height: 40px;
float: left;
border-right: solid rgb(170, 170, 170) 1px;
}
/*輸入框*/
#content #login_page #div3 div input{
height: 40px;
width: 245px;
border: 0;
float: left;
padding-left: 10px;
font-size: 14px;
}
#content #login_page #div3 div input:focus{
outline: 0;
}
/*忘記密碼*/
#content #login_page #div3 a{
position: absolute;
right: 25px;
margin-top: 20px;
color: rgb(89, 89, 89);
font-size: 12px;
text-decoration: none;
}
#content #login_page #div3 a:hover{
color: red;
text-decoration: underline;
}
/*登錄按鈕*/
#content #login_page #div3 button{
width: 300px;
margin-left: 25px;
height: 35px;
position: absolute;
bottom: 20px;
background-color: rgb(219, 34, 46);
border: none;
color: white;
font-size: 20px;
}
#content #login_page #div4{
/*垂直方向居中*/
height: 50px;
line-height: 50px;
font-size: 10px;
color: rgba(220,220,220,0.8);
}
#content #login_page #div4 #a1{
margin-left: 25px;
margin-right: 15px;
color: rgb(89,89,89);
font-size: 12px;
text-decoration: none;
padding-left: 25px;
background: url(../img/qq.png) no-repeat 0 center white;
}
#content #login_page #div4 #a2{
margin-left: 5px;
color: rgb(89,89,89);
font-size: 12px;
text-decoration: none;
padding-left: 25px;
background: url(../img/weixin.png) no-repeat 0 center white;
}
#content #login_page #div4 #a3{
position: absolute;
right: 25px;
color: rgb(165,19,23);
font-size: 12px;
text-decoration: none;
padding-left: 25px;
background: url(../img/right.png) no-repeat 0 center rgba(0,0,0,0);
}
#content #login_page #div4 #a1:hover{
color: red;
text-decoration: underline;
}
#content #login_page #div4 #a2:hover{
color: red;
text-decoration: underline;
}
#content #login_page #div4 #a3:hover{
text-decoration: underline;
}
/*===============底部=================*/
#footer{
height: 105px;
}
#footer div{
height: 50px;
/*水平居中*/
text-align: center;
/*垂直居中*/
line-height: 50px;
font-size: 12px;
color: rgb(89, 89, 89);
}
#footer div a{
margin-left: 10px;
margin-right: 10px;
color: rgb(89, 89, 89);
text-decoration: none;
}
#footer div a:hover{
color: red;
text-decoration: underline;
}
#footer p{
color: rgb(89, 89, 89);
font-size: 12px;
/*水平居中*/
text-align: center;
}
index-html
<!--index.html是網(wǎng)站首頁對應html文件-->
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<!--設置網(wǎng)頁標題-->
<title>京東-歡迎登錄</title>
<!--設置網(wǎng)頁圖標-->
<link rel="icon" type="image/ico" href="img/jd_logo.ico"/>
<!--導入樣式表-->
<link rel="stylesheet" type="text/css" href="css/index.css"/>
</head>
<body>
<!--===================頂部====================-->
<div id="header">
<!--====頂部的頂部====-->
<div id="top">
<div>
<img src="img/logo.png"/>
<img src="img/l-icon.png"/>
</div>
<a id="survey" target="_blank" >登錄頁面,調查問卷</a>
</div>
<!--====頂部的底部====-->
<div id="bottom">
<p><img src="img/warning.png"/>   依據(jù)《網(wǎng)絡安全法》虚婿,為保障您的賬戶安全和正常使用屋剑,請盡快完成手機號驗證! 新版<a target="_blank" >《京東隱私政策》</a>已上線震叮,將更有利于保護您的個人隱私。</p>
</div>
</div>
<!--===================中間=====================-->
<div id="content">
<!--登錄框-->
<div id="login_page">
<!--提示塊-->
<div id="div1">
<p><img src="img/xx.png"/>  京東不會以任何理由要求您轉賬匯款鳍鸵,謹防詐騙苇瓣。</p>
</div>
<!--按鈕塊-->
<div id="div2">
<button id="btn1">掃碼登錄</button>|
<button id="btn2">賬號登錄</button>
</div>
<!--信息收集塊-->
<div id="div3">
<!--用戶名-->
<div id="username">
<img src="img/pygame.png"/>
<input type="text" name="uersname" placeholder="郵箱/用戶名/已驗證手機" />
</div>
<!--密碼-->
<div id="password">
<img src="img/password_icon.png"/>
<input type="password" name="password" placeholder="密碼" />
</div>
<!--忘記密碼-->
<a >忘記密碼</a>
<!--登錄-->
<button>登 錄</button>
</div>
<!--注冊和第三方登錄-->
<div id="div4">
<a id="a1" class="aa" href="">QQ</a>|
<a id="a2" class="aa" href="">微信</a>
<a id="a3" href="">立即注冊</a>
</div>
</div>
</div>
<!--===================底部=====================-->
<div id="footer">
<div>
<a href="">關于我們</a>|
<a href="">聯(lián)系我們</a>|
<a href="">人才招聘</a>|
<a href="">商家入駐</a>|
<a href="">廣告服務</a>|
<a href="">手機京東</a>|
<a href="">友情鏈接</a>|
<a href="">銷售聯(lián)盟</a>|
<a href="">京東社區(qū)</a>|
<a href="">京東公益</a>|
<a href="">English Site</a>
</div>
<p>Copyright ? 2004-2018 京東JD.com 版權所有</p>
</div>
</body>
</html>
QQ圖片20181101214107.jpg