Home > Web Front-end > HTML Tutorial > 网站图片变灰的通用CSS解决方案_html/css_WEB-ITnose

网站图片变灰的通用CSS解决方案_html/css_WEB-ITnose

WBOY
Release: 2016-06-21 09:08:20
Original
1053 people have browsed it

<style>html { 	-webkit-filter: grayscale(100%); 	-moz-filter: grayscale(100%); 	-ms-filter: grayscale(100%); 	-o-filter: grayscale(100%); 	filter: grayscale(100%); 	filter: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg'><filter id='grayscale'><feColorMatrix type='matrix' values='0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0 0 0 1 0'/></filter></svg>#grayscale");	filter: progid: DXImageTransform.Microsoft.BasicImage(grayscale=1); 	filter: gray;} </style> <!--[if IE]><style> 	html, * { 		-webkit-filter: grayscale(100%); 		-moz-filter: grayscale(100%); 		-ms-filter: grayscale(100%); 		-o-filter: grayscale(100%); 		filter: grayscale(100%); 		filter: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg'><filter id='grayscale'><feColorMatrix type='matrix' values='0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0.3333 0.3333 0.3333 0 0 0 0 0 1 0'/></filter></svg>#grayscale"); 		filter: progid:DXImageTransform.Microsoft.BasicImage(grayscale=1); 		filter: gray;	} </style> <![endif]-->
Copy after login


source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template