UK Web Focus (Brian Kelly)

Innovation and best practices for the Web

Posts Tagged ‘Wordpress’

RDFa and WordPress

Posted by Brian Kelly on 5 Apr 2011

RDFa: A Brief Recap

RDFa (Resource Description Framework – in – attributes) is a W3C Recommendation that adds a set of attribute level extensions to XHTML for embedding rich metadata within Web documents.

As described in the Wikidpia entry for RDFa five “principles of interoperable metadata” are met by RDFa:

  1. Publisher Independence: each site can use its own standards
  2. Data Reuse: data is not duplicated. Separate XML and HTML sections are not required for the same content.
  3. Self Containment: the HTML and the RDF are separated
  4. Schema Modularity: the attributes are reusable
  5. Evolvability: additional fields can be added and XML transforms can extract the semantics of the data from an XHTML file

Additionally RDFa may benefit Web accessibility as more information is available to assistive technology.

But how does go about evaluating the potential of RDFa? Last year I wrote a post on Experiments With RDFa which was based on manual inclusion of RDFa markup in a Web page. Although this highlighted a number of issues, including the validity of pages containing RDFa, this is not a scalable approach for significant deployment of RDFa. What is needed is a content management system which can be used to deploy RDFa on existing content in order to evaluate its potential and understand deployment issues.

The Potential for WordPress

WordPress as a Blog Platform and a CMS

WordPress provides a blog platform which can be used for large-scale management of blogs which are hosted at wordpress.com. In addition the software is available under an open source licence and can be deployed within an institution. There is increasing interest in use of WordPress within the higher education sector as can be seen from the recent launch of a WORDPRESS JISCMail list (which is aimed primarily at the UK HE sector) with some further examples of interest in use of WordPress in being available on the University Web Developers group.

A recent discussion on the WORDPRESS JISCMail lists addressed the potential of WordPress as a CMS rather than a blogging platform.  Such uses were also outlined recently in a post on the College Web Editor blog which suggested reasons why WordPress can be the right CMS for #highered websites.  In light of the growing interest in use of WordPress as a CMS it would seem that this platform could have a role to play in the deployment of new HTML developments such as RDFa.

The wp-RDFa WordPress Plugin

A strength of WordPress is its extensible architecture which allows plugins to be developed by third parties and deployed on locally installations of the software.  One such development is the wp-RDFa plugin which supports FOAF and  Dublin Core metadata. The plugin uses Dublin Core markup to tag posts with the title, creator and date elements. In addition wp-RDFa can be configured to make use of FOAF to “relate your personal information to your blog and to relate other users of your blog to you building up a semantic map of your relationships in the online world“.

Initial Experiments With wp-RDFa

Dublin Core Metadata

UKOLN’s Cultural Heritage blog has been closed recently, with no new posts planned for publication.  The blog will however continue to be hosted and can provide a test bed for experiments such as use of the wp-RDFa plugin.

In an initial experiment we found that the although the titles of each blog post were described using Dublin Core metadata, the title was replicated in the blog display. Since this was not acceptable we displayed the use of Dublin Core metadata and repeated the experiment on a private backup copy of the UK Web Focus blog. This time there were no changes in how the blog posts were displayed.

The underlying HTML code made use of the Dublin Core namespace:

<rdf:RDF xmlns:rdf=”http://www.w3.org/1999/02/22-rdf-syntax-ns#&#8221; xmlns:dc=”http://purl.org/dc/elements/1.1/”&gt;

with each individual blog post containing the title and publication date provided as RDFa:

<h3 class=”storytitle”>
<span property=“dc:date” content=”2010-04-27 08:17:53″ resource=”http://blogs.ukoln.ac.uk/xxxxx/2010/04/27/workshop-on-engagement-impact-value/&#8221; />
<span rel=”http://blogs.ukoln.ac.uk/xxxxx/2010/04/27/workshop-on-engagement-impact-value/&#8221; property=”dc:title” resource=”http://blogs.ukoln.ac.uk/xxxxx/2010/04/27/workshop-on-engagement-impact-value/”>Workshop on Engagement, Impact, Value</span></a></h3>

It therefore does appear that the plugin can be deployed on local WordPress installations in order to provide richer semantic markup for existing content. I suspect that the problem with the display in the original experiment may may due to an incompatibility with the theme which is being used (Andreas09). I have reported this problem to the developer of the wp-RDFa plugin.

FOAF (Friends-of-a-Friend)

I had not expected an RDFa plugin to provide support for FOAF, the Friends-of-a-Friend vocabulary.  However since my work with FOAF dates back to at least 2004 I had an interest in seeing how it might be used in the context of a blog.

I had expected that information about the blog authors and commenters would be displayed in some way using a RDFa viewer such as the FireFox Operator plugin. However nothing seemed to be displayed using this plugin. In addition use of the RDFa Viewer and the RDFA Developer plugin also failed to detect FOAF markup embedded as RDFa.  I subsequently found that the FOAF information was provided as an external file.  Use of the FOAF Explorer service provides a display of the FOAF information which has been created by the plugin.

