2/27/2005

amazon2melvyl

Filed under: library, tools — ryan @ 5:08 pm

Yesterday I was perusing my Amazon wishlist, looking up the books I have bookmarked there on Melvyl, the combined UC Libraries catalog. The cutting and pasting was getting a little tedious, until I realized that Greasemonkey could come to my rescue. So I whipped up a little user script that looks for links to books at Amazon, and adds links to look up those books on Melvyl. You can get it here.

6 Responses to “amazon2melvyl”

  1. Jeremy Dunck wrote:

    Consider hooking into OCLC’s xisbn service.

    Otherwise, rock on!

    Added to the directory.

  2. Ryan Shaw wrote:

    Cool, thanks for pointing that out. Unfortunately, I can’t think of a way to call the xISBN service from a Greasemonkey script due to security restrictions (and I don’t want users to have to muck about with their security settings).

    But it would probably be worth turning amazon2melvyl into an full-fledged extension, in order to get the benefit of using xISBN. I’ll work on that.

  3. Phil Ringnalda wrote:

    Rather than linking to your image, how about a data: URI? Just bung your image URL into Hixie’s data : URI kitchen and it’ll spit back a URI you can put directly in the script, saving you bandwidth and your users that creepy feeling when they are surfing erotica at Amazon.

  4. Phil Ringnalda wrote:

    You don’t entirely have to get elevated privs to go through xISBN, as long as you are one of the catalogs they have a bookmarklet for (as you are). Use the URL the bookmark loads, and you wind up with their frame on the left side, which isn’t pretty (except when you were searching for something with more than 25 ISBNs, since that’s Melvyl’s per-search limit), but depending on the sorts of things you search for, it might be worth it. Especially in a public library search, where you’re very likely to be on the paperback record at Amazon while your library will own the hardback, it’s probably worth the tradeoff.

  5. Julien Couvreur wrote:

    I wrote a user script generator that can generate that kind of script. It’s still work in progress at: http://blog.monstuff.com/archives/images/GreaseMonkeyScriptGenerator.html

    Basically, you specify a pattern for the links you are interested in, then you specify a template the you want inserted next to the links that matched.
    I’m still looking into patching GreaseMonkey to support installing a user script from a data: url.

    Cheers,

  6. Ryan Shaw wrote:

    Julien: Very cool! Although I should point out that the latest version of amazon2melvyl doesn’t just use information from the linked URI but also queries a third-party web service (xISBN) to build the inserted link–so it couldn’t be generated by your tool. But hopefully your tool will get a lot more people making userscripts…

Leave a Reply

Powered by WordPress