外链的超链接狗尾巴有没有通用的删除法?

阅读:1724回复:4
2022-10-26 17:56
写私信
楼主#
一点超链接就自动加狗尾巴,神烦了,
https://bbs7070.com/plugin.php?id=austgl_iframe:austgl_iframe&url=https://www.zaobao.com%2F




原始地址多清爽
https://www.zaobao.com
My Technical Blog: http://art-technical.blogspot.com/
2022-10-27 00:35
写私信
1楼#
如果是那种点击时才加的,写个userjs把拦截一下点击事件就行
不过这个要准确定位到需要处理的<a>元素,所以不是通用的
2022-10-27 06:40
写私信
2楼#
taoww:如果是那种点击时才加的,写个userjs把拦截一下点击事件就行
不过这个要准确定位到需要处理的<a>元素,所以不是通用的
回到原帖
点击时加的
My Technical Blog: http://art-technical.blogspot.com/
2022-10-28 19:07
写私信
3楼#
viewtheard:点击时加的回到原帖
至少你给的bbs7070.com这个论坛的帖子里的链接是一开始就是要跳转的。
不过这样处理起来还简单点,一行代码搞定
// ==UserScript==
// @name        bbs7070.com
// @namespace   bbs7070.com
// @match       https://bbs7070.com/*
// @grant       none
// @version     1.0
// ==/UserScript==
Array.prototype.forEach.call(document.querySelectorAll('a[href^="https://bbs7070.com/plugin.php?id=austgl_iframe:austgl_iframe&url="]'),(e)=&gt;{e.href=e.innerText});
2022-10-29 17:19
写私信
4楼#
taoww:至少你给的bbs7070.com这个论坛的帖子里的链接是一开始就是要跳转的。
不过这样处理起来还简单点,一行代码搞定
// ==UserScript==
// @name        bbs7070.com
// @namespa...
回到原帖
感谢指教,很棒,解决了
My Technical Blog: http://art-technical.blogspot.com/