day07

2018.07.17

1.表單

表單.PNG

2.input和button區(qū)別

input和button區(qū)別.PNG

3.搜索框

搜索框.PNG

input和button區(qū)別

4.margin中的小問題

margin中的小問題.PNG
margin問題.PNG

5.

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <style>
      *{margin:0px;padding: 0px;}
      body{
          font-family: Helvetica;
          color:#999;
      }
      .head{
          width:300px;
          height:60px;
          margin-top:10px;
          margin-left:60px;
          position: relative;
      }
      .head-img{
          position:absolute;
          top:5px;
          width:50px;
          height:50px;
          background: #f56600;
      }
      .head-right{
        position:absolute;
        color:#333;
        left:60px;/*向右向下移動 使文字與圖片隔一段距離*/
        top:3px;
      }
      .head-right p{
          font-size:15px;/*讓每個人都能享受科技的樂趣 的字體大小*/
      }
      .beijing{
          background-image: url("images6/banner.png");
          position:relative;
          width:100%;
          height:589px;
          margin-top:25px;
          background-position: -250px 0;/*讓圖片左移 使圖片中的
          人物從右往中間移動留下放登陸界面的位置*/
      }
      .container{
          width:400px;
          height:525px;
          margin-left: auto;
          margin-right: auto;
          text-align:center;
          background: #fff;
          box-shadow: 0 0 15px 3px rgba(51, 51, 51, 0.53);
          overflow: hidden;
          position: absolute;
          top:32px;
          right:60px;
      }
      .header{
          font-size:22px;
          margin-top:30px;
          margin-bottom:30px;
      }
      .header-left{
          color:#f56600;
      }
      .header-middle{
          color:#e0e0e0;
      }
      .header-right{
          color:#333;
      }
      input{
        width: 336px;
        height: 30px;
        padding: 8px;
        outline: none;
        border:1px solid #e0e0e0;
      }
      .input-up{
          margin-bottom:15px;/*給用戶名 密碼 輸入框下間距*/
      }
      .input-down{
          margin-bottom:20px;
      }
      .submit input{
          width:352px;
          height:50px;
          background: #f56600;
          color:white;
          font-size: 18px;
          margin-bottom: 20px;/*設置按鈕*/
      }
      .middle{
          font-size: 16px;
          margin-bottom: 120px;
      }
      fieldset{
          border:none;/*去掉其他登陸方式的邊框*/
      }
      .border{
          width:350px;
          border-top:1px solid #e0e0e0;
          margin-left:auto;
          margin-right:auto;
          margin-bottom:10px;/*顯示一條橫線*/
      }
      .AllIcon{
          margin-left:40px;
          margin-bottom:30px;
          overflow: hidden;/*隱藏照片不需要的多余的部分*/
          position:absolute;/*給下面的放圖片的div設置絕對定位*/
          top:470px;
      }
      .AllIcon a{
          width:20px;
          height:20px;
          display: block;/* 將擠在一行的a標簽分開*/
          float:left;/*給a設置左浮動 讓其到一行去*/
          background: #747474  url("images6/icons_type.png") no-repeat;
          border-radius: 50%;/*讓正方形變?yōu)閳A形 用來顯示圖片*/
          margin-left:50px;/*讓四個顯示f的圓形分開*/
      }
      .AllIcon .one{
          background-position: -19px 0;
      }
      .AllIcon .two{
          background-position: -38px 0;
      }
      .AllIcon .three{
          background-position: -57px 0;
      }
      .AllIcon .four{
          background-position: -85px 0;
      }
      .footer{
          margin-top:50px;
          margin-bottom:80px;
          text-align:center;
          position: relative;/*因為里面的圖片要絕對定位 所以其父元素要相對定位*/
        }
        .footer>p{
          margin-top:15px;
          font-size: 12px;
        }
        .footer img{
            width:15px;
            height:15px;
            position:absolute;
            top:50%;
            left:50%;
            margin-top:7px;
            margin-left:-39px;/*這是一個難點 需重點注意*/
        }
    </style>
</head>
<body>
    <div class="head">
          <div class="head-img">
              <img src="images6/mi-logo.png">
          </div>  
          <div class="head-right" >
                <h2>小米商城</h2>
                <p>讓每個人都能享受科技的樂趣</p>
          </div>
    </div>
    <div class="beijing">
      <div class="container">
      <form>
         <p class="header">
            <span class="header-left">賬號登陸</span>
            <span class="header-middle">|</span>
            <span class="header-right">掃碼登陸</span>
         </p> 
         <input class="input-up" type="text" placeholder="郵箱/手機號/小米賬號"><br>
         <input class="input-down" type="text" placeholder="密碼"><br>
         <p class="submit"> 
            <input type="submit" value="立即登陸">
         </p>
         <p class="middle">
           <span>注冊小米賬號</span>
           <span>|</span>
           <span>忘記密碼?</span>
         </p>
      </form>
      <div class="footer">
         <fieldset class="border">
           <legend>其他登陸方式</legend>
         </fieldset>
      </div>
      <div class="AllIcon">
          <a href="#" class="one"></a>
          <a href="#" class="two"></a>
          <a href="#" class="three"></a>
          <a href="#" class="four"></a>
      </div>
   </div>
</div>
<div class="footer">
     <p>
         <span><a>簡體</a></span>
         <span><a>|</a></span>
         <span><a>繁體</a></span>
         <span><a>|</a></span> 
         <span><a>English</a></span> 
         <span><a>|</a></span> 
         <span><a>常見問題</a></span>
     </p>
     <p>
         小米公司版權所有-京ICP備10046444-
         &nbsp; &nbsp; &nbsp;京公網(wǎng)安備11010802020134號-京ICP證110507號
     </p>
     <img src="images6/index.jpg">
</div>  
</body>
</html>

.

?著作權歸作者所有,轉載或內(nèi)容合作請聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時請結合常識與多方信息審慎甄別。
平臺聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點,簡書系信息發(fā)布平臺,僅提供信息存儲服務。

相關閱讀更多精彩內(nèi)容

  • 布局 樣式1內(nèi)聯(lián)樣式(不用) 2內(nèi)部樣式 *{} 3外部樣式<link rel="stylesheet" type...
    很普通的人閱讀 368評論 0 0
  • 今天學到了什么 1. 樣式的引入 1.1 內(nèi)聯(lián)樣式 了解就行了 不使用 1.2 外部樣式 盡量用外部樣式 2. 路...
    yt1997閱讀 191評論 0 0
  • 今天學到了什么 1. 樣式的引入 1.1 內(nèi)聯(lián)樣式 了解就行了 不使用 1.2 外部樣式 盡量用外部樣式 2. 路...
    努力進化閱讀 262評論 0 0
  • Web API Web API介紹 API的概念 API(Application Programming Inte...
    xcx時光你好閱讀 292評論 0 0
  • 一.樣式 1.1內(nèi)聯(lián)樣式和常規(guī)樣式 常規(guī)樣式的話,方便調(diào)試修改而內(nèi)聯(lián)樣式寫法不方便修改和調(diào)試 二.輸入框和表單 1...
    雪落殤晨閱讀 240評論 0 0

友情鏈接更多精彩內(nèi)容