0
5

[–] boredTech [S] 0 points 5 points (+5|-0) ago 

Updated. Now I'm grabbing from my blocked users page.

console.log("started");

$(document).ready(function(){
  $.get('https://voat.co/u/boredTech/blocked/user', function(result){
     $(result).find('td > a').each(function(){
       $("div.submission").has('a[href="/u/' + $(this).text() + '"]').hide();
       });
   });
});

console.log("done");

0
5

[–] PuttItOut 0 points 5 points (+5|-0) ago  (edited ago)

Dude!!!

Would you be willing to try this with the packages feature we are launching soon, you know, to test and things?

Go to preview.voat.co, log in (hope you have a login that you know), click on your user name, and in side bar there is a packages link. Click that to get started.

Should be able to just copy this code right in and run it.

0
5

[–] boredTech [S] 0 points 5 points (+5|-0) ago 

jQuery is definitely out of style. Won't run or let me import the package (SyntaxError: modules are not implemented yet). I'll have to play with it this afternoon to change it over to pure js.

0
4

[–] PuttItOut 0 points 4 points (+4|-0) ago 

Well, we use jquery on the UI, so if you put this in a package you can use jquery and any other js Voat has, as well as the api.

I didn't see anything in your script(s) that wouldn't work (but perhaps I missed something).

I'd be very curious to get your thoughts on the packages feature. Let me know if you decide to play and have any questions.

0
4

[–] boredTech [S] 0 points 4 points (+4|-0) ago 

This is my scripts final form.

Fuck you number commie niggers / and sorry 1488s.

// ==UserScript==
// @name        voat
// @namespace   https://voat.co
// @description spam killer
// @version     1
// @grant       none
// @include https://voat.co/*
// ==/UserScript==

console.log("started");

var spam_dom = [
  "zerohedge.com",
  "politico.com",
  "npr.org",
  "youtube",
  "youtu.be",
  "dailydot.com",
  "cnn.com",
  "kotaku.com",
  "theverge.com",
  "scientificamerican.com",
  "phys.org",
  "geek.com",
  "theguardian.com",
  "i.ibb.co",
  "imgur.com",
  "facebook.com",
  "nytimes.com",
  "reuters.com",
  "thehill.com",
  "thenation.com",
  "hooktube.com",
  "qmap.pub",
  "thegatewaypundit.com",
  "nbcnews.com",
  "whatdoesitmean.com",
  "shareblue.com",
  "weather.com",
  "washingtonpost.com",
  "washingtonexaminer.com",
  "staradvertiser.com",
  "newspunch.com",
  "westernjournal.com",
  "townhall.com",
  "newsmax.com",
  "huffingtonpost.com",
  "nyt.com",
  "breitbart.com",
  "twitter.com/EpochTimes",
  "quodverum.com",
  "redstate.com"
  
]

$(document).ready(function(){
  for each (var spam in spam_dom)
  {
    $("div.submission").has('a[href*="' + spam + '"]').animate({opacity: 0.25});
    $("div.submission").has('a[href*="' + spam + '"]').appendTo('div#container');
  }
  
  $.get('https://voat.co/u/boredTech/blocked/user', function(result){
     $(result).find('td > a').each(function(){
       $("div.submission").has('a.author[href="/u/' + $(this).text() + '"]').animate({opacity: 0.25});
       $("div.submission").has('a.author[href="/u/' + $(this).text() + '"]').appendTo('div#container');
       });
   });
  $("div.submission").has('a.author[href*="0"]').animate({opacity: 0.25});
  $("div.submission").has('a.author[href*="1"]').animate({opacity: 0.25});
  $("div.submission").has('a.author[href*="2"]').animate({opacity: 0.25});
  $("div.submission").has('a.author[href*="3"]').animate({opacity: 0.25});
  $("div.submission").has('a.author[href*="4"]').animate({opacity: 0.25});
  $("div.submission").has('a.author[href*="5"]').animate({opacity: 0.25});
  $("div.submission").has('a.author[href*="6"]').animate({opacity: 0.25});
  $("div.submission").has('a.author[href*="7"]').animate({opacity: 0.25});
  $("div.submission").has('a.author[href*="8"]').animate({opacity: 0.25});
  $("div.submission").has('a.author[href*="9"]').animate({opacity: 0.25});
  
  $("div.submission").has('a.author[href*="0"]').appendTo('div#container');
  $("div.submission").has('a.author[href*="1"]').appendTo('div#container');
  $("div.submission").has('a.author[href*="2"]').appendTo('div#container');
  $("div.submission").has('a.author[href*="3"]').appendTo('div#container');
  $("div.submission").has('a.author[href*="4"]').appendTo('div#container');
  $("div.submission").has('a.author[href*="5"]').appendTo('div#container');
  $("div.submission").has('a.author[href*="6"]').appendTo('div#container');
  $("div.submission").has('a.author[href*="7"]').appendTo('div#container');
  $("div.submission").has('a.author[href*="8"]').appendTo('div#container');
  $("div.submission").has('a.author[href*="9"]').appendTo('div#container');
});

console.log("done");

0
4

[–] Cynabuns 0 points 4 points (+4|-0) ago 

Very slick

0
4

[–] boredTech [S] 0 points 4 points (+4|-0) ago 

Thanks, it's really very unpolished. My favorite "feature" is when you go to one of the blocked links and it shoves the submission under the comments. It just looks messed up.

But, it's amazing how much cream rises to the top without having to hunt it down.

0
3

[–] UsedToBeCujoQuarrel 0 points 3 points (+3|-0) ago 

Could someone explain 'greasemonkey' to me? What language is that and how do you add it to a browser. A pointer to a tutorial would be great.

0
4

[–] boredTech [S] 0 points 4 points (+4|-0) ago  (edited ago)

Grease Monkey is an addon which allows you to run javascript on whatever web page you feel like.

It was originally developed for firefox. But, has been ported to chrome. For Palemoon there exists a fork for it in some github location.

just go to your addons and see if you can locate it.


As for the language. This is a little abnormal for javascript as I'm using jQuery (I think it has gone out of style???).

0
2

[–] UsedToBeCujoQuarrel 0 points 2 points (+2|-0) ago 

Thanks. Looks like something called 'tampermonkey' might be it. Or not

0
3

[–] boredTech [S] 0 points 3 points (+3|-0) ago 

Update 2. Fuck you domain shitters.

// ==UserScript==
// @name        voat
// @namespace   https://voat.co
// @description spam killer
// @version     1
// @grant       none
// @include https://voat.co/*
// ==/UserScript==

console.log("started");

var spam_dom = [
  "zerohedge.com",
  "politico.com",
  "npr.org",
  "youtube",
  "youtu.be",
  "dailydot.com",
  "cnn.com"
]

$(document).ready(function(){
  for each (var spam in spam_dom)
    $("div.submission").has('a[href*="' + spam + '"]').hide();
  
  $.get('https://voat.co/u/boredTech/blocked/user', function(result){
     $(result).find('td > a').each(function(){
       $("div.submission").has('a[href="/u/' + $(this).text() + '"]').hide();
       });
   });
});

console.log("done");