ios系统和某些移动端background-p_w_upload:fixed不兼容性,没有任何效果,但可以hack一下就可以了,代码如下:
ps:想在哪个标签加背景,可以在它class后:before.
?
1
2
3
4
5
6
7
8
9
10
11
|
body:before {
content
:
' '
;
position
:
fixed
;
z-index
:
-1
;
top
:
0
;
right
:
0
;
bottom
:
0
;
left
:
0
;
background
:
url
(path/to/p_w_picpath)
center
0
no-repeat
;
background-
size
: cover;
}
|
内容来自:前端录ios_iphone_移动端background-p_w_upload:fixed兼容性[失效]
转载于:https://blog.51cto.com/yanhuang/1876120