• 30. Mai
  • 18:47
  • 2010

  • Updated
  • 20. Okt
  • 22:02
  • 2010

Fool Facebook's Like-Button

Edit: This doesn't work with the new pages-like-system (Blabla likes Some stuff on example.com).
Edit: Diese Prozedur funktioniert nicht ordnungsgemäß mit dem neuen Like-System (Blabla gefällt Irgendwas auf irgendeinerwebseite).

Note that this is a bilingual post. Scroll down to read it in German.

English

Yesterday I grew pretty sick of having to click "Like" on certain Facebook-pages, just to see what their content is. However, as simple as it may sound, there is always a way around! (hehe)

Here is how:

  1. Drag the following link into your Bookmarkbar: FoolLike
  2. Visit a facebookpage which only displays it's secret if you like it
  3. Click FoolLike in your bookmarks.
  4. No 4th step needed :D

Note: I only tested this on 3 pages. If it's not working for you, write a comment!

If you are more tech-savvy.. Scroll down, or click here

German

Der Mensch ist ein neugieriges Wesen. Dies machen sich in letzter Zeit immer mehr Facebook-Pages zu nutze indem sie einen User zwingen sie zu mögen, um ihren Inhalt zu sehen. Ich persönlich finde diesen Umstand katastrophal, denn man sollte meiner Meinung nach etwas wegen seinem Inhalt bzw. wegen seiner Aussage mögen, und nicht etwa um den Inhalt einsehen zu können.

Doch wie heißt es so schön? Es gibt immer einen Weg:

  1. Zieht den folgenden Link in eure Lesezeichen-Symbolleiste: FoolLike
  2. Geht auf irgendeine Facebook-Page welche euch zum liken zwingt.
  3. Klickt auf das FoolLike Lesezeichen
  4. Nein es gibt kein viertens ;-)

Ich will noch kurz anmerken, dass ich dieses kleine Skriptchen nur auf 3 Pages getestet habe. Falls es nicht funktioniert, schreib einfach ein Kommentar.

Tech-Jargon

Okay so some people might be interested in how this is achieved. Well this is by far no black-magic or anything. Plain javascript:

appcontent = document.getElementById('tab_canvas').getElementsByTagName('*');
for (i = 0; i < appcontent.length; i++) {
    appcontent[i].style['visibility'] = 'visible';
};

As you can see it's pretty simple. Those pages I looked at are constructed like this:

<div id="tab_canvas" class="tab_content profile_bottom_wash">
    .. some more divs ..
    <span style="visibility: hidden">
        Hidden content
    </span>
</div>

So, easy as that. Just get the tab_canvas div and while iterating over all child elements, set the visibility to visible.

Since this is my first bookmarklet I came across something really important. In order to get your bookmarklet to function properly.. you need to do the following:

javascript:(function(){
    // Code comes here
})()

Minified and put into html.. It looks like this:

<a href="javascript:(function(){appcontent=document.getElementById('tab_canvas').getElementsByTagName('*');for(i=0;i<appcontent.length;i++){appcontent[i].style['visibility']='visible';};})()">FoolLike</a>

Hopefully this is helpful!

Thanks for reading. Danke.

blog comments powered by Disqus

This is Luis’ blog. Here he posts about stuff that he encounters in everday life, both virtual and real.

Recently he wrote “Complete Facebook Profile?”, “Lighttpd's X-Sendfile”, “Modular Lighttpd Configurations”, “Fool Facebook's Like-Button” and “Calculating Battery Health”.

Contact