Automatically count total endorsements

Day 5,323, 09:00 Published in Portugal Brazil by RojerGS

I have run two lotteries already, in which I distribute the total endorsements of the lottery article.

I don't count the total endorsements by hand, that would be crazy!
I use a simple bookmark that runs a tiny script that just counts the endorsements.

You can try it for yourself on this article.

Steps:

1. endorse the article (optional but appreciated!);
2. create a new browser bookmark;
3. copy the full line below, starting from "javascript" until ";"

javascript:va = document.getElementsByClassName("view_all"); if (va.length > 0) {va[0].click()};alert("Total endorsements: " + (document.getElementsByClassName("end_100").length * 100 + document.getElementsByClassName("end_50").length * 50 + document.getElementsByClassName("end_5").length * 5));

4. paste in the URL section of the bookmark;



5. save the bookmark;
6. click the bookmark when inside an eRepublik article.



I hope this is helpful!