Access Keys:
Skip to content (Access Key - 0)
My Area (Access Key - 2)


Toggle Sidebar
Your Rating: Results: PatheticBadOKGoodOutstanding! 1 rates

Labels

elympics elympics Delete
moodle moodle Delete
interface interface Delete
open open Delete
xml xml Delete
feed feed Delete
atom atom Delete
rss rss Delete
intermediate intermediate Delete
perl perl Delete
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.

Issued items as RSS or RSS-ATOM feed

Tags: , , , , , , , , ,
Last Updated: Dec 21, 2009 23:54


Description
Using the same criteria as we use for someone to log into MyAccount, I have created a CGI script which will display someone's issued items as an RSS/ATOM feed.

At UCOL, we also issue the New Resources to a New Books Display "patron", so this feed can be used easily for special patrons too, with a little editing once you've found out the patron id for the "patron" you want to display - you can do this using the Voyager Circulation client. This is done at about line 44 in each script, which you can then use to hard-code the script, and rename to generate the rss feed on the fly - here's a working example (which doesn't use the Voyager webservice):

http://libcat.ucol.ac.nz/vwebv/pn_newresources_rss.cgi

Another option would be to edit the scripts so they could be sheduled/cron.d to produce the RSS feeds as files for less server-intensive work.


Author: Tom Pasley
Institution: UCOL Library
Year: 2009


License: BSD style
Short description: Use, modification and distribution of the code are permitted provided the copyright notice, list of conditions and disclaimer appear in all related material.
Link to terms: [Detailed license terms]


Skill required for using this code:

  • intermediate

State

Either 'Stable' or 'In Development', depending on what voters think!

Programming language

Perl

Software requirements

Most of the required modules should be present on a Voyager server.

Screen captures

This is the RSS feed, as displayed using Sage, a Firefox add-on.

Download

issued_items_atom.cgi

Working example

http://libcat.ucol.ac.nz/vwebv/issued_items_rss.cgi?patronbarcode=31232&lastname=Pasley

http://libcat.ucol.ac.nz/vwebv/issued_items_atom.cgi?patronbarcode=31232&lastname=Pasley

Using the following Ex Libris open interfaces

Voyager AuthenticatePatronService to obtain the patron_id.

Changes

Release notes

Original release.

Uses lots of code borrowed from Michael Doran's New Books scripts.

Hopefully this is also an "open" interface which can be used by benign 'bots, and included in products such as Moodle (using a modified RSS module, after accessing the $USER object to derive the RSS url).

URL is server location/issued_items_rss.cgi?patronbarcode=libraryid&lastname=lastname

URL is server location/issued_items_atom.cgi?patronbarcode=libraryid&lastname=lastname

Installation instructions

Edit the script using something like Notepad++

Place this script(s) in a valid cgi-enabled directory on a server, using FTP or whatever works!

Using a telnet terminal, use this as the voyager user to make the cgi scripts executable:

chmod +x issued_items_rss.cgi
chmod +x issued_items_atom.cgi

If your Voyager installation is running Michael Doran's New Books list, then put this cgi script in the same directory as "newBooks.cgi" once configured.

Make sure you link to the RSS or Atom feed so it will be used!

TO DO list

Possibly add a parameter to allow the client to specify the image size used?

No support for internationalisation - though could be edited manually.

Known issues

A bit slooow on our server, but your mileage might vary!

I have verified the outputs as proper RSS and RSS/ATOM at http://feedvalidator.org


Comments

Text...


Page Attachments

File NameCommentSizeNumber of Downloads
issued_items_atom.cgi14 kB80
issued_items_rss.cgi13 kB61

Added by Tom Pasley on Dec 16, 2009 03:04, last edited by Tom Pasley on Dec 21, 2009 23:54

Adaptavist Theme Builder Powered by Atlassian Confluence