Get the App
SLTechnology News&Howtos  ›  Internet Technology  › 

How to use CSS to gray web pages

Shulou Source: shulou.com Published: 2022-05-31 13:12:05 10月04日 Update

Most people do not understand the knowledge points of this article "how to use CSS to turn the web page gray", so the editor summarizes the following content, detailed content, clear steps, and has a certain reference value. I hope you can get something after reading this article. Let's take a look at this "how to use CSS to turn the web page gray" article.

The methods are as follows:

This piece of CSS code can change the web page to black and white, and add the code to the top of the CSS to achieve plain.

Html {filter: grayscale;-webkit-filter: grayscale;-moz-filter: grayscale;-ms-filter: grayscale;-o-filter: grayscale; filter:progid:DXImageTransform.Microsoft.BasicImage (grayscale=1);}

If you don't have a HTML tag in your page, remember to add it. You can add the following HTML5 tag, or change the html of the above CSS tag to body or something.

There are some websites where the color of the FLASH animation cannot be controlled by the CSS filter and can be inserted between the and of the FLASH code:

If some pages with Flash still display color, or if the Flash FLV player changes when the browser scrolls up and down (for example, sword net 3, swordsman world website shunt page), change Flash to JS output (in this case, SWFObject):

The above is about the content of this article on "how to use CSS to gray web pages". I believe we all have a certain understanding. I hope the content shared by the editor will be helpful to you. If you want to know more related knowledge, please pay attention to the industry information channel.

Tags: Content website web page gray code tag article knowledge article page up and down world between value swordsman animation most that is color player Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Redmi Linux NVidia MySQL Shulou Information