The Mnemosyne-Atlas: adding Pinterest to the library catalogue.

Why pinterest?

Last week I attended a talk by Phil Bradley at the Cilip in London AGM (a podcast of this talk Around the World on a Library Degree is available). Phil pointed out Pinterest as a particularly useful and interesting site to watch. I had not heard of this before so registered an account. Shortly after I noticed the Pinterest implementation at Darien Library.

Pinterest is a social networking site for sharing photos. Users organise items of media on boards – typically thematically or for a particular event.

I was immediately struck by the appearance of a full pinboard, it made me think of Aby Warburg’s Mnemosyne-Atlas. The Mnemosyne-Atlas was Warburg’s unfinished work, a series of plates (or boards) showing images from the classical period to Warburg’s present time. Alongside classical and renaissance images it included photographs, maps, woodcuts, advertisements, fragments of text, posters, and so on – all kinds of visual media. Warburg intended the boards to be accompanied by commentaries, but these were incomplete on his death in 1929 and only fragments exist.

Taken as a whole it is a summary of all of Warburg’s various interests. It has been compared with avant-garde photo montages in form but is something more, perhaps even a “visual archive of European cultural history” (Rampley, 1999). A photograph from an exhibition of Mnemosyne-Atlas plates is shown above. This is from a set on Flickr called aby warburg – the mnemosyne atlas.

Without expecting every user to be a scholar and cultural theorist of Warburg’s stature, I think there is value in supporting linking our catalogue records to Pinterest as it will allow users to relate them to other images and construct different meanings from them.  I feel it’s especially appropriate for Senate House Libraries which includes the library of the The Warburg Institute.

What is different about Pinterest is it makes creation of ‘vision boards’ easy – many sites now support pinning an image to Pinterest, and there are smartphone apps allowing you to pin anything you can photograph.

How to do this in Encore

At Senate House Libraries we have testing a beta version of the next release of our next-generation catalogue (or discovery interface), Encore. Caution! Everything described below links to a beta version of our catalogue that is not yet finished.

Adding a “Pin It” button is made possible by the ability to insert your own Javascript on the bibliographic record display of the new version of the catalogue. To be able to pin a catalogue record to a Pinterest board at minimum we need an image and a link to associate with it; a description of the image is optional. In this case the image is of the book jacket.

Here’s the Javascript to accomplish this, mind any line wrapping and WordPress oddness if you copy and paste it – file also available on Pastebin.

<script src="//s7.addthis.com/js/250/addthis_widget.js" type="text/javascript"></script>
<script type="text/javascript">
(function() {
var azImageDiv = document.getElementById("imageAnyComponent_0");
if (azImageDiv) {
if (azImageDiv.width>1 && azImageDiv.height>1) {
// key is a variable Encore uses for checking Google Books. It contains 'ISBN:' plus an ISBN10.
var azAsin = key.substring(5);
var pinterestDiv=document.createElement('div');
pinterestDiv.innerHTML = '<span class="bibInfoHeader">Pinterest</span><div class="addthis_toolbox addthis_default_style" ><p>' + '<a class="addthis_button_pinterest" pi:pinit:url="https://encore.ulrls.lon.ac.uk/iii/encore42/record/C__R' + recordid + '" pi:pinit:media="' + 'http://images-eu.amazon.com/images/P/' + azAsin + '.01._SCLZZZZZZZ_.jpg"' + ' pi:pinit:layout="horizontal"</a></div>';
document.getElementById("customBottom").appendChild(pinterestDiv);
}
}
})();
</script>

Commentary

The challenge is to ensure we only render the Pin It button when we’re confident we have a book jacket image.

First step is to get the imageAnyComponent_0 div and check the size. This div contains the jacket image on Encore and is put there by the catalogue. Amazon returns a 1×1 pixel GIF if it has no jacket to offer, so if the image is larger than this it is probably a jacket image. Having the image is key: if we don’t have it we render nothing.

Assuming we have a jacket image I use the Add This to insert a Pinterest button which will pin a larger version of the jacket image and a link to the catalogue. Add This makes it very easy to deal with various social media buttons with minimal effort, plus it includes analytics information allowing us to judge use of these services on the catalogue. I recommend it.

Getting the ISBN turned out to be easy as the vendor’s Javascript for checking for Google Books previews already declares a variable key containing ‘ISBN:’ plus the ISBN-10 of the book.

Result

Here is how the the Pin It button appears in Encore:

If you use the Pin It button, it results in the creation of a pin like this, which can be found on my (testing!) board Catalog records from@SenateHouseLib:

Problems

I think this is a satisfactory start: comments, improvements and criticism welcome (but especially improvements).

First problem is Add This doesn’t seem to support passing a description for the pinned item. To make sharing as “frictionless” as possible I wanted to the add part of the page title as a description, for example: Senate House Libraries — Love is a dog from hell : poems, 1974-1977 / Charles Bukowski would be fine, and the Pinterest user can edit this during pinning. I added this manually to my pin above. Based on the syntax for the other options above it should be: pi:pinit:description=”description” but that doesn’t work.

Second problem is Amazon images doesn’t support ISBN-13, only ISBN-10. However the Encore catalogue will use the first ISBN that appears in the catalogue record which might be an ISBN-13. Converting from ISBN-13 to ISBN-10 is not a complete solution as although you could pin the item, you won’t see the jacket image in the catalogue in the first place.

Photo credit

Mnemosyne-Atlas boards photographed by Flirck user dzsil, license CC BY-SA.

References

Rampley, M. (1999). ‘Archives of memory: Walter Benjamin’s Arcades project and Aby Warburg’s Mnemosyne Atlas’, in Coles, A. (ed.) The optic of Walter Benjamin. London: Black Dog, pp. 94-119.