Update 2007-02-05:
- since the activation of the new Metafilter url scheme, this bookmarklet is broken; I'm working on a new version :)


Bookmarklet:
- detect deleted Metafilter threads
(update 2006-01-15: now also works for Ask Metafilter)

Drag the link above to your browser's Links toolbar and click it while viewing the Metafilter front page (or one of the archived months); this will open up a new window with links to recently deleted threads (works by detecting the gaps in the sequence of thread ids). Tested in Firefox and IE6.

[Inspired by this MetaTalk thread]

Source code:
javascript:void(A=document.getElementsByTagName('a'), N=[],M=[],f=''); for(i=0;i<A.length;i++){ void(h=A[i].href,p=h.indexOf('/mefi/')); if(p!=-1 && h.indexOf('#')==-1 && A[i].parentNode.tagName.toLowerCase()=='span'){ void(k=h.substring(p+6,h.length),N[N.length]=k,M[k]=1)}} for (i=N[0]; i>N[N.length-1]; i--) { if (!M[i]) f += '<a target=_blank href=http://'+location.host+'/mefi/' +i+'>'+i+'</a>\n'; } void((W=window.open()).document.write('Deleted threads: ' + f));void(W.document.close());

comments

1. posted by dab at 01:29 on August 06, 2004

Clever toy - thanks!

2. posted by Armoured-Ant at 19:09 on August 06, 2004

All I get is a popup with

Deleted threads:

in it.

3. posted by ericville at 03:37 on August 07, 2004

niiice! very clever, indeed ;)

Armoured-Ant: double check that you're executing the bookmarklet from the same browser window that you have MetaFilter pulled up on- i got the same thing when i tried it the first time.

4. posted by Dave at 17:56 on August 10, 2004

Don't all these show up in the RSS feed anyway?

5. posted by slart at 03:33 on August 11, 2004

works in safari too, thanks!

6. posted by Jeblis at 09:27 on July 27, 2006

Neat script. Thanks for the update!

7. posted by Captain Science at 22:35 on February 25, 2007

Can't wait for the new version!

8. posted by rider at 02:58 on May 02, 2007

Here's a hacked version that works with the new Url scheme (in firefox...not well tested...use at own risk)

javascript:void(A=document.getElementsByTagName('a'),N=[],M=[],f=''); for(i=0; i<A.length; i++){ void(h=A[i].href,k=h.match(/\d{5}/)); if(k > 10000 && h.indexOf('user') ==-1 && h.indexOf('#')==-1 && A[i].parentNode.tagName.toLowerCase()=='span'){ void(N[N.length]=k,M[k]=1)} } for (i=N[0]; i>N[N.length-1]; i--) { if (!M[i]) f += '<a target=_blank href=http://'+location.host+'/mefi/' +i+'>'+i+' </a>\n'; } void((W=window.open()).document.write('Deleted threads: ' + f)); void(W.document.close());

add a comment

Note: no HTML allowed. URLs starting with http:// are automatically turned into working links. Please don't spam.