Perceive

Auto-Discovery Bookmarklet

Here is the latest and greatest Auto-Discovery Subscription Bookmarklet Thingamabob;void(el=d.getElementsByTagName('link'));g=false;h='';for(i=0;i<el.length;i++){void(ty=el[i].getAttribute('type'));if(ty.indexOf('application/rss+xml')!=-1||ty.indexOf('text/xml')!=-1||ty.indexOf('text/x-opml')!=-1){void(x=el[i].getAttribute('href'));if(window.confirm('Subscribe to: '+x+'?')){h=h+x+',';g=true;}}};if(!g){window.alert('No Subscriptions Made');}else{h=h.substr(0,h.length-1);void(window.open('http://127.0.0.1:8888/index.html?add_url='+h));}). Changes in this one include:

  • Support for pages with more than one subscription type
    • Support for text/x-opml, application/rss+xml, and text/xml
    • Confirmation dialog, allowing you to selectively subscribe to the feeds you want
    • Feeds are subscribed to via one single URL passed to AmphetaDesk

Let me know if you all have any problems with it, or would like to see it do something it doesn't.

Update: This Bookmarklet;void(el=d.getElementsByTagName('link'));g=false;h='';for(i=0;i<el.length;i++){void(ty=el[i].getAttribute('type'));if(ty.indexOf('application/rss+xml')!=-1||ty.indexOf('text/xml')!=-1||ty.indexOf('text/x-opml')!=-1){void(x=el[i].getAttribute('href'));if(window.confirm('Subscribe to: '+x+'?')){h=h+encodeURIComponent(x)+',';g=true;}}};if(!g){window.alert('No Subscriptions Made');}else{h=h.substr(0,h.length-1);void(window.open('http://127.0.0.1:8888/index.html?add_url='+h));}) fixes a problem with feed URLS with ?'s in them.

Tags
Related Links Elsewhere