<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-6260775124375674077</id><updated>2011-09-23T16:18:28.921+01:00</updated><category term='talksATcam'/><category term='calendar'/><category term='mendeley'/><category term='pipes'/><category term='Yahoo pipes'/><category term='bookmarklet'/><title type='text'>The Arcadia Mashups Blog</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://arcadiamashups.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://arcadiamashups.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Tony Hirst</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>10</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-6260775124375674077.post-254879034794115843</id><published>2011-09-22T13:21:00.000+01:00</published><updated>2011-09-22T13:21:12.711+01:00</updated><title type='text'>Feed Autodiscovery In Javascript</title><content type='html'>  &lt;script src="http://www.google.com/jsapi" type="text/javascript"&gt;&lt;/script&gt;    &lt;script type="text/javascript"&gt;     google.load("feeds", "1");     google.load("jquery", "1.6.2");     //---      //http://jquery-howto.blogspot.com/2009/09/get-url-parameters-values-with-jquery.html     function setup() {         $.extend({             getUrlVars: function () {                 var vars = [],                     hash;                 var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&amp;');                 for (var i = 0; i &lt; hashes.length; i++) {                     hash = hashes[i].split('=');                     vars.push(hash[0]);                     vars[hash[0]] = hash[1];                 }                 return vars;             },             getUrlVar: function (name) {                 return $.getUrlVars()[name];             }         });     }     //---     function OnLoad() {         setup()         if (!($.getUrlVar('url'))) $('#url').val('http://blog.ouseful.info');         else $('#url').val(unescape($.getUrlVar('url')));         lookupFeed()     }     function yqlAutodisc(){		var yqurl='http://query.yahooapis.com/v1/public/yql/psychemedia/feedautodetect?url='+escape($('#url').val())+'&amp;format=json'		$('#ycontent').html('&lt;em&gt;...trying...&lt;/em&gt;')     	$.getJSON(yqurl, function(response){  			// response is a variable containing the JSON object, if it fetched it successfully		  			if (!(response.query.count))  				$('#ycontent').html('&lt;em&gt;No autodiscoverable feeds...&lt;/em&gt;')  			else {  				$('#ycontent').html('')  				$.each(response.query.results.link, function(i,item){  					$('#ycontent').append('&lt;div&gt;&lt;em&gt;'+item.title+'&lt;/em&gt;: &lt;a href="'+item.href+'"&gt;'+item.href+'&lt;/a&gt;&lt;/div&gt;')				});			}		})     }          function lookupFeed() {         $('#content').html("&lt;em&gt;...trying...&lt;/em&gt;")         // Go find it!  Call lookupDone when the search is complete.         var url = $('#url').val()         google.feeds.lookupFeed(url, lookupDone);                  yqlAutodisc();     }     function lookupDone(result) {         // Make sure we didn't get an error.         if (!result.error &amp;&amp; result.url != null) {             var url = result.url;             // Print the feed found to the page.  Note that we only ever get one result             // back from a lookupFeed.             $('#content').html('&lt;a href="' + url + '"&gt;' + url + '&lt;/a&gt;');             $('#furl').val(url)             lookupFeedHistory()         } else $('#content').html("&lt;em&gt;No feed found...&lt;/em&gt;")     }     function feedLoaded(result) {         if (!result.error) {             $('#histcontent').html('')             // Loop through the feeds, putting the titles onto the page.             // Check out the result object for a list of properties returned in each entry.             // http://code.google.com/apis/ajaxfeeds/documentation/reference.html#JSON             for (var i = 0; i &lt; result.feed.entries.length; i++) {                 var entry = result.feed.entries[i];                 $('#histcontent').append('&lt;div&gt;' + i + ': &lt;a href="'+entry.link+'"&gt;' + entry.title + '&lt;/a&gt;&lt;/div&gt;');             }         } else $('#histcontent').html('&lt;em&gt;Something appears to be wrong:-(&lt;/em&gt;')     }     function lookupFeedHistory() {         $('#histcontent').html("&lt;em&gt;...trying...&lt;/em&gt;")         var url = $('#furl').val()         var feed = new google.feeds.Feed(url);         feed.includeHistoricalEntries(); // tell the API we want to have old entries too         feed.setNumEntries($('#furlmax').val()); // should really noddy check this first for an appropriate value         // Calling load sends the request off.  It requires a callback function.         feed.load(feedLoaded);     }     google.setOnLoadCallback(OnLoad);    &lt;/script&gt;        &lt;form action="javascript:lookupFeed()"&gt;&lt;span&gt;Try your own URL:&lt;/span&gt; &lt;input type="text" size="60" id="url"/&gt; &lt;input id="newgo" type="submit" value="Go"/&gt;&lt;/form&gt;    &lt;div&gt;Top feed for this page (via Google feed api): &lt;span id="content"&gt;&lt;/span&gt;&lt;br/&gt;&lt;br/&gt;    Feeds detected via YQL: &lt;span id="ycontent"&gt;&lt;/span&gt;&lt;/div&gt;    &lt;br/&gt;    &lt;form action="javascript:lookupFeedHistory()"&gt;&lt;span&gt;Try your own feed URL:&lt;/span&gt; &lt;input type="text" size="60" id="furl"/&gt; Items: &lt;input type="text" size="5" id="furlmax" value='10'/&gt; (max 250) &lt;input id="histgo" type="submit" value="Go"/&gt;&lt;/form&gt;        &lt;div&gt;Historical entries for this feed: &lt;span id="histcontent"&gt;&lt;/span&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6260775124375674077-254879034794115843?l=arcadiamashups.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://arcadiamashups.blogspot.com/feeds/254879034794115843/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://arcadiamashups.blogspot.com/2011/09/feed-autodiscovery-in-javascript.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/254879034794115843'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/254879034794115843'/><link rel='alternate' type='text/html' href='http://arcadiamashups.blogspot.com/2011/09/feed-autodiscovery-in-javascript.html' title='Feed Autodiscovery In Javascript'/><author><name>Tony Hirst</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6260775124375674077.post-6453857958637903458</id><published>2009-11-27T22:19:00.008Z</published><updated>2009-11-28T21:58:41.809Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='mendeley'/><category scheme='http://www.blogger.com/atom/ns#' term='pipes'/><category scheme='http://www.blogger.com/atom/ns#' term='Yahoo pipes'/><title type='text'>Mashlib Pipes Tutorial: Reading List Inspired Journal Watchlists</title><content type='html'>It's coming up to that Mashed Libraries time of year again (&lt;a href="http://middlemash.wordpress.com/"&gt;Middlemash&lt;/a&gt;, this time), which means it's time for me to put together a new Yahoo Pipes demo, ideally one that builds on something I've used at a previous mashed Library event (in particular, the &lt;a href="http://ouseful.wordpress.com/2009/07/09/mashlib-pipes-tutorial-2d-journal-search/"&gt;Mashlib Pipes Tutorial: 2D Journal Search&lt;/a&gt;). So here's a little something that does exactly that...&lt;br /&gt;&lt;br /&gt;(If you're new to Yahoo Pipes, check out the introductory post "&lt;a href="http://arcadiamashups.blogspot.com/2009/10/getting-started-with-yahoo-pipes.html"&gt;Getting Started With Yahoo Pipes: Merging RSS Feeds&lt;/a&gt;", which shows how Pipes work, and leads you through a get you startd activity to create a pipe that merged several RSS feeds to produce a single, aggregate feed.)&lt;br /&gt;&lt;br /&gt;In particular, in this demonstration I'll show how it's possible to use a pipe that either you yourself, or someone else entirely, might have already built, within a new pipe of your own.&lt;br /&gt;&lt;br /&gt;To set the scene, suppose you have a list... a list of resources... a reading list, for example. In and of itself, this might be a key resource in the delivery of a course, but might it also be &lt;em&gt;more&lt;/em&gt; than that? Whenever &lt;em&gt;I&lt;/em&gt; see a list of web resources, I ask myself: &lt;em&gt;could this be the basis of a custom search engine that searches over just those resources, or just the websites those resources live on?&lt;/em&gt; So where might this thought take us in the context of a reading list?&lt;br /&gt;&lt;br /&gt;Over on the Arcadia blog, I showed how &lt;a href="http://www.mendeley.com/"&gt;Mendeley&lt;/a&gt; might be used to support the publication and syndication of reading lists (&lt;a href="http://arcadiaproject.blogspot.com/2009/11/reading-list-management-with-mendeley.html"&gt;Reading List Management with Mendeley&lt;/a&gt;), using a list built around references to a series of journal articles as an example; this list, in fact: &lt;a href="http://www.mendeley.com/collections/36456/Synthetic-Biology/"&gt;"Synthetic Biology" Collection, by Ricardo Vidal&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;One of the nice things about Mendeley public collection is that they expose an RSS feed of the collection, so might we be able to use Yahoo Pipes to:&lt;br /&gt;&lt;br /&gt;- extract a set of journal titles from a list, and then&lt;br /&gt;- create a watchlist over the current tables of contents of those listed journals&lt;br /&gt;&lt;br /&gt;to keep us up to date with the some of the recent literature in that topic area?&lt;br /&gt;&lt;br /&gt;To start with, let's look at how we might grab a list of current contents feeds, filtered by keyword, for the journals listed in the Mendeley Reading list identified above. The first thing to do is import the reading list feed into the pipes environment:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/4141923256/" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2519/4141923256_a53041247f.jpg" width="500" height="120" alt="Pipes grab feed"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;The way this list has been constructed we can find a reference to the journal in the description element:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/4141175773/" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2649/4141175773_f5feb773e9.jpg" width="500" height="213" alt="Inspecting a Mendeley reading list"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;We also note that a "journal" category has been used, which we could filter the items against:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/4141183321/" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2786/4141183321_0d87e85d3b.jpg" width="478" height="122" alt="Mendeley Pipe - filter on journal items"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Extracting the journal title from the description requires the use of a heuristic (rule of thumb). Noticing that the description typically contains references of the form &lt;em&gt;Journal title (year), volume, page reference etc.&lt;/em&gt;, we can use a regular expression to strip out everything after and  including the first bracket that opens on to a numeral 1 or 2:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/4141950034/" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2619/4141950034_2dd6cdfd38.jpg" width="500" height="99" alt="Mendeley -xtracting a journal title"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;The second step of the regular expression block simply groups the title as a search phrase within quotation marks. Using a &lt;em&gt;Unique&lt;/em&gt; block removes duplicate entries in the feed so we don't search for the same journal title more than once.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/4141972528/" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2788/4141972528_e257015337.jpg" width="398" height="84" alt="dedupe in a pipe"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;To grab the filter contents feed, we use the Loop block to search Scott Wilson's JOPML service (which provides a search interface over journal titles indexed by the TicTocs current journal contents service) using the &lt;a href="http://ouseful.wordpress.com/2009/07/09/mashlib-pipes-tutorial-2d-journal-search/"&gt;2D Journal Search&lt;/a&gt; block I put together after the last mashlib:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/4141981850/" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2763/4141981850_3981fa9766.jpg" width="500" height="222" alt="Using an embedded pipe"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;So what do we have now? The ability to pull out a list of unique journal titles (hopefully!) and then use these as publication search terms in a JOPML search for publications indexed by TicTocs; a set of keyword/topic search terms are then applied to the titles of articles in the current issue of the listed journals, in order to provide a watchlist of articles on a particular topic from a list of journals as identified in a reading list. (To display all the content, simply use a space character as a search term.)&lt;br /&gt;&lt;br /&gt;by looking at the data returned by the 2D search pipe, we also get a few ideas for further possible refinements:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/4141987190/" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2569/4141987190_0f138095b8.jpg" width="442" height="262" alt="TicTocs metadata"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;For example, we might sort the results by publication title, or use a regular expression to annotate the title with the name of the journal it came from.&lt;br /&gt;&lt;br /&gt;You can find a copy of the pipe here: &lt;a href="http://pipes.yahoo.com/pipes/pipe.info?_id=5aa865374074be9486f069962b36632b"&gt;Mendeley Reading list journal watcher&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6260775124375674077-6453857958637903458?l=arcadiamashups.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://arcadiamashups.blogspot.com/feeds/6453857958637903458/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://arcadiamashups.blogspot.com/2009/11/mashlib-pipes-tutorial-reading-list.html#comment-form' title='10 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/6453857958637903458'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/6453857958637903458'/><link rel='alternate' type='text/html' href='http://arcadiamashups.blogspot.com/2009/11/mashlib-pipes-tutorial-reading-list.html' title='Mashlib Pipes Tutorial: Reading List Inspired Journal Watchlists'/><author><name>Tony Hirst</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://farm3.static.flickr.com/2519/4141923256_a53041247f_t.jpg' height='72' width='72'/><thr:total>10</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6260775124375674077.post-3047918858637405377</id><published>2009-11-03T15:15:00.001Z</published><updated>2009-11-04T10:05:40.289Z</updated><title type='text'>Open Library Training Materials and Custom Search Engines</title><content type='html'>Chatting to a fellow Visiting Fellow this morning about the best way of searching historical newspaper content (my vote, given the local context, was to use Factiva or LexisNexis (or is it called Lexis Library now?), it struck me that it might be handy to be able to search across all the UK HEI Library websites for tutorials and generic training materials.&lt;br /&gt;&lt;br /&gt;So how might we do this? One easy way I know of creating a site (or page) limited search engine is via a &lt;a href="http://www.google.com/cse/docs/"&gt;Google Custom Search Engine&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;&lt;object width="425" height="344"&gt;&lt;param name="movie" value="http://www.youtube.com/v/IeiFFpo8qME&amp;hl=en&amp;fs=1&amp;rel=0"&gt;&lt;/param&gt;&lt;param name="allowFullScreen" value="true"&gt;&lt;/param&gt;&lt;param name="allowscriptaccess" value="always"&gt;&lt;/param&gt;&lt;embed src="http://www.youtube.com/v/IeiFFpo8qME&amp;hl=en&amp;fs=1&amp;rel=0" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="344"&gt;&lt;/embed&gt;&lt;/object&gt;&lt;br /&gt;&lt;br /&gt;For a more detailed overview, see &lt;a href="http://www.youtube.com/watch?v=arTvmaMkNCI"&gt;Google Developer Day US - Google Custom Search Engine&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;Handily, @ostephens posted an application that screenscrapes UK HE Library details (including th URIs of Library websites) from Sconul the other day (&lt;a href="http://www.meanboyfriend.com/overdue_ideas/2009/11/accessing-sconul-access"&gt;Accessing Sconul Access&lt;/a&gt;), from which I took a dump of details for all UK Libraries that I've placed at &lt;a href="http://dl.getdropbox.com/u/1176102/sconulLibs.xml"&gt;http://dl.getdropbox.com/u/1176102/sconulLibs.xml&lt;/a&gt;, RSSified at &lt;a href="http://pipes.yahoo.com/pipes/pipe.info?_id=f257abdf5a1b6486afa56ad1ed63af8c"&gt;Sconul RSS Pipe&lt;/a&gt; and geocoded/mapped at &lt;a href="http://pipes.yahoo.com/pipes/pipe.info?_id=fb5ef40222bc84ae6a23446438a4a307"&gt;SCONUL Map&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://pipes.yahoo.com/pipes/pipe.info?_id=fb5ef40222bc84ae6a23446438a4a307" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2622/4071525569_990d1020ef.jpg" width="500" height="475" alt="Sconul Map http://pipes.yahoo.com/pipes/pipe.info?_id=fb5ef40222bc84ae6a23446438a4a307"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;It's been some time since I created a Google Linked Custom Search Engine (that is, a custom search engine whose limits are set dynamically from a linked to configuration (that is, &lt;em&gt;annotation&lt;/em&gt; file), but I had a vague memory that it was possible to create an annotation file from an RSS feed (such as the one I created above from the Sconul data), and indeed it is possible: &lt;a href="http://www.google.com/cse/docs/tools.html"&gt;Tools for Linked CSEs&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;So for example, here is an &lt;a href="http://www.google.com/cse/tools/makeannotations?url=pipes.yahoo.com%2Fpipes%2Fpipe.run%3F_id%3Df257abdf5a1b6486afa56ad1ed63af8c%26_render%3Drss&amp;label=sconul&amp;pattern=path"&gt;annotation file from the Sconul data&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;However, wiring this feed into a new CSE &lt;em&gt;didn't&lt;/em&gt; appear to work (maybe it takes some time for the feed to start powering the CSE?), so instead I ran a quick search and replace over the contents of a copy of the annotation file, and just pasted the literal URIs into the configuration page of a new CSE:&lt;br /&gt;&lt;br /&gt; &lt;a href="http://www.google.com/cse/docs/" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2219/4072336490_7b2e5beb71.jpg" width="500" height="430" alt="Creating a Google CSE"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Anyway, here it is, such as it is: a &lt;a href="http://www.google.com/cse/home?cx=009190243792682903990:phpddg0idfs"&gt;custom search engine that searches over UK HEI Library websites&lt;/a&gt; (possibly;-)&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.google.com/cse?cx=009190243792682903990%3Aphpddg0idfs&amp;q=lexisnexis+tutorial" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2649/4071582415_3f48f6d193.jpg" width="500" height="386" alt="Exanple UK HEI Library website CSE http://www.google.com/cse?cx=009190243792682903990%3Aphpddg0idfs&amp;q=lexisnexis+tutorial"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;PS Also related, @lorcand posted a couple of tweets over the last few days about Library tutorial videos on Youtube:&lt;br /&gt;- &lt;em&gt;U Glasgow library vids "Library On Demand" &lt;a hrf="http://www.lib.gla.ac.uk/libraryondemand/"&gt;http://www.lib.gla.ac.uk/libraryondemand/&lt;/a&gt; via @williamjnixon (URL fixed)&lt;/em&gt;&lt;br /&gt;- &lt;em&gt;Five (yes, five) video tutorials about using the library catalogue. &lt;a href="http://www.bristol.ac.uk/studentskills/content/ilitskills/tutorials/librarycatalogue/"&gt;http://www.bristol.ac.uk/studentskills/content/ilitskills/tutorials/librarycatalogue/&lt;/a&gt;&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;I'm not sure if there's a list of Library presences on Youtube (there is &lt;a href="http://www.lizazyan.com/uk-universities-on-youtube/"&gt;one for HEIs&lt;/a&gt;, which I used as the basis of a &lt;a href="http://ouseful.wordpress.com/2009/08/28/uk-hei-boxee-channel/"&gt;UK HEIs DeliTV channel&lt;/a&gt;) but if there is, it won't be too hard to create a custom search engine over those channels.&lt;br /&gt;&lt;br /&gt;In the meantime, here are a couple more loosely library related custom search engines: &lt;a href="http://ouseful.open.ac.uk/howdoi"&gt;How Do I?&lt;/a&gt; Instructional video search (&lt;a href="http://ouseful.open.ac.uk/blogarchive/010608.html"&gt;about HowDoI&lt;/a&gt;), and my &lt;a href="http://www.google.com/cse/home?cx=009190243792682903990:-xmjvu8uf1a"&gt;Science Experimental Protocols Video Search &lt;/a&gt;, which searches over several sites that collate scientific/experimental protocols.&lt;br /&gt;&lt;br /&gt;See also: Brian Kelly on &lt;a href="http://ukwebfocus.wordpress.com/2009/10/23/opening-up-institutional-training-resources/"&gt;Opening Up Institutional Training Resources&lt;/a&gt;, me on &lt;a href="http://ouseful.wordpress.com/2009/09/16/vendor-certification-on-the-open-web-google-training-resources/"&gt;Google('s) Training Resources&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6260775124375674077-3047918858637405377?l=arcadiamashups.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://arcadiamashups.blogspot.com/feeds/3047918858637405377/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://arcadiamashups.blogspot.com/2009/11/open-library-training-materials-and.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/3047918858637405377'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/3047918858637405377'/><link rel='alternate' type='text/html' href='http://arcadiamashups.blogspot.com/2009/11/open-library-training-materials-and.html' title='Open Library Training Materials and Custom Search Engines'/><author><name>Tony Hirst</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://farm3.static.flickr.com/2622/4071525569_990d1020ef_t.jpg' height='72' width='72'/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6260775124375674077.post-3611263916577831301</id><published>2009-11-03T11:52:00.000Z</published><updated>2009-11-03T11:52:00.127Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='calendar'/><category scheme='http://www.blogger.com/atom/ns#' term='pipes'/><category scheme='http://www.blogger.com/atom/ns#' term='talksATcam'/><title type='text'>Cambridge Calendar Feeds (Part I) - Screenscraping with Yahoo Pipes</title><content type='html'>In the post &lt;a href="http://arcadiamashups.blogspot.com/2009/10/getting-started-with-yahoo-pipes.html"&gt;Getting Started With Yahoo Pipes: Merging RSS Feeds&lt;/a&gt;, I described how it's possible to merge two or more RSS feeds within a Yahoo pipe in order to produce a single combined feed.&lt;br /&gt;&lt;br /&gt;But what happens if there is no feed available from a website or a webpage? Is there any way we can bring that content into the Yahoo Pipes environment, perhaps so that we can combine it with a 'proper' RSS feed? Well it so happens that there &lt;em&gt;are&lt;/em&gt; several other ways of bringing content into a Pipe, other than by subscribing to an RSS feed, and I'll describe one of them here: importing an HTML page directly, and turning a particular section of it into an RSS feed.&lt;br /&gt;&lt;br /&gt;As an example, let's consider the following page on the &lt;a href="http://talks.cam.ac.uk/dates/2009/11/2"&gt;talks@cam&lt;/a&gt; website:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://talks.cam.ac.uk/dates/2009/11/2" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2554/4068419625_c3de2d2d87.jpg" width="500" height="313" alt="talks@cam http://talks.cam.ac.uk/dates/2009/11/2"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Although many of the list types on the talks@cam website support a wide variety of output formats (including RSS), the daily full fat feed doesn't appear to. The only option is the HTML output (unless someone can tell me how to find a feed? That said, this post &lt;em&gt;is&lt;/em&gt; all about making do with what we've got and consequently generating RSS from an HTML page...)&lt;br /&gt;&lt;br /&gt;If we look at the HTML code that generates the page using the &lt;em&gt;View Source&lt;/em&gt; option from the browser &lt;em&gt;View&lt;/em&gt; menu, we can (eventually) see that the page is structured quite neatly.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/4069188326/" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2434/4069188326_36af06b977.jpg" width="500" height="157" alt="View source on a camt talks daily listing"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;(Just because the page looks neat and tidy in the full browser view doesn't necessarily mean the HTML code is nicely structured!).&lt;br /&gt;In particular, we can see that there is a repeating element at the start of each calendar entry - in particular, the &lt;em&gt;&amp;lt;li&amp;gt;&lt;/em&gt; element - and that each listing item follows a similar pattern, or structure. So for example, if we look at:&lt;br /&gt;&lt;br /&gt;&lt;em&gt;&amp;lt;li&amp;gt;12:45 - &amp;lt;a href="http://talks.cam.ac.uk/talk/index/20701" class="click link"&amp;gt;Dependent types and program equivalence&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;we see it has the structure:&lt;br /&gt;&lt;br /&gt;&lt;em&gt;&amp;lt;li&amp;gt;&lt;strong&gt;TIME&lt;/strong&gt; - &amp;lt;a href="&lt;strong&gt;EVENT URI&lt;/strong&gt;" class="click link"&amp;gt;&lt;strong&gt;EVENT DETAILS&lt;/strong&gt;&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;This is how it appeared on the rendered web page in the browser:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/4068454525/" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2735/4068454525_f82d0afe56.jpg" width="457" height="45" alt="talks@cam example event"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;The &amp;lt;li&amp;gt; defines a list element, which is rendered in the browser as a list item starting with a bullet; the &amp;lt;a&amp;gt; tag defines a link, with the defined URI and link text.&lt;br /&gt;&lt;br /&gt;Now suppose that we would like an RSS feed where each item in the feed corresponded to a separate event. How might w go about that?&lt;br /&gt;&lt;br /&gt;The first step is to bring the HTML page into the pipes environment using the Fetch HTML block from the Pipes' Source menu. The URI &lt;em&gt;http://talks.cam.ac.uk/dates&lt;/em&gt; appears to pull up the events for the current date (though a more exact URI pattern of the form &lt;em&gt;http://talks.cam.ac.uk/dates/YEAR/MONTH/DAY&lt;/em&gt; such as &lt;em&gt;http://talks.cam.ac.uk/dates/2009/11/3&lt;/em&gt; also pulls up the page for a particular date) so that's the one we'll use:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/4069240718/" title="Photo Sharing"&gt;&lt;img src="http://farm4.static.flickr.com/3490/4069240718_df7e328172.jpg" width="500" height="333" alt="Yahoo screen scraper"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;You'll see the pipe has brought the web page into the pipe context. As well as previewing the rendered web page, we can inspect the HTML by clicking on the &lt;em&gt;source&lt;/em&gt; in the Previewer:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/4069245238/" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2595/4069245238_c7001792bc.jpg" width="500" height="217" alt="Pipe screen scraper - view html"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;You'll notice that the &lt;em&gt;Fetch Page&lt;/em&gt; block allows us to declare where we want to &lt;em&gt;Cut content from&lt;/em&gt;, and &lt;em&gt;to&lt;/em&gt; and also how we want to &lt;em&gt;split&lt;/em&gt; it. That is, we can specify  some HTML code in the page that tells the pipe where the 'useful' part of the page starts (that is, that part of it we want to "scrape" the content from), and where the useful part of the page (as far as we're concerned) ends, &lt;em&gt;and&lt;/em&gt; what piece of repeating HTML we want the pipe to use to separate out the different items contained in the page.&lt;br /&gt;&lt;br /&gt;To star with that 'delimiter', we recall each item in the event list starts with &amp;lt;li&amp;gt;, so we shall use that as our delimiter.&lt;br /&gt;&lt;br /&gt;But how do we know where the useful HTML starts, and where it ends? We have to find that by trial and error through inspecting the HTML. We need something that appears for the first time in the page close to thee start of the useful content, and something that appears for the first time after that just after the end of the useful content. (If necessary, we might have to grab an excessively large piece of HTML from the page .)&lt;br /&gt;&lt;br /&gt;Not that in the current case, whilst it might look like &lt;em&gt;&amp;lt;h3&amp;gt;Monday 02 November 2009&amp;lt;/h3&amp;gt;&lt;/em&gt; provides us with a unique place from which to start cutting content, if we look at the listing for a different today's date, there will be a different set of characters there...!&lt;br /&gt;&lt;br /&gt;Using the &amp;lt;/h3&amp;gt; tag as the start of the useful content, and &amp;lt;/ul&amp;gt; as the end, we can tell the pipe to cut out the useful listings:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/4069292378/" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2687/4069292378_62bef0ec44.jpg" width="500" height="233" alt="talks@cam scraping"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Adding the &amp;lt;li&amp;gt; delimiter gives us a crude set of items, one for each event:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/4068543965/" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2469/4068543965_7f6cf7cae1.jpg" width="500" height="211" alt="Screeenscraping talks@cam"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;In order to turn these items into 'proper' RSS feed items, we need to define a title, and ideally also a link for the event. We can create, and prepopulate these links using the &lt;em&gt;Rename&lt;/em&gt; block from the &lt;em&gt;Operators&lt;/em&gt; menu:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/4068555869/" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2682/4068555869_0017440b2e.jpg" width="500" height="266" alt="Screenscraping Yahoo pipes"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;We now need to tidy up those elements with a &lt;em&gt;Regex&lt;/em&gt; (&lt;em&gt;Regular Expression&lt;/em&gt;) block. Regular Expressions are like voodoo magic - they let you manipulate a string of characters in order to transform that string in all sorts of ways. Written correctly, they can be very powerful and look very elegant. I tend use them in a pidgin way, fumbling my way to a solution using simple rules of them and tricks I've use before!&lt;br /&gt;&lt;br /&gt;So for example, I know that the pattern &lt;em&gt;.*href="([^"]*)".*&lt;/em&gt; will strip out the URI from a single line of text, that contains a link, and place it in the variable $1.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/4068572717/" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2441/4068572717_6fbcb938c1.jpg" width="500" height="292" alt="RegEx in Yahoo pipe"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;(The . stands for 'any character'; the * says 'zero or more of the preceding character (or any character for a preceding .); the expression [^"]* says 'a set of characters []* that isn't ^ a "; the () marks out the set of contiguous characters that will be passed to the variable $1; &lt;em&gt;href="&lt;/em&gt; and the final " are literal string matched characters. The whole string of matched characters are then replaced by the contents of the $1 variable. The &lt;em&gt;s&lt;/em&gt; is ticked so that the pipe will cope with any excess whitespace characters.)&lt;br /&gt;&lt;br /&gt;A second regular expression - &lt;em&gt;([^\s]*)[^&gt;]*&gt;([^&lt;]*).*&lt;/em&gt; replaced by &lt;em&gt;$2 ($1)&lt;/em&gt; - this time applied to the &lt;em&gt;title&lt;/em&gt; element, extracts the name of the talk and the time.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/4069308225/" title="Photo Sharing"&gt;&lt;img src="http://farm3.static.flickr.com/2789/4069308225_03a1c0aba4.jpg" width="500" height="229" alt="Yahoo pipes regex"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Finally, we tidy up the output of the feed to remove any items that don't also link to an vent record on talks@cam (that is, we remove items where an event link was not extracted by the regular expression.)&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/4070079868/" title="Photo Sharing"&gt;&lt;img src="http://farm4.static.flickr.com/3500/4070079868_86b7742f92.jpg" width="500" height="190" alt="Yahoo pipes - filter"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;And to tidy up the presentation a little more, we click in the title tab to give the pipe an appropriate name:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://pipes.yahoo.com/pipes/pipe.info?_id=15df40719fea352f9217fe471f6c0560" title="Photo Sharing"&gt;&lt;img src="http://farm4.static.flickr.com/3054/4069326197_c538f9042b.jpg" width="371" height="60" alt="Pipes title"/&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;If we now &lt;a href="http://pipes.yahoo.com/pipes/pipe.info?_id=7f06b4ba2d28a4192edb96f5d509a592"&gt;Run the pipe&lt;/a&gt;, we can grab a link to an RSS feed of today's talks@cam:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://pipes.yahoo.com/pipes/pipe.info?_id=7f06b4ba2d28a4192edb96f5d509a592" title="talks@cam scraper pipe http://pipes.yahoo.com/pipes/pipe.info?_id=15df40719fea352f9217fe471f6c0560 by psychemedia, on Flickr"&gt;&lt;img src="http://farm4.static.flickr.com/3521/4070106606_1b652c4dc2.jpg" width="500" height="256" alt="talks@cam scraper pipe http://pipes.yahoo.com/pipes/pipe.info?_id=15df40719fea352f9217fe471f6c0560" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;em&gt;In a follow on to this post, I'll show how to bring time into the equation and add a timestamp for each event to each item in the feed.&lt;/em&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6260775124375674077-3611263916577831301?l=arcadiamashups.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://arcadiamashups.blogspot.com/feeds/3611263916577831301/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://arcadiamashups.blogspot.com/2009/11/cambridge-calendar-feeds-part-i.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/3611263916577831301'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/3611263916577831301'/><link rel='alternate' type='text/html' href='http://arcadiamashups.blogspot.com/2009/11/cambridge-calendar-feeds-part-i.html' title='Cambridge Calendar Feeds (Part I) - Screenscraping with Yahoo Pipes'/><author><name>Tony Hirst</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://farm3.static.flickr.com/2554/4068419625_c3de2d2d87_t.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6260775124375674077.post-3207044664051068264</id><published>2009-10-29T12:56:00.004Z</published><updated>2009-10-29T14:02:57.274Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='pipes'/><title type='text'>Autodiscoverable RSS Feeds From Cambridge Libraries</title><content type='html'>One of the very many clever things that folk have worked out what they can do with web pages, web browsers and such like is a way of supporting the &lt;em&gt;autodiscovery&lt;/em&gt; of RSS feeds associated with a web page by declaring the location of the web feed within a &lt;tt&gt;&amp;lt;link&amp;gt;&lt;/tt&gt; tag in the &lt;tt&gt;&amp;lt;head&amp;gt;&lt;/tt&gt; of a web page (&lt;a href="http://www.rssboard.org/rss-autodiscovery"&gt;RSS autodiscovery: howto&lt;/a&gt;).&lt;br /&gt;&lt;br /&gt;What this means is that if you have a list of links to library web pages, you can potentially automatically discover any RSS feeds associated with that library (if they have published autodiscoverable feed links, that is).&lt;br /&gt;&lt;br /&gt;Some time ago, I put together a quick app that took a screenscraped list of UK HEI Library homepage URIs from somewhere (you wouldn't believe how hard it is to try to find a list of UK HEI library homepages;-) and tried to autodiscover any RSS feeds associated with them - &lt;a href="http://ouseful.wordpress.com/2009/04/06/autodiscoverable-rss-feeds-from-hei-library-websites/"&gt;Autodiscoverable RSS Feeds From HEI Library Websites&lt;/a&gt;. When I ran the &lt;a href="http://ouseful.open.ac.uk/iwmw/iwmwAuto.php"&gt;detector&lt;/a&gt; just now, I got about a 36% success rate, which is far better than this time last year...&lt;br /&gt;&lt;br /&gt;So anyway, I was wondering: how do the Cambridge University Libraries fare?&lt;br /&gt;&lt;br /&gt;Looking through my list of handy &lt;em&gt;cam.ac.uk&lt;/em&gt; links, here's one for an XML feed of the associated libraries, with links to their homepage: &lt;em&gt;http://www.lib.cam.ac.uk/api/local/libraries_data.cgi&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.lib.cam.ac.uk/api/local/libraries_data.cgi"&gt;&lt;img src="http://farm3.static.flickr.com/2442/4054951897_4f8b714815.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Notice that the URI for the web page of each library can be found down the XML path: &lt;tt&gt;libraries.&lt;em&gt;library.web_address&lt;/em&gt;&lt;/tt&gt;&lt;br /&gt;&lt;br /&gt;So let's bring this in to a Yahoo Pipes environment, and try to autodetect any RSS feeds linked to from those pages. As well as importing RSS, Yahoo Pipes can also import JSON and XML feeds using the Fetch Data import block. However, I've noticed that the Fetch Data block sometimes chokes (I'm not quite sure why) so instead I use another Yahoo service - YQL - to act as an intermediary that will fetch the xml, maybe process it a little for me, and then pull the result into the pipe:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://developer.yahoo.com/yql/console/?q=select%20library.web_address%20from%20xml%20where%20url%3D%27http%3A%2F%2Fwww.lib.cam.ac.uk%2Fapi%2Flocal%2Flibraries_data.cgi%27"&gt;&lt;img src="http://farm3.static.flickr.com/2684/4055707512_8652f310bf.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;(You can &lt;a href="http://developer.yahoo.com/yql/console/?q=select%20library.web_address%20from%20xml%20where%20url%3D%27http%3A%2F%2Fwww.lib.cam.ac.uk%2Fapi%2Flocal%2Flibraries_data.cgi%27"&gt;try this query in the YQL Developer console&lt;/a&gt;.)&lt;br /&gt;&lt;br /&gt;What the query statement does:&lt;br /&gt;&lt;tt&gt;select library.web_address from xml where url='http://www.lib.cam.ac.uk/api/local/libraries_data.cgi'&lt;/tt&gt;&lt;br /&gt;is grab all the &lt;tt&gt;library.web_address&lt;/tt&gt; elements (that point to the homepage for each library) from the XML page at &lt;em&gt;http://www.lib.cam.ac.uk/api/local/libraries_data.cgi&lt;/em&gt; and pass them in to the pipe as XML.&lt;br /&gt;&lt;br /&gt;&lt;em&gt;NB it's trivial to create a simple 'helper' pipe block that acts like a mimimal &lt;tt&gt;Fetch Data&lt;/tt&gt; block but actually pulls in the XML file via YQL:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://pipes.yahoo.com/ouseful/yqlxmlproxy "&gt;&lt;img src="http://farm3.static.flickr.com/2679/4054978739_ab1e86d2f4.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;This block could then be included in a pipe in the same way that a Fetch Data block can be...&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;So what next? Well, now we can use the &lt;tt&gt;Feed Autodiscovery&lt;/tt&gt; block to see if there are any autodiscoverable RSS feeds listed on those web pages.&lt;br /&gt;&lt;br /&gt;In order to do this, we need to pop the &lt;tt&gt;Feed Autodiscovery&lt;/tt&gt; inside a Loop block - this allows the pipe to grab any autodiscovered feed URIs and produce a new feed of feed URIs by replacing the original elements that point to the Library homepages. The &lt;tt&gt;Emit all results&lt;/tt&gt; instruction enforces this replacement policy.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://pipes.yahoo.com/pipes/pipe.info?_id=8785aff3aa03c98595cebec10c198907"&gt;&lt;img src="http://farm3.static.flickr.com/2633/4055011893_27aba6fe82.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;So to recap - we grab a list of webpage URIs fromn the Cambridge Libraries XML feed:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://pipes.yahoo.com/pipes/pipe.info?_id=8785aff3aa03c98595cebec10c198907"&gt;&lt;img src="http://farm3.static.flickr.com/2487/4055755530_5ba4a0c817.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Then we replace those feed items by any and all autodiscovered feed URIs:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://pipes.yahoo.com/pipes/pipe.info?_id=8785aff3aa03c98595cebec10c198907"&gt;&lt;img src="http://farm3.static.flickr.com/2577/4055758450_d6ed6af31d.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;(Who'd have thunk it - &lt;em&gt;Penguin of the Day&lt;/em&gt;;-).&lt;br /&gt;&lt;br /&gt;Note that the pipe also reports on any broken links it finds in the original homepage list:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://pipes.yahoo.com/pipes/pipe.info?_id=8785aff3aa03c98595cebec10c198907"&gt;&lt;img src="http://farm3.static.flickr.com/2588/4055762456_15fdf6037c.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;We can now use this pipe in another pipe that looks at all the autodiscovered feed URIs, pulls the contents of them into a single feed, and then maybe sorts them by date order (as described in &lt;a href="http://arcadiamashups.blogspot.com/2009/10/getting-started-with-yahoo-pipes.html"&gt;Getting Started With Yahoo Pipes: Merging RSS Feeds&lt;/a&gt;):&lt;br /&gt;&lt;br /&gt;&lt;a href="http://pipes.yahoo.com/pipes/pipe.info?_id=e8c3b2eba9673fd9326d3233b046b367"&gt;&lt;img src="http://farm3.static.flickr.com/2727/4055029539_54d9bd5881.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Again, the pipe reports on any feed URLs that appear to be broken:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://pipes.yahoo.com/pipes/pipe.info?_id=e8c3b2eba9673fd9326d3233b046b367"&gt;&lt;img src="http://farm3.static.flickr.com/2518/4055777350_c1dd29df56.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;So there we have it - a pipe that contains the aggregated feed items from the autodiscoverable RSS feeds listed on Cambridge University Library homepages, all powered by a single XML file containing links to the Library homepages.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6260775124375674077-3207044664051068264?l=arcadiamashups.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://arcadiamashups.blogspot.com/feeds/3207044664051068264/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://arcadiamashups.blogspot.com/2009/10/autodiscoverable-rss-feeds-from.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/3207044664051068264'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/3207044664051068264'/><link rel='alternate' type='text/html' href='http://arcadiamashups.blogspot.com/2009/10/autodiscoverable-rss-feeds-from.html' title='Autodiscoverable RSS Feeds From Cambridge Libraries'/><author><name>Tony Hirst</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://farm3.static.flickr.com/2442/4054951897_4f8b714815_t.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6260775124375674077.post-496180005025792020</id><published>2009-10-29T11:25:00.006Z</published><updated>2009-10-29T12:44:43.593Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='pipes'/><title type='text'>Getting Started With Yahoo Pipes: Merging RSS Feeds</title><content type='html'>If you don't already know what RSS is, you may have noticed the folllowing logo appear on different websites, and even within your browser, and never really been sure what it's actually for...&lt;br /&gt;&lt;br /&gt;&lt;img style="width: 180px; height: 180px;" src="http://4.bp.blogspot.com/_587xyqOtXWE/RiMfesrIvgI/AAAAAAAAAGk/uw__4xaZgAg/s400/RSS+Logo.jpg" border="0" alt="" /&gt;&lt;br /&gt;&lt;br /&gt;What it's for is wiring (or plumbing). What it's for is passing content from one web page or application to another. What it's for is never having to visit that web page again to keep up to date with new content that might appear on that web page or website. What it's for is letting you see content from that page or site in another application, such as feed reader like Google Reader, or a 'web desktop/dashboard' like Netvibes, or Google personal pages. What it's for is turning websites into 'not email', that you can subscribe to from a single application and then view updates from in a single location.&lt;br /&gt;&lt;br /&gt;It's also for much more than that, but that's what we'll start with...&lt;br /&gt;&lt;br /&gt;&lt;object width="425" height="344"&gt;&lt;param name="movie" value="http://www.youtube.com/v/0klgLsSxGsU&amp;hl=en&amp;fs=1&amp;"&gt;&lt;/param&gt;&lt;param name="allowFullScreen" value="true"&gt;&lt;/param&gt;&lt;param name="allowscriptaccess" value="always"&gt;&lt;/param&gt;&lt;embed src="http://www.youtube.com/v/0klgLsSxGsU&amp;hl=en&amp;fs=1&amp;" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="344"&gt;&lt;/embed&gt;&lt;/object&gt;&lt;br /&gt;&lt;br /&gt;But that's not what this post is about... What this post &lt;em&gt;is&lt;/em&gt; about is how you can use an online application called &lt;a href="http://pipes.yahoo.com"&gt;Yahoo Pipes&lt;/a&gt; to do all sorts of plumbing with RSS feeds.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://pipes.yahoo.com/"&gt;&lt;img src="http://farm3.static.flickr.com/2645/4055610654_15863499d1.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;To get started, you'll need a Yahoo account, then you can create your first pipe... &lt;br /&gt;&lt;br /&gt;&lt;div&gt;&lt;object width="512" height="322"&gt;&lt;param name="movie" value="http://d.yimg.com/static.video.yahoo.com/yep/YV_YEP.swf?ver=2.2.46" /&gt;&lt;param name="allowFullScreen" value="true" /&gt;&lt;param name="AllowScriptAccess" VALUE="always" /&gt;&lt;param name="bgcolor" value="#000000" /&gt;&lt;param name="flashVars" value="id=13878389&amp;vid=5260536&amp;lang=en-us&amp;intl=us&amp;thumbUrl=http%3A//l.yimg.com/a/p/i/bcst/videosearch/9326/87078068.jpeg&amp;embed=1" /&gt;&lt;embed src="http://d.yimg.com/static.video.yahoo.com/yep/YV_YEP.swf?ver=2.2.46" type="application/x-shockwave-flash" width="512" height="322" allowFullScreen="true" AllowScriptAccess="always" bgcolor="#000000" flashVars="id=13878389&amp;vid=5260536&amp;lang=en-us&amp;intl=us&amp;thumbUrl=http%3A//l.yimg.com/a/p/i/bcst/videosearch/9326/87078068.jpeg&amp;embed=1" &gt;&lt;/embed&gt;&lt;/object&gt;&lt;br /&gt;&lt;a href="http://video.yahoo.com/watch/5260536/13878389"&gt;Learn How to Build a Pipe in Just a Few Minutes&lt;/a&gt; @ &lt;a href="http://video.yahoo.com" &gt;Yahoo! Video&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;It's like Lego, but with bits of web content pulled into the pipe from one or more RSS feeds, with the content packaged up into bundles where each bundle contains:&lt;br /&gt;- a &lt;em&gt;title&lt;/em&gt;;&lt;br /&gt;- some content (like the body of a blog post or news story), referred to as the &lt;em&gt;description&lt;/em&gt;;&lt;br /&gt;- a &lt;em&gt;link&lt;/em&gt; (which is often to the original web page that contains the &lt;em&gt;description&lt;/em&gt;).&lt;br /&gt;&lt;br /&gt;So for example, if we look at the &lt;a href="http://www.lib.cam.ac.uk/toolbox/rss.html"&gt;RSS from Cambridge University Library&lt;/a&gt; web page, we see links to a variety of RSS feeds.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.lib.cam.ac.uk/toolbox/rss.html" title="http://www.lib.cam.ac.uk/toolbox/rss.html by psychemedia, on Flickr"&gt;&lt;img src="http://farm3.static.flickr.com/2752/4055568932_71e419d6f5.jpg" width="500" height="216" alt="http://www.lib.cam.ac.uk/toolbox/rss.html" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;We can pull one or more of these feeds into the pipes environment by creating a new Yahoo pipe and then using the Fetch Feed block from the Sources area of the left hand side bar:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/25451952@N00/4055592368/"&gt;&lt;img src="http://farm3.static.flickr.com/2656/4055592368_57054560f0.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;(Highlighing a block by clicking on it lets you preview the output of that block.)&lt;br /&gt;&lt;br /&gt;We can add combine the output of several feeds simply by adding the URL of each required feed to the Fetch Feed block:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/25451952@N00/4054856103/"&gt;&lt;img src="http://farm3.static.flickr.com/2455/4054856103_b34233098a.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;The order of items in combined feed will be all the items from the last feed in the Fecth Feed block. followed by the items in the feed before it, and so on.&lt;br /&gt;&lt;br /&gt;To order the items in the combination feed by date order, use the 'Sort' block:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/25451952@N00/4055643138/"&gt;&lt;img src="http://farm4.static.flickr.com/3509/4055643138_b7c36bdf2d.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;The field you need to sort on is chosen from the drop down menu - PubDate is the element we want to sort on:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/25451952@N00/4055604214/"&gt;&lt;img src="http://farm3.static.flickr.com/2494/4055604214_f280391226.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;(Wire the blocks together by clicking on the 'output circle' at the bottom of a block and dragging the 'wire' that is produced onto the 'input circle' at the top of the next block.)&lt;br /&gt;&lt;br /&gt;Finally, we need to connect the output block to the pipe to complete it.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/25451952@N00/4054867181/"&gt;&lt;img src="http://farm3.static.flickr.com/2491/4054867181_f7fa8e8502.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;If you run the Pipe, you will see its 'front page':&lt;br /&gt;&lt;br /&gt;&lt;a href="http://pipes.yahoo.com/pipes/pipe.info?_id=744f25ab8e56a478f4a6e77ab9f73177"&gt;&lt;img src="http://farm3.static.flickr.com/2441/4054875391_58666cd393.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;you can now subscribe to the output feed from this pipe (or use it in another pipe...), add it to your Yahoo or Google homepage, and so on.&lt;br /&gt;&lt;br /&gt;There's a lot more you can do with Yahoo Pipes, but this is a good start: being able to &lt;em&gt;aggregate&lt;/em&gt; (that is merge, or combine) content from several different sources into a single feed, and then order them accroding to time.&lt;br /&gt;&lt;br /&gt;So how else might we use this simple 'aggregate and order' pattern?&lt;br /&gt;&lt;br /&gt;How about combining table of contents feeds from different journals (you can find their URIs from &lt;a href="http://www.tictocs.ac.uk/"&gt;TicTocs&lt;/a&gt;?&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/25451952@N00/4055624842/"&gt;&lt;img src="http://farm3.static.flickr.com/2533/4055624842_53c686948b.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;In this way, you can create a single RSS feed that keeps you up to date with the  contents of several different journals you are interested in, and maybe also pulls in content from a recent/new books feed from your Library?&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6260775124375674077-496180005025792020?l=arcadiamashups.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://arcadiamashups.blogspot.com/feeds/496180005025792020/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://arcadiamashups.blogspot.com/2009/10/getting-started-with-yahoo-pipes.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/496180005025792020'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/496180005025792020'/><link rel='alternate' type='text/html' href='http://arcadiamashups.blogspot.com/2009/10/getting-started-with-yahoo-pipes.html' title='Getting Started With Yahoo Pipes: Merging RSS Feeds'/><author><name>Tony Hirst</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_587xyqOtXWE/RiMfesrIvgI/AAAAAAAAAGk/uw__4xaZgAg/s72-c/RSS+Logo.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6260775124375674077.post-2385311161210726142</id><published>2009-10-26T10:38:00.003Z</published><updated>2009-10-26T10:38:13.004Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='bookmarklet'/><title type='text'>The 'Get Selection' Bookmarklet Pattern</title><content type='html'>In &lt;a href="http://arcadiamashups.blogspot.com/2009/10/introduction-to-bookmarklets.html"&gt;An Introduction to Bookmarklets&lt;/a&gt;, I introduced the idea of a bookmarklet, a browser based bookmark that lets you execute a small Javascript programme in the context of the currently displayed web page, rather than taking you to a bookmarked page.&lt;br /&gt;&lt;br /&gt;This was followed by &lt;a href="http://arcadiamashups.blogspot.com/2009/10/get-current-url-bookmarklet-pattern.html"&gt;The 'Get Current URL' Bookmarklet Pattern&lt;/a&gt;, which descrbed how to create a bookmarklet that would operate on the URI of the currently viewed page, within a generic bookmarklet wrapper.&lt;br /&gt;&lt;br /&gt;In this post, I'll provide an example of a bookmarklet pattern that passes some highlighted (that is, selected) text within the current page and passes it to another web page.&lt;br /&gt;&lt;br /&gt;In Firefox and Safari web browsers, we can straightforwardly use the javascript function &lt;em&gt;window.getSelection()&lt;/em&gt; to grab any selected text in the web page. (You can select text in the normal way - click the cursor on the page at the start of the text you want to select, then drag over the text you want to highlight).&lt;br /&gt;&lt;br /&gt;In at least some versions of IE, we need to use the construction &lt;em&gt;document.selection.createRange().text&lt;/em&gt;.&lt;br /&gt;&lt;br /&gt;These two can be combined in a javascript construction that looks to see &lt;em&gt;if&lt;/em&gt; (?) the first construction is available, and if not, &lt;em&gt;then&lt;/em&gt; (:) uses the second:&lt;br /&gt;&lt;em&gt;window.getSelection?window.getSelection():document.selection.createRange().text;&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;To see how this works, highlight some text on this page and then &lt;a href='javascript:(function(){var t=window.getSelection?window.getSelection().toString():document.selection.createRange().text;t="You selected: "+t; alert (t);})()'&gt;click here&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;Here is an example that achieves that effect:&lt;br /&gt;&lt;em&gt;Highlight some text and &lt;a href='javascript:(function(){var t=window.getSelection?window.getSelection().toString():document.selection.createRange().text;t="You selected: "+t; alert (t);})()'&gt;click here&lt;/a&gt;.&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;So how might we use this in practice? How about DOI resolution? (If you don't know about DOIs, they're &lt;em&gt;D&lt;/em&gt;igital &lt;em&gt;O&lt;/em&gt;bject &lt;em&gt;I&lt;/em&gt;dentifiers - so go Google.. ;-)&lt;br /&gt;&lt;br /&gt;DOIs typically look something like this: &lt;em&gt;doi:10.1016/S0040-1625(03)00072-6&lt;/em&gt;. A long string of characters (in various formats depending on publisher), often prefixed by &lt;em&gt;doi:&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;A DOI can point to one or more instances of a document. A DOI resolver will take a DOI and point you to an instance of it depending on various criteria. (In a library setting, this might depend on what online resources your library subscribes to.)&lt;br /&gt;&lt;br /&gt;So for example, let's see what the DOI resolver at &lt;em&gt;http://dx.doi.org/&lt;/em&gt; can do with the DOI &lt;em&gt;10.1016/S0040-1625(03)00072-6&lt;/em&gt;...&lt;br /&gt;&lt;br /&gt;You can call the resolver with the DOI in the following way:&lt;br /&gt;&lt;em&gt;http://dx.doi.org/doi:&lt;strong&gt;THE-DOI_YOU/WANT:RESOLVING&lt;/strong&gt;&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;Try it: &lt;a href="http://dx.doi.org/doi:10.1016/S0040-1625(03)00072-6"&gt;http://dx.doi.org/doi:10.1016/S0040-1625(03)00072-6&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Hopefully, you might now see an opportunity here for a bookmarklet that uses the 'getSelection' pattern? In particular, a bookmarklet that lets a user highlight a DOI and then click on the bookmarklet to resolve that DOI.&lt;br /&gt;&lt;br /&gt;Using the &lt;em&gt;window.location=&lt;strong&gt;NEWURL&lt;/strong&gt;&lt;/em&gt; trick that we saw in the &lt;a href="http://arcadiamashups.blogspot.com/2009/10/get-current-url-bookmarklet-pattern.html"&gt;The 'Get Current URL' Bookmarklet Pattern&lt;/a&gt;, we can construct just such a bookmarklet.&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Grab the selected text (hopefully corresponding a valid DOI!;-): &lt;em&gt;var t=window.getSelection?window.getSelection().toString():document.selection.createRange().text;&lt;/em&gt;&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Construct a URI that will pass this DOI to the DOI resolver: &lt;em&gt;var uri="http://dx.doi.org/doi:"+t;&lt;/em&gt;&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Go to this URI, and as a result get redirected to an instance of the actual resource: &lt;em&gt;window.location=uri;&lt;/em&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;We can then simplify this as follows:&lt;br /&gt;&lt;em&gt;var t=window.getSelection?window.getSelection().toString():document.selection.createRange().text; window.location="http://dx.doi.org/doi:"+t;&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;And pop it into our generic bookmarklet wrapper:&lt;br /&gt;&lt;em&gt;javascript:(function(){var t=window.getSelection?window.getSelection().toString():document.selection.createRange().text; window.location="http://dx.doi.org/doi:"+t;})()&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;Try it - select this DOI (just the numbers... no leading doi:): &lt;em&gt;10.1016/S0040-1625(03)00072-6&lt;/em&gt; and then click on this &lt;a href='javascript:(function(){var t=window.getSelection?window.getSelection().toString():document.selection.createRange().text;window.location="http://dx.doi.org/doi:"+t;})()'&gt;DOI Resolver bookmarklet&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;Here's a tool for helping generate your own bookmarklets using the 'get selection' pattern:&lt;br /&gt;&lt;br /&gt;&lt;form&gt;Bookmarklet name: &lt;input type='text' size='30' value='Resolve DOI' id='gselbmn'/&gt;&lt;br/&gt;&lt;br /&gt;&lt;strong&gt;javascript:(function(){var t=window.getSelection?window.getSelection().toString():document.selection.createRange().text;window.location='&lt;/strong&gt;&lt;input type='text' size='50' value='http://dx.doi.org/doi:' id='gselbmg'/&gt;&lt;strong&gt;'+t;})()&lt;/strong&gt; &lt;input type='button' value='Generate bookmarklet' onclick="javascript:function generateGetSelBM(u){var o=document.getElementById('gselbm');var a=document.createElement('a');var t='javascript:(function(){var t=window.getSelection?window.getSelection().toString():document.selection.createRange().text;window.location=\''+u+'\'+t;})()'; a.setAttribute('href',t);a.innerHTML=document.getElementById('gselbmn').value;o.appendChild(a);} generateGetSelBM(document.getElementById('gselbmg').value)"/&gt;&lt;/form&gt;&lt;br /&gt;&lt;br /&gt;&lt;div&gt;Your bookmarklet: &lt;span id='gselbm'&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;PS If you leave the space for the URI blank, you can generate a bookmarklet that will let you highlight an unlinked URI in a webpage, like the following one:&lt;br /&gt;&lt;em&gt;http://arcadiaproject.blogspot.com&lt;/em&gt;&lt;br /&gt;and 'click through' it (via the bookmarklet) to the corresponding webpage...&lt;br /&gt;&lt;br /&gt;PPS in some situations, it might be sensible to 'go defensive' and encode the selected text so that it works nicely in a URI. do this by adding the step:&lt;br /&gt;&lt;em&gt;t=encodeURIComponent(t);&lt;/em&gt;&lt;br /&gt;before the &lt;em&gt;window.location&lt;/em&gt; step.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6260775124375674077-2385311161210726142?l=arcadiamashups.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://arcadiamashups.blogspot.com/feeds/2385311161210726142/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://arcadiamashups.blogspot.com/2009/10/get-selection-bookmarklet-pattern.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/2385311161210726142'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/2385311161210726142'/><link rel='alternate' type='text/html' href='http://arcadiamashups.blogspot.com/2009/10/get-selection-bookmarklet-pattern.html' title='The &apos;Get Selection&apos; Bookmarklet Pattern'/><author><name>Tony Hirst</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6260775124375674077.post-6269755764471790709</id><published>2009-10-21T18:37:00.002+01:00</published><updated>2009-10-21T19:25:43.233+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='bookmarklet'/><title type='text'>The 'Get Current URL' Bookmarklet Pattern</title><content type='html'>In &lt;a href="http://arcadiamashups.blogspot.com/2009/10/introduction-to-bookmarklets.html"&gt;An Introduction to Bookmarklets&lt;/a&gt;, I introduced the idea of a &lt;em&gt;bookmarklet&lt;/em&gt;, a browser based bookmark that lets you execute a small Javascript programme in the context of the currently displayed web page, rather than taking you to a bookmarked page.&lt;br /&gt;&lt;br /&gt;In this post, I'll provide an example of a bookmarklet pattern that passes the URL of the current page to another web page.&lt;br /&gt;&lt;br /&gt;To show you the effect of the bookmark, click here: &lt;a href='javascript:window.location="http://bigtiny.ecs.soton.ac.uk?mode=qrcode&amp;url="+encodeURIComponent(window.location.href);'&gt;see what happens&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;What you should find is that the URI of the current page is passed to the SplashURL service, which displays a short URL code, and a QR code, that both point back to this page.&lt;br /&gt;&lt;br /&gt;If you click through on the link above and look at the URI of the page that is loaded, you will see that it has the form:&lt;br /&gt;&lt;br /&gt;&lt;em&gt;http://splashurl.net/?mode=qrcode&amp;url=&lt;strong&gt;a_version_of_the_uri_of_this_page&lt;/strong&gt;&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;What the link above did - and what a bookmarklet can do, is the following:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;look up the URI of the current page using the Javascript 'command' &lt;em&gt;window.location.href&lt;/em&gt;;&lt;/li&gt;&lt;br /&gt;&lt;li&gt;encode this URI so that it can be used in another URI: &lt;em&gt;encodeURIComponent(window.location.href)&lt;/em&gt;;&lt;/li&gt;&lt;br /&gt;&lt;li&gt;use this encoded version of the URI of the current page in the SplashURL URI:&lt;br /&gt;&lt;em&gt;var newURI="http://bigtiny.ecs.soton.ac.uk?mode=qrcode&amp;url="+encodeURIComponent(window.location.href);&lt;/em&gt;&lt;/li&gt;&lt;br /&gt;&lt;li&gt;reload the current window with this new URI: &lt;em&gt;window.location=newURI;&lt;/em&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;That gives us the following Javascript code snippet:&lt;br /&gt;&lt;em&gt;var newURI="http://bigtiny.ecs.soton.ac.uk?mode=qrcode&amp;url="+encodeURIComponent(window.location.href);window.location=newURI;&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;We can actually write this in a simplified form where we do not create the &lt;em&gt;newURI&lt;/em&gt; variable at all. Instead, we simply change the location of the current window to the new URI:&lt;br /&gt;&lt;em&gt;window.location="http://bigtiny.ecs.soton.ac.uk?mode=qrcode&amp;url="+encodeURIComponent(window.location.href);&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;To use this code in a bookmarklet, or in a web page link*, we need to identify this code snippet as Javascript:&lt;br /&gt;&lt;em&gt;&lt;strong&gt;javascript:&lt;/strong&gt;var newURI="http://bigtiny.ecs.soton.ac.uk?mode=qrcode&amp;url="+encodeURIComponent(window.location.href);window.location=newURI;&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;[* note that some web publishing platforms will strip javascript code out of a link - Blogger is kind enough to leave it in.]&lt;br /&gt;&lt;br /&gt;We might also take a precautionary step of making sure that the program code in the bookmarklet does not conflict with any javscript code already present in the current page:&lt;br /&gt;&lt;em&gt;javascript:&lt;strong&gt;(function(){&lt;/strong&gt;var newURI="http://bigtiny.ecs.soton.ac.uk?mode=qrcode&amp;url="+encodeURIComponent(window.location.href);window.location=newURI;&lt;strong&gt;})()&lt;/strong&gt;&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;Here's the bookmarklet: &lt;a href='javascript:(function(){window.location="http://bigtiny.ecs.soton.ac.uk?mode=qrcode&amp;url="+encodeURIComponent(window.location.href);})()'&gt;SplashQR&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;That is, we wrap our program snippet in the following:&lt;br /&gt;&lt;em&gt;javascript:(function(){&lt;strong&gt;Javascript bookmarklet program code here&lt;/strong&gt;})()&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;(To 'install' it on your Firefox or Safari browser, simply drag the link to the bookmarks toolbar. In IE, right click on the link and add to Favourites/Links, then in the View-&gt;Toolbar menu option of your browser, make sure the Link Toolbar is ticked.)&lt;br /&gt;&lt;br /&gt;So now we have a pattern for creating bookmarklets that can pass the URI of the current page to another page. So if you see web service that includes the URI of another page in its URI, you can write a bookmarklet to invoke that service on a web page you are currently viewing.&lt;br /&gt;&lt;br /&gt;Here's a simple form to help you generate this sort of bookmarklet:&lt;br /&gt;&lt;br /&gt;&lt;form&gt;Bookmarklet name: &lt;input type='text' size='12' value='SplashQR' id='gurlbmn'/&gt;&lt;br/&gt;&lt;strong&gt;javascript:(function(){window.location='&lt;/strong&gt;&lt;input type='text' size='50' value='http://bigtiny.ecs.soton.ac.uk?mode=qrcode&amp;url=' id='gurlbmg'/&gt; &lt;strong&gt;'+encodeURIComponent(window.location.href);})()&lt;/strong&gt;&lt;br/&gt;&lt;input type='button' value='Generate bookmarklet' onclick="javascript:function generateGetUrlBM(u){var o=document.getElementById('gurlbm');var a=document.createElement('a');var t='javascript:(function(){window.location=\''+u+'\'+encodeURIComponent(window.location.href);})()'; a.setAttribute('href',t);a.innerHTML=document.getElementById('gurlbmn').value;;o.appendChild(a);} generateGetUrlBM(document.getElementById('gurlbmg').value)"/&gt;&lt;/form&gt;&lt;br /&gt;&lt;br /&gt;&lt;div&gt;Your bookmarklet: &lt;span id='gurlbm'&gt;&lt;/span&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;If you come across any web page/services that include another URI in their URI, particularly in the context of academic, public, legal, governmental, medical or corporate libraries, please post an example, along with a description of what the page does, in the comments below.&lt;br /&gt;&lt;br /&gt;In the next post in this series, I'll review how to create a bookmarklet that acts on a piece of text that is highlighted/selected by the user within the current page.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6260775124375674077-6269755764471790709?l=arcadiamashups.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://arcadiamashups.blogspot.com/feeds/6269755764471790709/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://arcadiamashups.blogspot.com/2009/10/get-current-url-bookmarklet-pattern.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/6269755764471790709'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/6269755764471790709'/><link rel='alternate' type='text/html' href='http://arcadiamashups.blogspot.com/2009/10/get-current-url-bookmarklet-pattern.html' title='The &apos;Get Current URL&apos; Bookmarklet Pattern'/><author><name>Tony Hirst</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6260775124375674077.post-7827013344137263389</id><published>2009-10-07T10:47:00.001+01:00</published><updated>2009-11-02T16:42:14.796Z</updated><category scheme='http://www.blogger.com/atom/ns#' term='bookmarklet'/><title type='text'>An Introduction to Bookmarklets</title><content type='html'>One of the expected deliverables from my time on the &lt;a href="http://arcadiaproject.lib.cam.ac.uk/index.html"&gt;Arcadia Project&lt;/a&gt; is a set of posts on different mashup design patterns and implementation patterns that can act as Quick Start tricks and tips for anyone who wants to get started with producing &lt;em&gt;ad hoc&lt;/em&gt;, itch scratching and potentially one-shot/disposable applications (that is, lightweight tools put together for a particular task that may or may not ever be useful again...)&lt;br /&gt;&lt;br /&gt;On the implementation side, the &lt;em&gt;bookmarklet&lt;/em&gt; approach is one I use extensively, so I thought it might be an idea to introduce the idea of bookmarklets, and then describe over a series of posts a set simple reusable patterns that I return to again and again, as well as a set of bookmarklet generators to get you started created your own bookmarklets.&lt;br /&gt;&lt;br /&gt;So - what is a &lt;em&gt;bookmarklet&lt;/em&gt;? In practical terms, a bookmarklet is a button that you can add to your browser that extends the functionality of the browser, or a web page displayed in it. But before we see how bookmarklets work, let's take a step back and look at the anatomy of a web browser for a moment. I'm using the Firefox browser for the screenshots and screencasts/videos, but a similar approach is used in other browsers too:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/25451952@N00/3989184443/"&gt;&lt;img src="http://farm3.static.flickr.com/2583/3989184443_40d659f7c0.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;At the top of the screen is a location, or address bar. This is where you can type the URL of a website you want to visit. Whenever you view a web page, its URL will appear in the location bar. So if you click a link on a Google results page to a BBC webpage, for example, when you view the BBC page it's URL will be displayed in the location bar.&lt;br /&gt;&lt;br /&gt;Below the location bar is a Bookmark (or Favorites) toolbar. You can typically hide (or reveal) this toolbar via the browser View menu:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/25451952@N00/3989947546/"&gt;&lt;img src="http://farm4.static.flickr.com/3421/3989947546_eb3766fc48.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;The Bookmark toolbar is a place where you can add your own links (that look like buttons) to the browser. They are bit like shortcuts to application that you might place on a Windows desktop. So if you visit the same two or three websites regularly, adding a bookmark to them can save you time. In the above screenshot, I have a bookmark to &lt;em&gt;Camtools&lt;/em&gt; and the &lt;em&gt;Hermes Webmail&lt;/em&gt; system, for example.&lt;br /&gt;&lt;br /&gt;Adding a bookmark to the toolbar is easy, and there are &lt;a href="http://www.youtube.com/watch?v=4e-BBbnBDBc"&gt;several ways to do it&lt;/a&gt; which all work, to a greater or lesser extent, in most of the popular web browsers (Internet Explorer, Firefox, Safari, and so on):&lt;br /&gt;&lt;br /&gt;&lt;object width="425" height="344"&gt;&lt;param name="movie" value="http://www.youtube.com/v/4e-BBbnBDBc&amp;hl=en&amp;fs=1&amp;"&gt;&lt;/param&gt;&lt;param name="allowFullScreen" value="true"&gt;&lt;/param&gt;&lt;param name="allowscriptaccess" value="always"&gt;&lt;/param&gt;&lt;embed src="http://www.youtube.com/v/4e-BBbnBDBc&amp;hl=en&amp;fs=1&amp;" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="344"&gt;&lt;/embed&gt;&lt;/object&gt;&lt;br /&gt;&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Right click on a link on a webpage, then select 'Bookmark [Favorite] this page' (or something similar!). You may need to select the location for where you want the store the bookmark - look for the &lt;em&gt;toolbar&lt;/em&gt; option.&lt;/li&gt;&lt;li&gt;Drag a link from the page and just drop it on the toolbar.&lt;/li&gt;&lt;li&gt;Drag the page icon from the location bar at the top of the page and then drop it onto the toolbar.&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;&lt;br /&gt;Okay, so that's &lt;em&gt;bookmarks&lt;/em&gt;; but what about bookmark&lt;em&gt;lets&lt;/em&gt;?&lt;br /&gt;&lt;br /&gt;Bookmarklets are mini-programmes that you can run from the browser bookmark toolbar. As programmes, they can take things like the URL of the currently displayed webpage and make use of them in some way, or they can be used to modify the contents of the currently displayed webpage.&lt;br /&gt;&lt;br /&gt;So for example, the following 'Split screen bookmarklet' takes the URL of the current page and loads it into two separate frames, to make it easier to take screen grabs of a web page where you want to capture two different areas of the same page in the same screenshot:&lt;br /&gt;&lt;br /&gt;&lt;object width="425" height="344"&gt;&lt;param name="movie" value="http://www.youtube.com/v/11D3vCad7dY&amp;hl=en&amp;fs=1&amp;"&gt;&lt;/param&gt;&lt;param name="allowFullScreen" value="true"&gt;&lt;/param&gt;&lt;param name="allowscriptaccess" value="always"&gt;&lt;/param&gt;&lt;embed src="http://www.youtube.com/v/11D3vCad7dY&amp;hl=en&amp;fs=1&amp;" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="344"&gt;&lt;/embed&gt;&lt;/object&gt;&lt;br /&gt;&lt;br /&gt;Alternatively, the 'Newton QR Code' bookmarklet will add a QRcode (2D barcode) to a results page on the Newton Library Catalogue:&lt;br /&gt;&lt;br /&gt;&lt;object width="425" height="344"&gt;&lt;param name="movie" value="http://www.youtube.com/v/8v2h-vKTXwc&amp;hl=en&amp;fs=1&amp;"&gt;&lt;/param&gt;&lt;param name="allowFullScreen" value="true"&gt;&lt;/param&gt;&lt;param name="allowscriptaccess" value="always"&gt;&lt;/param&gt;&lt;embed src="http://www.youtube.com/v/8v2h-vKTXwc&amp;hl=en&amp;fs=1&amp;" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="344"&gt;&lt;/embed&gt;&lt;/object&gt;&lt;br /&gt;&lt;br /&gt;So how does a bookmarklet differ from bookmark in practical terms? Let's look at the properties of a bookmark (in Firefox, you can do this by right-cliking on a bookmark and selecting the &lt;em&gt;Properties&lt;/em&gt; menu option).&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/psychemedia/3989241307/" title="Bookmark properties by psychemedia, on Flickr"&gt;&lt;img src="http://farm4.static.flickr.com/3493/3989241307_a3a0064519_o.png" width="333" height="230" alt="Bookmark properties" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;You'll see theire's just the descriptive text that appears as the button label on the toolbar, and the URL of the bookmarked page.&lt;br /&gt;&lt;br /&gt;Here's what a bookmarklet looks like:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/25451952@N00/3990003322/"&gt;&lt;img src="http://farm4.static.flickr.com/3501/3990003322_3aece8c0b4.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;The link, rather than starting with &lt;em&gt;http://&lt;/em&gt;, starts with &lt;em&gt;javascript:&lt;/em&gt; and is then followed by some javascript program code. When you click on the bookmarklet button, this mini-javascript programme will be run. Note that the bookmarklet should only be able to 'see' things in the current page, so if you have multiple tabs open in your browser, clicking on a bookmarklet should only affect the current page you are on.&lt;br /&gt;&lt;br /&gt;Okay - so that's a quick intro to bookmarklets. In the next post in this series, I'll review some typical bookmarklet 'patterns', as well as the anatomy of a bookmarklet, before getting into some worked examples of how to create your own bookmarklets.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6260775124375674077-7827013344137263389?l=arcadiamashups.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://arcadiamashups.blogspot.com/feeds/7827013344137263389/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://arcadiamashups.blogspot.com/2009/10/introduction-to-bookmarklets.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/7827013344137263389'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/7827013344137263389'/><link rel='alternate' type='text/html' href='http://arcadiamashups.blogspot.com/2009/10/introduction-to-bookmarklets.html' title='An Introduction to Bookmarklets'/><author><name>Tony Hirst</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://farm3.static.flickr.com/2583/3989184443_40d659f7c0_t.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6260775124375674077.post-6248480660893252214</id><published>2009-10-01T15:18:00.000+01:00</published><updated>2009-10-01T17:47:09.823+01:00</updated><title type='text'>Visual Links - Sharing Links With QR Codes</title><content type='html'>When I had my first look at the Cambridge University Library online catalogue yesterday, I hadn't yet sorted out my computer credentials so I was limited to using the system in a personally stateless way using public terminals.&lt;br /&gt;&lt;br /&gt;Some of the links I tried to follow were also blocked (they were trying to go outside the local subdomain, I guess), but they might have been useful and if the opportunity had allowed I might have bookmarked them.&lt;br /&gt;&lt;br /&gt;So pondering this, and as a starter for ten, are there any easy takeaways for the casual, non-authenticated user to capture information relating to a particular results page using some sort of mobile device, such as a pencil'n'paper device, or a mobile phone (not that cameras are allowed in the library...)?&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/25451952@N00/3971242063/"&gt;&lt;img src="http://farm3.static.flickr.com/2643/3971242063_2d1eacb771.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;I spy one - there's a shortcode possibility in the 'Link to this record' URL, I think? &lt;em&gt;ul-4528529&lt;/em&gt; looks like it could be a handy shortcode to me?&lt;br /&gt;&lt;br /&gt;&lt;form&gt;&lt;input type='text' value='ul-4528529' id='libshortcode'/&gt; &lt;input type='button' value='Resolve it..' onclick="javascript:function arcadia_resolve(t){t=t.split('-');window.location='http://hooke.lib.cam.ac.uk/cgi-bin/bib_seek.cgi?cat='+t[0]+'&amp;bib='+t[1];} arcadia_resolve(document.getElementById('libshortcode').value)"/&gt;&lt;/form&gt;&lt;br /&gt;&lt;br /&gt;So if a 'Catalogue shortcode' was published on each page:&lt;br /&gt;&lt;br /&gt;&lt;em&gt;Catalogue shortcode: &lt;strong&gt;ul-4528529&lt;/strong&gt;&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;with an easy to find resolver somewhere (the form above works as a stop gap), it's easy enough to scribble down a shortcode for a book's results page on the library catalogue:-)&lt;br /&gt;&lt;br /&gt;For getting that link onto a phone, a QR-code would be another possibility. Here's what the page might look like:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/25451952@N00/3971408235/"&gt;&lt;img src="http://farm3.static.flickr.com/2595/3971408235_f7e53359b2.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;To try a similar effect out yourself, add the following bookmarklet to you browser toolbar... (just click and drag it onto your browser bookmarks toolbar in Firefox/Safari, or right click on it and select 'Add to Favorites' in IE/Internet Explorer.)&lt;br /&gt;&lt;br /&gt;&lt;a href="javascript:(function(){var u=window.getSelection();var d=document;var g=d.getElementById('googleBooksRow');var t='http://chart.apis.google.com/chart?chs=150x150&amp;cht=qr&amp;chl=';t+=encodeURIComponent(u);var i=d.createElement('img');i.setAttribute('src',t);g.appendChild(i);})()"&gt;Newton  QR code&lt;/a&gt; (uses Google visulisation API QR code generator)&lt;br /&gt;&lt;br /&gt;...go to a results page, highlight the link and then click on the bookmarklet:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.flickr.com/photos/25451952@N00/3972181742/"&gt;&lt;img src="http://farm3.static.flickr.com/2607/3972181742_77d1e7bf8a.jpg" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;It also strikes me that a really useful generic tool that could be implemented on public terminals using a browser extension would be a right-click menu option offering to &lt;em&gt;Display this link as a QR-code&lt;/em&gt;...?&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6260775124375674077-6248480660893252214?l=arcadiamashups.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://arcadiamashups.blogspot.com/feeds/6248480660893252214/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://arcadiamashups.blogspot.com/2009/10/visual-links-sharing-links-with-qr.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/6248480660893252214'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6260775124375674077/posts/default/6248480660893252214'/><link rel='alternate' type='text/html' href='http://arcadiamashups.blogspot.com/2009/10/visual-links-sharing-links-with-qr.html' title='Visual Links - Sharing Links With QR Codes'/><author><name>Tony Hirst</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='http://img2.blogblog.com/img/b16-rounded.gif'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://farm3.static.flickr.com/2643/3971242063_2d1eacb771_t.jpg' height='72' width='72'/><thr:total>0</thr:total></entry></feed>
