Created
October 14, 2014 14:12
-
-
Save user19/a514b4087886f56ea717 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
javascript:(function(){var buttonElements=document.getElementById('watch-like-dislike-buttons').getElementsByClassName('yt-uix-button-content');var viewElement=document.getElementById('watch7-views-info');var i=another=Number(buttonElements[0].innerHTML.replace(",",""));var j=Number(buttonElements[1].innerHTML.replace(",",""));var count=setInterval(function(){counter(i);i++;if(i>=another+1000){clearInterval(count);}},10);function counter(num){buttonElements[0].innerHTML=String(num).replace(/(\d)(?=(\d\d\d)+(?!\d))/g,'$1,');viewElement.getElementsByClassName('video-extras-sparkbar-likes')[0].style.width=100*num/(num+j)+'%';viewElement.getElementsByClassName('video-extras-sparkbar-dislikes')[0].style.width=100*j/(num+j)+'%';}})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment