You are in a maze of twisty passages, all alike.
RSS icon Email icon Home icon
  • Defeating the DiggBar…

    Posted on April 11th, 2009 Finster No comments

    from-the-internetI ran into this little snippet at Daring Fireball:

    Last week Digg released something they call the DiggBar, which serves as both a new interface for Digg and doubles as a URL shortening service. The way it works is that you just add “digg.com/” at the beginning of any URL, and Digg creates a short URL in the form of digg.com/1234. Here’s an example DiggBar URL that points to google.com: http://digg.com/d1nYVs. Further, the Digg homepage now links to these DiggBar URLs rather than linking directly to other web sites.

    But unlike normal URL shortening services, when you load these Digg URLs, rather than redirect you to the original URL, Digg loads a page which frames the content of the original site. As a user, what you see is that the URL in your browser’s location field remains digg.com/1234, and the content of the destination site loads underneath a Digg-branded toolbar.

    Obviously, this is a problem.

    I’ve gone ahead and implemented Daring Fireball’s 3 lines of PHP code on my site here. You can see my results: http://digg.com/u1j0Z

    Begone, DiggNation.

    UPDATE: Apparently, Digg has not set up the diggBar so that Digg doesn’t show up as the HTTP_REFERER. Therefore, I’ve had to unleash the nuclear option and added some javascript to block all framing whatsoever. Not really what I wanted to do, but until I come up with another solution, it will have to do.

    Leave a reply