COinS-PMH (unAPI) Wordpress Plugin
Since becoming the first
COinS-PMH
(now
unAPI)-compliant
blog in the world, I’ve been meaning to flesh the plugin out a bit
before releasing it; but I haven’t had time. So here’s the Wordpress
Simple OAI
plugin. To
install it: unzip it into the wp-content/plugins
directory (so you get
a directory called oai
there). Then, add this code snippet to
post.php
and single.php
in your current theme, under the posting
title:
<span class="Z3988 pmh" title="ctx_ver=Z39.88-2004 & rft_val_fmt=info%3Aofi%2Ffmt%3Akev%3Amtx%3Adc & rfr_id=info%3Asid%2Fwallandbinkley.com%3Agenerator & rft.identifier=oai:wallandbinkley.com:quaedam:<?php echo the_ID(); ?> & rft.title=<?php echo urlencode(the_title('', '', FALSE));?>">.</span>
I’ve broken the title attribute into several lines for readability, but you should be sure to combine it into a single line; and note that its ampersands should be presented as entities. Replace “wallandbinkley.com” and “quaedam” with your own domain and blog names.
In the head of these two files, add this (modifying the url as appropriate):
<link rel="meta" type="application/xml" title="COinS-PMH" href="http://www.wallandbinkley.com/quaedam/wp-content/plugins/oai/wp-oai-simple.php?" />
Finally, insert this into your style.css
:
.pmh {display: none;}
Now install Dan Chudnov’s GreaseMonkey script, if you haven’t already, and visit your blog. You should see something like this screenshot.
[...] So, does that mean I can do XYZ that I've wanted to do? Maybe. Anybody who knows how to write a WordPress plugin can take a stab at playing with all that data. The "refine search" content in the right column, and the "alternate searches" content at the bottom is generated that way. Try this one: I've finally got the Wikipedia results I've always wanted in the catalog, just look in the right column. Or take a look at the "add to del.icio.us" link in the record display, that's generated by a regular wordpress plugin written by Arne Brachhold, who wasn't thinking of libraries or OPACs when he wrote it. And down at the bottom of the page you'll see the a list of related works that's built by my own bsuite plugin. Want COinS-PMH/unAPI? The interface and all the data are there to make it happen, and here's a good plugin to start from. [...]
[...] So, does that mean I can do XYZ that I've wanted to do? Maybe. Anybody who knows how to write a WordPress plugin can take a stab at playing with all that data. The "refine search" content in the right column, and the "alternate searches" content at the bottom is generated that way. Try this one: I've finally got the Wikipedia results I've always wanted in the catalog, just look in the right column. Or take a look at the "add to del.icio.us" link in the record display, that's generated by a regular wordpress plugin written by Arne Brachhold, who wasn't thinking of libraries or OPACs when he wrote it. And down at the bottom of the page you'll see the a list of related works that's built by my own bsuite plugin. Want COinS-PMH/unAPI? The interface and all the data are there to make it happen, and here's a good plugin to start from. [...]
[...] choose a URI prefix for your blog, e.g. oai:wallandbinkley.com:quaedam: (I'm using oai prefixes for compatibility with my Wordpress OAI-PMH plugin). Note the final colon. [...]
[...] Thanks to a couple of very helpful posts and some neat WordPress hacks — http://www.wallandbinkley.com/quaedam/?p=59 and http://www.wallandbinkley.com/quaedam/?p=50 – Tecnosofia is now unAPI-1.0- and COinS-PMH-compliant. Under each post there are shortcut links to view the Dublin Core, MODS, and other unAPI formats (should I add them in). [...]
Hello! I installed Wordpress on my server, and set up a site. It's a relly nice piece of software. However, I am missing a piece of functionality, and couldn't find a suitable answer for it. Mayou you know a plugin I could use?I need to automatically inserts ads in my posts.And not AdSense ads, but rather HTML snippets defined by me (affiliate links, etc). Let's say I would insert a tag in my post: -- ad here -- and the plugin would automatically replace it with some HTML code, when the post is displayed on my site.I really don't need any fancy configuration options etc, just the basic replace functionality. Do you know a plugin that can handle this?
[...] COinS-PMH (unAPI) WordPress Plugin (tags: library_tools web2.0 oai-pmh xml blogging plugin wordpress WP unAPI COinS) [...]