您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Remove tracking elements from links
当前为
This is just a very primitive remover of some tracking elements. Currently it recognizes and removes URL variables starting with utm_
(so-called Urchin Tracking Module parameters), wt_
(Webtrekk), WT.
(Webtrends) and referrer
. If you wish, you can extend that in the declaration of the badp
variable (an array). If you encounter problems on some sites (which e.g. rely on a referrer
parameter), either remove it from the array – or deactivate the script for that site (with Greasemonkey, you can configure "user exceptions").
Note: JavaScript's URLSearchParams()
expects parameters to be separated by ampersands ("&"). Some sites use semi-colons (";") instead, in which case URLSearchParams()
messes up the query-string (replacing several characters by their URL-encoded variant) so it no longer works. To avoid that, this scripts beforehand replaces all semi-colons by ampersands, which works in most cases I've encountered – but might rise issues if a parameter is supposed to contain an semi-colon (thought that should be URL-encoded then, it's sometimes forgotten), or some site uses "&" to separate parameters. In those cases, it's best to put that site into your "user excludes". Alternatively, you can also turn off the ";" › "&" conversion inside the script by setting var replace_semicolon = false;