🏠 Home 

讨论 » 创建请求

Script for finding text in same page on select

§
发表于:2016-07-06
编辑于:2016-07-06

Script for finding text in same page on select

Hello,

Can anyone help me or, better, create a script for me?

What I need:

On selecting a text in a page, it will look for the exact or closest r###lt on the same webpage, and highlighting that r###lt in a blue color. The script need to be running at all times. If it is possible, can an activate and deactivate option be added? Can you also annotate all the codes so that I can understand what they do?




Thank you, whoever you may be, for looking into it.

§
发表于:2016-07-07

I don't think I will write this script, but some code examples might help you or whoever is interested in taking it on:

(1) Detect a user selection (e.g., onmouseup) -- I don't have any scripts that monitor this mouse event but there probably are many examples on the web

(2) Read a selection in the page

https://greasyfork.org/en/scripts/15254-exclude-term-on-google-firefox-only

(3) Find and highlight all matching text in a page

https://greasyfork.org/en/scripts/3719-text-highlighter-dynamic (simpler)
https://greasyfork.org/en/scripts/13007-text-highlight-and-seek

发表回复

登录以发表回复。