这个新技能,我是从百度FM中学习到的。

在网页中,有一个id为"body-bg"的层,

html代码:

<div id="body-bg" style="display: block;">
  <
img src="http://mu6.bdstatic.com/static/fm/1403504178/themes/public-bg9.jpg">
</
div>

css代码:

#body-bg {
   position: fixed;
   bottom: 0;
   left: 0;
   z-index: -999;
   overflow: hidden;
   width: 100%;
   height: 100%;
   min-height: 100%;
   _position: absolute;
}

这是我从百度FM中找到在代码,你可以用上面的代码尝试一下。

工作了两年了,css没有用到这么好,有很多需要好好学习,特别需要多操作,才能真正的提高自己的技能。

相关文章:

  • 2021-06-08
  • 2021-10-17
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-05-20
  • 2021-08-07
猜你喜欢
  • 2021-06-27
  • 2022-12-23
  • 2022-01-30
  • 2021-11-22
  • 2022-12-23
  • 2022-12-23
  • 2021-10-28
相关资源
相似解决方案