摘要:由于一些廣告是動態(tài)加載,也無能為力,所以,自己寫了一個(gè)腳本來過濾這些動態(tài)廣告。使用前使用后已過濾條垃圾廣告,本次過濾條腳本
由于一些廣告是動態(tài)加載,adplus也無能為力,所以,自己寫了一個(gè)腳本來過濾這些動態(tài)廣告。
使用前: 使用后:// ==UserScript== // @name ad-baidu // @namespace https://baidu.com/ // @version 0.1 // @description try to take over the world! // @author You // @match https://www.baidu.com/** // @grant none // ==/UserScript== var selectors = ` #content_left [style*="display:block !important;visibility:visible !important"] [tpl="right_toplist"] [class="c-gray c-feedback"] [data-click*="vLevel"] `; selectors = selectors.trim().split(" "); var count = 0; function showCount(cn){ if(cn>0){ count+=cn; var content_right = document.querySelector("#content_right"); if(content_right){ content_right.style.position = "relative"; var style = ` line-height: 42px; text-align: center; background: #0c0; color: #fff; margin-bottom:30px; `; var msgCount = document.querySelector("#msg-remove"); if(!msgCount){ content_right.insertAdjacentHTML("afterbegin",""); msgCount = document.querySelector("#msg-remove"); } msgCount.innerHTML = "已過濾:"+count+"條垃圾廣告,本次過濾:"+cn+"條"; } } } function clear() { selectors.forEach(function(selector) { var doms = document.querySelectorAll(selector); if(doms.length){ doms = Array.from(doms); showCount(doms.length); doms.forEach(function(dom) { dom.parentNode.removeChild(dom); }); } }); } setInterval(function () { clear(); },500);
腳本:https://github.com/jsoncode/c...
文章版權(quán)歸作者所有,未經(jīng)允許請勿轉(zhuǎn)載,若此文章存在違規(guī)行為,您可以聯(lián)系管理員刪除。
轉(zhuǎn)載請注明本文地址:http://systransis.cn/yun/83044.html
摘要:使用方法,新增腳本,粘貼代碼代碼如下已過濾條垃圾廣告,本次過濾條然后每次打開瀏覽器百度搜索,就不會再有提示了效果 下載地址:https://github.com/jsoncode/b...使用方法: showImg(https://segmentfault.com/img/bVx9BO?w=295&h=423); 將文件夾拖到這里面showImg(https://segmentfaul...
摘要:新站極簡插件打磨已久,終于上線訪問地址借此機(jī)會,推薦個(gè)最強(qiáng)插件,瞬間開發(fā)效率加倍用于調(diào)試應(yīng)用程序的和擴(kuò)展??梢越鉀Q擴(kuò)展無法自動更新的問題,同時(shí)可以訪問谷歌搜索,郵箱,等谷歌服務(wù)。 showImg(http://upload-images.jianshu.io/upload_images/15934130-50747924438e3c47.jpg?imageMogr2/auto-orie...
摘要:新站極簡插件打磨已久,終于上線訪問地址借此機(jī)會,推薦個(gè)最強(qiáng)插件,瞬間開發(fā)效率加倍用于調(diào)試應(yīng)用程序的和擴(kuò)展??梢越鉀Q擴(kuò)展無法自動更新的問題,同時(shí)可以訪問谷歌搜索,郵箱,等谷歌服務(wù)。 showImg(http://upload-images.jianshu.io/upload_images/15934130-50747924438e3c47.jpg?imageMogr2/auto-orie...
摘要:分享一些實(shí)用的軟件工具也可以分享自己常用的軟件給大家,這里會同步更新必備放幾個(gè)資源站點(diǎn)有能力建議購買正版不要看格式的,可以是。建議使用清除系統(tǒng)的間諜軟件,用了之后夏一跳,趕緊卸載了迅雷極速版,只用精簡版。 分享一些實(shí)用的軟件工具 PS:也可以分享自己常用的軟件給大家,這里會同步更新 kindle(必備) 放幾個(gè)azw3資源站點(diǎn):有能力建議購買正版,不要看PDF格式的,可以是mobi。我...
閱讀 3369·2021-11-22 15:22
閱讀 2894·2021-10-12 10:12
閱讀 2190·2021-08-21 14:10
閱讀 3856·2021-08-19 11:13
閱讀 2871·2019-08-30 15:43
閱讀 3256·2019-08-29 16:52
閱讀 481·2019-08-29 16:41
閱讀 1468·2019-08-29 12:53