xsg1

1.背景图片插入

代码格式:background-image:url(); 括号内填写图片路径

2.背景图片设置大小

代码格式:background-size:宽、高

3.背景图片设置不平铺

代码格式:background-repeat:no-repeat

由于背景图片插入后默认设置平铺效果,所以需使用该属性调整

4.背景图片定位

代码格式:background-position:方向(top/right/bottom/left)

5.背景图片固定

代码格式:background-attchment:fixed

 

分类:

技术点:

相关文章:

  • 2022-12-23
  • 2021-09-26
  • 2022-02-24
  • 2021-12-06
  • 2021-12-16
  • 2021-10-14
  • 2022-12-23
猜你喜欢
  • 2021-11-02
  • 2022-02-07
  • 2022-02-07
  • 2021-11-24
  • 2021-10-14
  • 2021-06-26
相关资源
相似解决方案