zoukankan      html  css  js  c++  java
  • CSS实现网页背景图片自适应全屏的方法

    <!DOCTYPE html>
    <html>
    <head>
        <meta http-equiv="content-type" content="text/html;charset=utf-8"/>
        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
        <title>title</title>
    </head>
    <body>
    <div class="wrapper">
        <!--背景图片-->
        <div id="web_bg" style="background-image: url(./img/bg.jpg);"></div>
        <!--其他代码 ... -->
    </div>
    </body>
    </html>
    #web_bg{
      position:fixed;
      top: 0;
      left: 0;
      width:100%;
      height:100%;
      min-width: 1000px;
      z-index:-10;
      zoom: 1;
      background-color: #fff;
      background-repeat: no-repeat;
      background-size: cover;
      -webkit-background-size: cover;
      -o-background-size: cover;
      background-position: center 0;
    }

    转自:

    https://www.jb51.net/css/599279.html

  • 相关阅读:
    Jackson
    Jackson
    SAX
    SAX
    JDK Tools
    JAXB
    linux系统mysql连接检查脚本
    linux系统ssh远程连接检查脚本
    linux系统带宽监测脚本
    linux系统web日志分析脚本
  • 原文地址:https://www.cnblogs.com/dongruiha/p/14287974.html
Copyright © 2011-2022 走看看