Skip to content

Instantly share code, notes, and snippets.

View ccloli's full-sized avatar
💩
Shitty shit shitting shits shittily

864907600cc ccloli

💩
Shitty shit shitting shits shittily
View GitHub Profile
// From CC Code
if(document.getElementsByClassName('d_post_content')[0]){
var d=/#(CC_Cipher|youtube|utb|acfun|bilibili|tucao|catfun|soundcloud|xiami|moefm)#/,
t1=new Date().getTime(),
list=[],
xpath = document.evaluate(
'//cc//text()', //XPath表达式:选择所有文本元素(text node)
document,//document.body, //筛选环境
null, //指定命名空间,不用管它
XPathResult.ORDERED_NODE_ITERATOR_TYPE, //被匹配的元素按出现顺序排列
@ccloli
ccloli / Baidu Zhidao Thread Notification
Last active August 29, 2015 14:04
Baidu Zhidao Thread Notification
// ==UserScript==
// @name Baidu Zhidao Thread Notification
// @version 1.1
// @description 在贴吧对来自百度知道的贴子进行提醒。
// @match http://tieba.baidu.com/p/*
// @match http://tieba.baidu.com/f?*z=*
// @include http://tieba.baidu.com/p/*
// @include http://tieba.baidu.com/f?*z=*
// @author 864907600cc
// @grant none
@ccloli
ccloli / Tieba Block
Last active August 29, 2015 14:04
Tieba Block
// ==UserScript==
// @name Tieba Block
// @version 0.2
// @description Tieba Block
// @match http://tieba.baidu.com/*
// @include http://tieba.baidu.com/*
// @author 864907600cc
// @icon http://1.gravatar.com/avatar/147834caf9ccb0a66b2505c753747867
// @run-at document-start
// @grant GM_registerMenuCommand
@ccloli
ccloli / 115-online-player.user.js
Last active May 3, 2024 06:37
115 Online Player
// ==UserScript==
// @name 115 Online Player
// @version 1.1.1
// @description Play videos from 115 online
// @match http://*.115.com/*
// @match http://*.115.com/*
// @author 8qwe24657913 | 864907600cc
// @run-at document-end
// @grant none
// @updateURL http://ext.ccloli.com/temporary/115-online-player.user.js
@ccloli
ccloli / BaiduMsgBackup.js
Last active January 31, 2023 23:19
BaiduMsgBackup
// BaiduMsgBackup by ccloli
// Tieba@864907600cc
// GitHub@ccloli
// License: GPLv3
(function(){
// This script using JSZip & FileSaver.js
// ==========---------- JSZip Begin ----------========== //
/*!
@ccloli
ccloli / tiebaAllSign.user.js
Last active January 9, 2016 06:51
tiebaAllsign NO BDUSS 版本
// ==UserScript==
// @name tiebaAllsign
// @description 贴吧集中签到
// @include http://www.baidu.com/
// @include https://www.baidu.com/
// @include http://www.baidu.com/?vit=1
// @include http://www.baidu.com/index.php?tn=baiduhome_pg
// @include http://tieba.baidu.com/f?kw=*
// @include http://tieba.baidu.com/f?ie=gbk&kw=*
// @include http://tieba.baidu.com/f?ie=utf-8&kw=*
@ccloli
ccloli / calculateMark.js
Last active August 29, 2015 14:26
tieba#3938066599 统计脚本
(function(){
var user = /*sessionStorage.getItem('himg-user') ? JSON.parse(sessionStorage.getItem('himg-user')).data : */[];
var frame = document.createElement('div');
var elem = document.getElementsByClassName('l_post');
var xhr = new XMLHttpRequest();
var page = (PageData && PageData.pager && PageData.pager.cur_page) || 1;
var totalPage = (PageData && PageData.pager && PageData.pager.total_page) || 1;
xhr.onload = function(){
frame.innerHTML = xhr.responseText;
totalPage = xhr.responseText.split('"total_page":')[1].split('}')[0].split(',')[0] - 0;
@ccloli
ccloli / Chrorme Ba Banner.user.js
Last active August 29, 2015 14:26
Chrorme Ba Banner
// ==UserScript==
// @name Chrorme Ba Banner
// @version 1.1
// @description chrome://kill
// @author 864907600cc
// @icon https://secure.gravatar.com/avatar/147834caf9ccb0a66b2505c753747867
// @match http://tieba.baidu.com/chrome
// @match http://tieba.baidu.com/chrome?*
// @match http://tieba.baidu.com/f*w=chrome
// @match http://tieba.baidu.com/f*w=chrome&*
@ccloli
ccloli / hook_xhr.js
Last active May 27, 2020 03:33
Hook XHR to hack NE
var originalXMLHttpRequest = XMLHttpRequest;
var fakeXMLHttpRequest = function(){
var __this__ = this;
var _this = new originalXMLHttpRequest();
var _this_proto = _this.constructor.prototype;
Object.keys(originalXMLHttpRequest).forEach(function(elem){
if (typeof originalXMLHttpRequest[elem] === 'function') {
__this__[elem] = function(){
_this[elem].apply(_this, arguments);
@ccloli
ccloli / GM_download_polyfill.js
Last active February 21, 2021 14:26
GM_download polyfill, a polyfill to make your userscript supports GM_download
/*
* GM_download polyfill
*
* @description A polyfill to make your userscript supports GM_download
* @author ccloli
* @version 1.0
*/
// to use this polyfill, you must add "@grant GM_xmlhttpRequest" at userscript metadata block