search
HomeBackend DevelopmentPHP TutorialWeb page grayscale effect compatible with firefox and chrome_PHP tutorial
Web page grayscale effect compatible with firefox and chrome_PHP tutorialJul 21, 2016 pm 03:25 PM
chromefirefoxcompatibleMethodaccomplishEffectmostGrayscaleofWeb pagewant

But from a technical point of view, the safest way to achieve web page grayscale is to directly process all images, without considering compatibility or efficiency. However, the workload is relatively large and switching back is also laborious.

ie series supports css filters. One sentence filter:gray; solves all problems. However, as we all know, ie is famous for its low efficiency, and you will find that the speed drops significantly after it is turned on. And, most fatally, it doesn't work in other browsers.

Is there a way to be compatible with all browsers? have. JavaScript can do it. Someone has long used js to simulate the gray filter of IE. If you are interested and willing to read English, you can check out "GRAYSCALING" IN NON-IE BROWSERS. If you don't want to read it, I can tell you directly how to use it.

1. Download grayscale.js file

2. Reference this js file in your header



3. To achieve site-wide grayscale, call

grayscale(document.body); in the onload event;

I have a lot of theme background pictures, which is difficult to process, and some pictures may disappear. . .

I will enable this effect for three days. Please forgive me if the theme display is abnormal due to processing problems and affects everyone's browsing experience. Anyway, those who come here are all acquaintances, and only a few of you can be influenced. . .

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/324198.htmlTechArticleOnly from a technical point of view, the safest way to achieve web page grayscale is to directly process all images without Consider compatibility, not efficiency. However, the workload is relatively large, switching...
Statement
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
crdownload是什么文件crdownload是什么文件Mar 08, 2023 am 11:38 AM

crdownload是chrome浏览器下载缓存文件,就是没下载完的文件;crdownload文件是一种临时文件格式,用于储存从硬盘上下载的文件,它能够帮助用户在下载文件时保护文件完整性,避免受到意外中断或停止的情况。CRDownload文件也可以用于备份文件,它可以让用户保存文件的临时副本;如果在下载时出现意外错误,就可以使用CRDownload文件来恢复已下载的文件。

chrome无法加载插件怎么办chrome无法加载插件怎么办Nov 06, 2023 pm 02:22 PM

chrome无法加载插件可以通过检查插件是否已正确安装、禁用和启用插件、清除插件缓存、更新浏览器和插件、检查网络连接和尝试在隐身模式下加载插件方法解决。其解决方法如下:1、检查插件是否已正确安装,重新安装即可;2、禁用和启用插件,点击禁用按钮,然后再次点击启用按钮即可;3、清除插件缓存,选择高级选项>清除浏览数据,勾选缓存图片和文件和清除所有Cookies,点击清除数据即可。

解决谷歌浏览器无法打开网页的方法解决谷歌浏览器无法打开网页的方法Jan 04, 2024 pm 10:18 PM

谷歌浏览器网页打不开怎么办?有很多小伙伴都喜欢上使用谷歌浏览器,当然也有部分小伙伴在使用的过程中发现自己无法正常的打开网页或者说网页打开的速度很慢,那么遇到这种情况要怎么办呢?下面就和小编来看看谷歌浏览器网页打不开的解决方法吧。谷歌浏览器网页打不开的解决方法方法一为了帮助还没有过关的玩家们,让我们一起来了解一下具体的解谜方法吧。首先,右键点击右下角的网络图标,然后选择“网络和Internet设置”。2、点击"以太网",接着点击"更改适配器选项"。3、点击”属性“按钮。4、双击打开i

Ubuntu Linux中如何删除Firefox Snap?Ubuntu Linux中如何删除Firefox Snap?Feb 21, 2024 pm 07:00 PM

要在UbuntuLinux中删除FirefoxSnap,可以按照以下步骤进行操作:打开终端并以管理员身份登录到Ubuntu系统。运行以下命令以卸载FirefoxSnap:sudosnapremovefirefox系统将提示你输入管理员密码。输入密码并按下Enter键以确认。等待命令执行完成。一旦完成,FirefoxSnap将被完全删除。请注意,这将删除通过Snap包管理器安装的Firefox版本。如果你通过其他方式(如APT包管理器)安装了另一个版本的Firefox,则不会受到影响。通过以上步骤

chrome是什么意思chrome是什么意思Aug 07, 2023 pm 01:18 PM

chrome是浏览器的意思,由Google开发的网络浏览器,它在2008年首次发布,并迅速成为全球最受欢迎的浏览器之一,其名字来源于浏览器的界面设计,因为它的标志性特征就是窗口顶部的标签栏,而这个标签栏的外观与铬金属非常相似。

Win10的最稳定版本Win10的最稳定版本Dec 25, 2023 pm 07:58 PM

很多用户都会遇到在操作电脑的时候卡顿或者是蓝屏,这个时候我们就需要找一个最为稳定的win10版本来进行操作,整体都是非常的好用的,可以让你日常使用更为流畅。史上最稳定的win10版本1、win10正版原装系统在这里用户可以使用简单的操作,系统经过优化,具有很强的稳定性、安全性、兼容性,用户可以按照步骤实现完美机器2、俄罗斯大神精简版win10经过严格的精简操作,删除了很多不必要的功能和服务。精简后,系统的CPU和内存占用率更低,运行速度更快。3、win10精简版1909安装多台不同硬件型号的电脑

chromesetup是什么软件chromesetup是什么软件Mar 03, 2023 pm 02:58 PM

chromesetup是谷歌浏览器安装程序;谷歌浏览器即Google Chrome,是由Google开发的一款设计简单、高效的Web浏览工具,其特点是简洁、快速,Chrome支持多标签浏览,每个标签页面都在独立的“沙箱”内运行,在提高安全性的同时,一个标签页面的崩溃也不会导致其他标签页面被关闭。

mozilla firefox可以卸载吗mozilla firefox可以卸载吗Mar 15, 2023 pm 04:40 PM

mozilla firefox可以卸载;firefox属于第三方浏览器,如果不需要,完全可以卸载。卸载方法:1、在开始菜单中,依次点击“Windwos系统”-“控制面板”;2、在“控制面板”界面中,点击“程序和功能”;3、在新界面中,找到并双击火狐浏览器图标;4、在卸载弹窗中,点击“下一步”;5、点击“卸载”即可。

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Tools

SAP NetWeaver Server Adapter for Eclipse

SAP NetWeaver Server Adapter for Eclipse

Integrate Eclipse with SAP NetWeaver application server.

SublimeText3 Linux new version

SublimeText3 Linux new version

SublimeText3 Linux latest version

MinGW - Minimalist GNU for Windows

MinGW - Minimalist GNU for Windows

This project is in the process of being migrated to osdn.net/projects/mingw, you can continue to follow us there. MinGW: A native Windows port of the GNU Compiler Collection (GCC), freely distributable import libraries and header files for building native Windows applications; includes extensions to the MSVC runtime to support C99 functionality. All MinGW software can run on 64-bit Windows platforms.

WebStorm Mac version

WebStorm Mac version

Useful JavaScript development tools

VSCode Windows 64-bit Download

VSCode Windows 64-bit Download

A free and powerful IDE editor launched by Microsoft