ScriptKitty

CookieBan Script

Apr 9th, 2014
35
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // ==UserScript==
  2. // @name        BanCookieBan
  3. // @description fuck cookie bans.
  4. // @namespace   im.a.gay.cat
  5. // @include     *4chan.org/*
  6. // @author team !kittensORw
  7. // @contributor !LunanonXE2
  8. // @contributor nokosage
  9. // @version     0.3
  10. // ==/UserScript==
  11.  
  12. function bcb(){
  13.     function a($Name,$Value,$EndH){
  14.             var exdate=new Date();
  15.             $EndH=exdate.getHours()+$EndH;
  16.             exdate.setHours($EndH);
  17.             document.cookie=$Name+ "=" +escape($Value)+(($EndH==null) ? "" : ";expires="+exdate.toGMTString()+"; path=/;domain=.4chan.org");
  18.     }
  19.     function clearC(){
  20.         var cookiekiller = setInterval(function(){
  21.             a('4chan_pass','_nope',1);
  22.         },300);
  23.         setTimeout(function(){clearInterval(cookiekiller);},5000);
  24.     }
  25.     clearC();
  26.    
  27.     var isChromium = window.chrome;
  28.     if(isChromium) {
  29.        document.addEventListener('QRPostSuccessful_', clearC, false);
  30.     } else {
  31.        document.addEventListener('QRPostSuccessful', clearC, false);
  32.     }
  33.    
  34.     document.addEventListener("ThreadUpdate", clearC, false);  
  35. }
  36. bcb();
Advertisement
Add Comment
Please, Sign In to add comment