Skip to content

Instantly share code, notes, and snippets.

@pupboss
Last active December 29, 2016 12:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pupboss/747e038280a175bd615a9259000e3afa to your computer and use it in GitHub Desktop.
Save pupboss/747e038280a175bd615a9259000e3afa to your computer and use it in GitHub Desktop.
一键删除知乎关注话题
var jq = document.createElement('script');
jq.src = "https://res.wx.qq.com/open/libs/jquery/2.1.4/jquery.js";
document.getElementsByTagName('head')[0].appendChild(jq);
$("a.TopicLink.PortraitItem-image").each(function(){
var num = this.href.replace('https://www.zhihu.com/topic/', '');
var remoteUrl = 'https://www.zhihu.com/api/v4/topics/' + num + '/followers';
$.ajax({
url: remoteUrl,
type: 'DELETE',
data: {}
});
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment