Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // ==UserScript==
- // @name Remove pictures in the chat of the cytu.be channel /r/the_tv_lounge
- // @namespace CyTube
- // @include *
- // @author Erik Vergobbi Vold, Tyler G. Hicks-Wright, PackageFiend
- // @description Removes .pic in cytu.be/r/the_tv_lounge using jQuery
- // ==/UserScript==
- // a function that loads jQuery and calls a callback function when jQuery has finished loading
- function addJQuery(callback) {
- var script = document.createElement("script");
- script.setAttribute("src", "//ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js");
- script.addEventListener('load', function() {
- var script = document.createElement("script");
- script.textContent = "window.jQ=jQuery.noConflict(true);(" + callback.toString() + ")();";
- document.body.appendChild(script);
- }, false);
- document.body.appendChild(script);
- }
- // the guts of this userscript
- function main() {
- // Note, jQ replaces $ to avoid conflicts.
- function () {
- var pic = jQ('img#picture:not(.hidden)');
- pic.src='#';
- pic.addClass('hidden');
- }
- setInterval(,1000)
- }
- // load jQuery and execute the main function
- addJQuery(main);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement