9酷

9酷歌曲广告剔除

  1. // ==UserScript==
  2. // @name 9酷
  3. // @namespace http://tampermonkey.net/
  4. // @version 0.2
  5. // @description 9酷歌曲广告剔除
  6. // @author gwbc
  7. // @match https://www.9ku.com/*
  8. // @icon https://scpic.chinaz.net/Files/pic/icons128/8169/e12.png
  9. // @grant none
  10. // ==/UserScript==
  11.  
  12. (function() {
  13. 'use strict';
  14. // Your code here...
  15. try{
  16. let youFix = document.querySelector('div.youFix');
  17. if(youFix != null)
  18. {
  19. youFix.remove();
  20. }
  21.  
  22. let iframes = document.querySelectorAll('iframe');
  23. for (let i = 0; i < iframes.length; ++i) {
  24. iframes[i].remove();
  25. }
  26.  
  27. let box = document.querySelector('.box');
  28. if(box != null)
  29. {
  30. let boxWidth = document.querySelector('.box').getBoundingClientRect().width;
  31. let boxHeight = document.querySelector('.nplayL-box').getBoundingClientRect().height
  32. document.querySelector('.pFl.clearfix').style.width = boxWidth + "px";
  33. document.querySelector('.nplayL-box').style.width = boxWidth / 2 + "px";
  34. document.querySelector('.ppR').style.width = boxWidth / 2 + "px";
  35. document.querySelector('.playingTit').style.width = boxWidth / 2 - 22 + "px";
  36. document.querySelector('.oldPlayer').style.margin = 0;
  37. document.querySelector('.lrcBox').style.width = boxWidth / 2 - 2 + "px";
  38. document.querySelector('.lrcBox').style.height = boxHeight - 111 + "px";
  39. document.querySelector('.oldPlayer').style.width = boxWidth / 2 - 22 + "px";
  40. document.querySelector('.ncol-btns').remove();
  41. document.querySelector('.dongBox.mb10').remove();
  42. document.querySelector('#p_top').remove();
  43. document.querySelector('.fotter').remove();
  44. document.querySelector('.ppBox').style.height = boxHeight - 2 + "px";
  45. document.querySelector('.ppBox').style.borderBottom = "1px solid #259b24";
  46. document.querySelector('.jp-progress').style.width = boxWidth / 2 - 20 + "px";
  47. document.querySelector('#lyric').style.height = boxHeight - 100 + "px";
  48. }
  49.  
  50. }catch(e){
  51. //TODO handle the exception
  52. }
  53.  
  54. var count = 0
  55. var t = setInterval(function() {
  56. count++;
  57. if (count > 2000) {
  58. clearInterval(t);
  59. }
  60.  
  61. try {
  62. let iframes = document.querySelectorAll('iframe');
  63. for (let i = 0; i < iframes.length; ++i) {
  64. iframes[i].remove();
  65. }
  66.  
  67. let sprris = document.querySelectorAll('#songlist li');
  68. for (let i = 0; i < sprris.length; ++i) {
  69. if (sprris[i].id.length != 0) {
  70. sprris[i].remove();
  71. }
  72. }
  73.  
  74. if(sprris.length != 0)
  75. {
  76. document.querySelector('.box.bgWrite.mb10.clearfix').remove();
  77. document.querySelector('.xxl.clearfix').remove();
  78. document.querySelector('.box.bgWrite.mb10').remove();
  79. document.querySelector('#fankui').remove();
  80. document.querySelector('#weixin').remove();
  81. document.querySelector('#gotop').remove();
  82. }
  83.  
  84. let ls = document.querySelectorAll('.musicList li[style*="position:relative"]');
  85. for (let i = 0; i < ls.length; ++i)
  86. {
  87. ls[i].remove();
  88. }
  89.  
  90. } catch (e) {
  91.  
  92. }
  93. }, 1);
  94. })();

QingJ © 2025

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