UK Web Focus

Innovation and best practices for the Web

URI Interface to W3C’s Unicorn Validator

Posted by Brian Kelly on 23 September 2010

The W3C recently announced that they had launched Unicorn, which they described as “a one-stop tool to help people improve the quality of their Web pages. Unicorn combines a number of popular tools in a single, easy interface, including the Markup validator, CSS validator, mobileOk checker, and Feed validator“.

Output from UnicornAn example of how this validation service works is illustrated, which is based on validation of the UKOLN home page.

The  default options provide validation of the HTML and CSS of the selected page together with any auto-discoverable RSS feeds.

The interface to the validator is a Web form hosted on the W3C Web site.

But encouraging use of such validation services would be much easier if the interface was more closely integrated with am author’s browsing environment, so that they didn’t have to visit an other page and copy and paste a URL.

The UKOLN Web site has been configured to provide this ease-of-use. Appending ,unicorn to the UKOLN home page will invoke the Unicorn validator – and this option can be used on any page on the UKOLN Web site.

This service is implemented by adding the following line to the Apache Web server’s configuration file:

RewriteRule /(.*),unicorn http://validator.w3.org/unicorn/check? ucn_uri =http://%{HTTP_HOST}/$1&ucn_task=conformance# [R=301]

I’m not sure how easy it may be to implement such extensions to Web servers these days; there may be policy barriers to such changes or perhaps technical barriers imposed by Content Management Systems.  But I wonder if this simple approach might be of interest to others?

About these ads

One Response to “URI Interface to W3C’s Unicorn Validator”

  1. [...] URI Interface toW3C’s Unicorn Validator [...]

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: