feiszw_remove_advs

Remove divs of advertisements at https://m.feiszw.com

  1. // ==UserScript==
  2. // @name feiszw_remove_advs
  3. // @namespace http://netoday.cn
  4. // @version 0.1.31
  5. // @description Remove divs of advertisements at https://m.feiszw.com
  6. // @author crazy_pig
  7. // @match https://m.feibzw.com/chapter-*
  8. // @match https://m.a6ksw.com/*
  9. // @match https://m.zydsfgc.com/*
  10. // @match http://www.soruncg.com/*
  11. // @icon data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==
  12. // @grant none
  13. // @license MIT
  14. // @require https://code.jquery.com/jquery-2.1.4.min.js
  15. // ==/UserScript==
  16. this.$ = this.jQuery = jQuery.noConflict(true);
  17.  
  18. (function() {
  19. 'use strict';
  20.  
  21. // get url user visited
  22. var _url = (window.location + "").toLowerCase();
  23.  
  24. if (_url.indexOf("a6ksw.com") >= 0){
  25.  
  26. setInterval(function (){
  27. if (null !== $('#chaptercontent') && 'undefined' !== typeof $('#chaptercontent')){
  28. $('body').removeAttr('id');
  29. $('body').removeAttr('class');
  30. $('body').attr('style','background-color:#181C1F;color:#EAF2F7;');
  31. let navHtml = '<div style="margin-top: 10px;margin-left: 20%;font-size: 25px;height: 50px;">'+$('.Readpage')[0].innerHTML+'</div>';
  32. $('#chaptercontent').find('a').remove();
  33. $('#chaptercontent').find('script').remove();
  34. $('#chaptercontent').find('div').remove();
  35. $('#chaptercontent').find('style').remove();
  36. let html = '<div id="chaptercontent" style="padding: 20px;">'+$('#chaptercontent').html()+'</div>';
  37. $('body').children().remove();
  38. $('body').html(navHtml+html+navHtml);
  39. let links = $('#chaptercontent').find('a');
  40. for(let i =0;i<links.lengh;i++){
  41. links[i].removeAttribute('id');
  42. links[i].removeAttribute('class');
  43. }
  44. ////改变背景颜色和文字颜色
  45. $('#chaptercontent').css({"background-color":"#016974","color":"#E4DD40","font-family":"Microsoft YaHei","font-size":"20px"});
  46. }
  47. }, 300);
  48. } else if (_url.indexOf("soruncg.com") >= 0){
  49. setInterval(function (){
  50. if (null !== $('#container') && 'undefined' !== typeof $('#container')){
  51. $('body').removeAttr('id');
  52. $('body').removeAttr('class');
  53. let html = $('#container').html();
  54. $('#container').remove();
  55. $('body').children().remove();
  56. $('body').append('<div id="container" style="padding: 20px;">'+html.replaceAll('<br>  <br>  <br>  <br>','<br><br>')+'</div>');
  57. $('.layout-tit').remove();
  58. $('.appguide-wrap').remove();
  59. $('.posterror').remove();
  60. //
  61. $('body').attr('style','background-color:#016974;color:#E4DD40;');
  62. $('#container').attr('style','background-color:#016974;color:#E4DD40;');
  63. }
  64. }, 300);
  65. } else if (_url.indexOf("zydsfgc.com") >= 0){
  66. setInterval(function (){
  67. $('ins').hide();
  68. //$('#readbg').attr('style','background-color:#016974;color:#E4DD40;font-family:Microsoft YaHei;font-size:20px;');
  69. $('.ls').attr('style','background:#016974;background-color:#016974;color:#E4DD40;font-family:Microsoft YaHei;font-size:20px;');
  70. $('.mlfy_main').attr('style','background:#016974;background-color:#016974;color:#E4DD40;font-family:Microsoft YaHei;font-size:20px;');
  71. $('.mlfy_page').attr('style','background:#016974;background-color:#016974;color:#E4DD40;font-family:Microsoft YaHei;font-size:20px;');
  72. $('.toolbar span a').attr('style','color:#E4DD40;');
  73. $('.mlfy_page a').attr('style','color:#E4DD40;');
  74. }, 300);
  75. }else{
  76. // edit last theme to green
  77. _change_style();
  78.  
  79. setInterval(function (){
  80. _recursion_set_style(document.body.children);
  81. }, 300);
  82. }
  83. })();
  84.  
  85. function _change_style(){
  86. document.body.style = "font-family: \"Microsoft YaHei\"; background-color: #016974; padding-bottom: 130px;";
  87. $("#crumb").remove();
  88. $("#header").css({"background-color":"#181C1F","color":"#EAF2F7"});
  89. $("#tools").css({"background-color":"#181C1F","color":"#EAF2F7"});
  90. $("#maintool").css({"background-color":"#181C1F","color":"#EAF2F7"});
  91. $("#moretool").css({"background-color":"#181C1F","color":"#EAF2F7"});
  92. $("#nr1").css("color","#E4DD40");
  93. $("#nr_title").css("color","#FFFFFF");
  94. $("#nr_botton").remove();
  95. }
  96.  
  97. /**
  98. * set font \ background-color \ font-family
  99. */
  100. function _recursion_set_style(childrenNodes){
  101. if (typeof(childrenNodes) !== 'undefined'){
  102. var i;
  103. // set visibility hidden
  104. var startFlag = false;
  105. for (i =0; i < childrenNodes.length ; i++){
  106. if (startFlag &&
  107. 'SCRIPT' !== childrenNodes[i].tagName.trim().toUpperCase() &&
  108. 'SPAN' !== childrenNodes[i].tagName.trim().toUpperCase()){
  109. childrenNodes[i].style.visibility = "hidden";
  110. }
  111. if ('SCRIPT' === childrenNodes[i].tagName.trim().toUpperCase() &&
  112. childrenNodes[i].getAttribute("src") === "/js/show.min.js"){
  113. childrenNodes[i].removeAttribute("src");
  114. }
  115. if('AUDIO' === childrenNodes[i].tagName.trim().toUpperCase()){
  116. startFlag = true;
  117. }
  118. if(childrenNodes[i].innerText.indexOf("中文域名一键直达") >= 0){
  119. childrenNodes[i].innerHTML = "<a href=\"https://m.feiszw.com/\" style=\"font-weight:bold; color: #fff;text-align:center;margin-bottom:24px;font-size:.8rem\">飞速中文网移动版首页</a>";
  120. }
  121. }
  122. }
  123. }

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址