What surprised me with the initial display of the FOAF content was the list of names which I did not recognise.  It seems that these are authors and contributors to a variety of other blogs hosted on UKOLN’s WordPress MU (multi-user) server. I wonder whether the plugin was written for a previous version of WordPress, for which there was one blog per installation? In any case a decision has been made to provide access to a FOAF resource which contains details of the blog authors only, as illustrated.

Emerging Issues

A post on Microformats and RDFa deployment across the Web recently surveyed take-up of RDFa based on an analysis of 12 billion web pages indexed by Yahoo! Search and shows that we are seeing a growth in the take-up of semantic markup in Web pages.  As CMS systems (such as Drupal 7 which supports RDfa ‘out of the box’ – link updated in light of comment)  begin to provide RDFa support we might expect to see a sharp growth in Web pages which provide content which can be processed by software as well as being read by humans.  For those institutions which host a local WordPress installation it appears that it is now possible to begin exploring use of RDFa. As described in a post by Mark Birkbeck on RDFa and SEO an important role for RDFa will be to provide improvements to searching.  But in addition the ability to use wp-RDFa to create FOAF files makes we wonder whether this approach might be useful in describing relationships between contributors to blogs and perhaps provide the hooks to facilitate data-mining of the blogosphere.

It would be a mistake, however, to focus on one single tool for creating RDFa markup.  On the WORDPRESS JISCMail list Pat Lockley  mentioned that he is also developing an RDFa plugin for WordPress and invited feedback on further developments.  Here are some of my thoughts:

  • There is a need for a clear understanding of how the semantic markup will be applied and the user cases it aims to address.
  • There will also be a need to understand how such semantic markup would be used in non-blogging uses of WordPress, where the notions of a blog post, blog author and blog commenters may not apply.
  • There will be a need to ensure that different plugins which create RDFa markup are interoperable i.e. if a plugin is replaced by an alternative applications which process the RDFa should give consistent results.
  • Consideration should be given to privacy implications of exposing personal data (in particular) in semantic markup.

Is anyone making use of RDFa in WordPress who has experiences to share?  And are there any further suggestions which can be provided for those who are involved in related development work?

Posted in standards | Tagged: , | 9 Comments »

WordPress has Gears (and my Glass is Half Full)

Posted by Brian Kelly on 2 Jul 2008

WordPress have just announced the availability of WordPress Gears:

Gears? It is a browser extension like Flash or QuickTime/Media Player. However Gears works with the browser to enhance web based applications. It can create local database and file storage, and run JavaScript in the background to update them without slowing down the browser.

Gears has been in the making for over a year and is well known among the web developers. Currently it supports Firefox versions 2 & 3 and Internet Explorer versions 6 & 7. Safari 3 support is coming soon.

On WordPress.com it is used to store all images and other web page components from the admin area to the user’s PC, speeding up access and reducing unnecessary web traffic.

The speed increase is most noticeable when Internet is slow or on high latency and makes everybody’s blogging experience more enjoyable.

We’re now starting to see the development of a numbers of tools which will reduce the bandwidth requirements for using a networked application and/or allow Web-based applications to be usable offline (e.g. Google Gears).

I’m pleased with the variety of developments which are taking place behind the scenes on the WordPress.com Web site which hosts this blog.  In January 2008, for example, there was an announcement on the WordPress blog that an interface which provides access statistics for syndicated accesses to blog posts had been relaunched and a week later there was an announcement of enhancements to the interface to the Akismet spam filter. Indeed if you look at the WordPress.com blog archive for 2008 you will see a whole host of developments which have been made, many to the hosted blog environment.

This is an example of the ‘always beta’ nature of many Web 2.0 services. But not everybody likes this. Stuart Smith, for example, has commented recently on my blog that:

Part of the problem is the eternal beta syndrome that dominates the world of web apps. It means nothing is ever finished or entirely taken responsibility for.

It’s true that an ‘eternal beta’ approach could be used to deploy new developments which have not been adequately tested, to the detriment of the end user. But to me the response to this criticism is to say that ongoing enhancements to services need to be carefully managed and mechanisms are needed to allow users to quickly and easily provide their feedback.  In the case of the WordPress.com blog, the announcement are made on their developments blog, are brought to the attention of blog authors in their administrators interface and they encourage feedback – which they do receive.

When the WordPress open source software is installed locally to provide a blog service, such ongoing developments do not happen. And this, I find, somewhat irritating when I use the JISC PoWR blogwhich is hosted by the JISC on their JISC Involve blog hosting service– the blog software is somewhat dated, and hasn’t benefitted from the developments I’m used to on the UK Web Focus blog.

Perhaps the differences between my perspectives and Stuart’s are based on particular experiences we may have had. On the other hand perhaps this reflects an individual mindset – do you see software development as bringing about improvements, or are developments more likely to be to disrupt well-established working practices?  Or to put it another way, is the glass half full or half empty?  I’m pleased to say that WordPress.com blog is half full :-)  (But WordPress shouldn’t get too complacent – if the quality deteriorates, I can always take my custom elsewhere).

Posted in Blog | Tagged: | 3 Comments »