Last active
September 27, 2018 12:44
-
-
Save KrisYu/ab90d07612b31b6665ba2cba1fde286b to your computer and use it in GitHub Desktop.
θ±η£εΉΏζπ’ε±θ½ει»ηθζ¬γ
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name forgetyou | |
// @namespace forgetyou | |
// @include https://www.douban.com/* | |
// @version 1.1 | |
// @grant none | |
// @require http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js | |
// ==/UserScript== | |
var banNames = ['someone1', 'someone2']; | |
function toggle_visibility(className) { | |
$('.' + className).each(function( index ) { | |
var e = $( this ); | |
var name; | |
var href = e.find('.usr-pic a').attr('href'); | |
if (href){ | |
if (href.indexOf('people/') != -1) { | |
name = href.split('people/')[1].split('/')[0]; | |
if ($.inArray(name, banNames) !== -1) { | |
e.remove(); | |
} | |
} | |
} | |
}); | |
} | |
toggle_visibility('status-item'); | |
// ζ₯θͺθ±η£er |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment