Fuck CSDN

Fuck CSDN!

目前为 2018-12-05 提交的版本。查看 最新版本

  1. // ==UserScript==
  2. // @name Fuck CSDN
  3. // @version 0.7
  4. // @description Fuck CSDN!
  5. // @author 流星暴雨
  6. // @grant none
  7. // @match http*://blog.csdn.net/*
  8. // @match http*://bbs.csdn.net/*
  9. // @run-at document-body
  10. // @homepageURL https://greasyfork.org/scripts/374950
  11. // @supportURL https://greasyfork.org/scripts/374950
  12. // @namespace Eternal
  13. // ==/UserScript==
  14.  
  15. (function() {
  16. 'use strict';
  17. if(location.host.match("blog")){
  18. $(function() {
  19. $("#article_content").css("height",'');
  20. $(".hide-article-box").remove();
  21. $(".fourth_column").remove();
  22. $(".pulllog-box").remove();
  23. $(".box-shadow").remove();
  24. $(".aside-box > div[data-track-click]").parent().remove();
  25. $(".BAIDU_DUP_fp_wrapper").remove();
  26. $(".adsbygoogle").parent().remove();
  27. $("#commentBox").prev().remove();
  28. $(".recommend-ad-box").remove();
  29. $("#adContent").remove();
  30. });
  31. var timer1=setInterval(function (){
  32. if($(".right-item[id]").size()>0){
  33. clearInterval(timer1);
  34. setTimeout(function (){
  35. $(".right-item[id]").remove();
  36. },50)
  37. }
  38. },10);
  39. window.setInterval_=setInterval;
  40. document.body.insertBefore_=document.body.insertBefore;
  41. var timer;
  42. var mysetInterval=function (fun,time){
  43. //console.log(fun+'');
  44. if((fun+'').match("check-adblock-time")){
  45. //$(".adblock").remove();
  46. //"function" == typeof window.csdn.insertcallbackBlock && window.csdn.insertcallbackBlock();
  47. /*timer=setInterval_(function (){
  48. if($(".check-adblock-bg").size()>0){
  49. clearInterval(timer);
  50. $(".check-adblock-bg").parent().remove();
  51. }
  52. },10);*/
  53. return null;
  54. }else{
  55. return setInterval_(fun,time);
  56. }
  57. }
  58. var myinsertBefore=function (ele,box){
  59. //console.log(ele.innerHTML);
  60. if(ele.innerHTML.match("ADP")||ele.innerHTML.match("广告")){
  61. return document.body;
  62. }else{
  63. return document.body.insertBefore_(ele,box);
  64. }
  65. };
  66. document.body.insertBefore=myinsertBefore;
  67. setInterval=mysetInterval;}else if(location.host.match("bbs")){
  68. $(function() {
  69.  
  70. $(".post_body > div[scrolling=no]").remove();
  71. $(".bbs_feed_ad_box").remove();
  72. var timer2=setInterval(function (){
  73. if($(".hide_topic_box").size()>0){
  74. clearInterval(timer2);
  75. $("#bbs_detail_wrap").css("max-height",'');
  76. $(".hide_topic_box").remove();
  77. $(".post_body > div").remove();
  78. $(".pulllog-box").remove();
  79. $("#adContent").remove();
  80. }
  81. },10);
  82. });
  83. }
  84.  
  85. console.log("Fuck CSDN!")
  86. })();