覆盖浏览器"查找和QUOT;特征 [英] Override browser "Find" feature

查看:92
本文介绍了覆盖浏览器"查找和QUOT;特征的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我不知道它是否可以使用JavaScript来利用浏览器的查找功能来查找页面上的文本截取或prevent用户。 (相信我,我有一个很好的理由!)我猜的答案是不,明显超出拦截命令/按Ctrl + F。

I'm wondering whether it's possible to use JavaScript to intercept or prevent the user from using the browser's "Find" feature to find text on the page. (Trust me, I have a good reason!) I'm guessing the answer is "no," beyond the obvious intercepting Cmd/Ctrl+F.

一个次优的解决办法是截获文本突出的浏览器查找期间执行。有没有办法做到这一点,在任何浏览器?

A second-best solution would be to intercept the text highlighting that the browser performs during a Find. Is there any way to do this, in any browser?

推荐答案

不是没有特定的浏览器扩展,我认为,如果在所有的帮助。这是一个过程,是完全JavaScript的上下文之外。

Not without the help of a browser-specific extension I think, if at all. This is a process that is entirely outside the JavaScript context.

这篇关于覆盖浏览器"查找和QUOT;特征的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