Skip to the Main Content

Note:These pages make extensive use of the latest XHTML and CSS Standards. They ought to look great in any standards-compliant modern browser. Unfortunately, they will probably look horrible in older browsers, like Netscape 4.x and IE 4.x. Moreover, many posts use MathML, which is, currently only supported in Mozilla. My best suggestion (and you will thank me when surfing an ever-increasing number of sites on the web which have been crafted to use the new standards) is to upgrade to the latest version of your browser. If that's not possible, consider moving to the Standards-compliant and open-source Mozilla browser.

May 26, 2004

Now More User-Friendly

If you’ve ever used the W3C Validator, you probably noticed a couple of things:

  1. The error messages produced by the onsgmls parser are pretty obscure.
  2. The latest version of the Validator attempts to improve the situation by including its own, more verbose error messages, in addition to the terse ones from onsgmls. These messages are not necessarily the clearest, but they are a big improvement.

If you’ve ever commented on this blog, you know that we run comments through a local copy of the Validator, yielding the same obscure error messages as the “old” W3C Validator. Alexei Kosut seems to have lost interest in his MTValidate plugin (at least, he never answered any of my emails). So I decided to update the plugin to use the new, more user-friendly error messages.

The result is mtvalidate-0.2. To install,

  1. There are some Perl module prerequisites. Get your webhost to install them, or use CPAN to install them in your extlib directory.
  2. Make sure you have the onsgmls SGML parser installed on your system. It comes with RedHat Linux, it’s available via fink for MacOSX,
    fink install opensp3
    and for other OS’s, you can always download and compile the source code.
  3. Download and uncompress the sgml-lib directory and put it inside the validator directory.
  4. Edit the SGML_Parser line in validator/config/validator.conf to reflect the location of onsgmls.
  5. Move MTValidate.pl and the validator directory into your MovableType plugins directory.
  6. Follow my previous instructions to enable validation of comments. Alexei has instructions to enable validation of entries.

Let me know how you like the new, “improved” error-reporting. And let the W3C know if you have any suggestions for improving the error messages.

Posted by distler at May 26, 2004 11:45 PM

TrackBack URL for this Entry:   https://golem.ph.utexas.edu/cgi-bin/MT-3.0/dxy-tb.fcgi/370

4 Comments & 0 Trackbacks

Re: Now More User-Friendly

If only installing MTValidate was more user-friendly.

I have my own domain that’s hosted on a shared box, but I’m not sure if SGML is installed on the system. Do you know how I can find out?

Posted by: Joshua Kaufman on June 4, 2004 6:57 PM | Permalink | Reply to this

installation

If you have shell access, try “which onsgmls” or “locate onsgmls”. On my system, these yield

% locate onsgmls
/sw/bin/onsgmls
/sw/share/man/man1/onsgmls.1
% which onsgmls
/sw/bin/onsgmls

so the path to the executable is /sw/bin/onsgmls .

You also need to make sure you have all the requisite Perl Modules installed. Using CPAN, you can do this most easily by installing Bundle::W3C::Validator. See this discussion.

Posted by: Jacques Distler on June 4, 2004 8:31 PM | Permalink | PGP Sig | Reply to this

Re: installation

Neither of those commands worked. When I type help, I find that I’m using “GNU bash, version 2.05a.0(1)-release (i386-pc-linux-gnu)”. Any other ideas?

Posted by: Joshua Kaufman on June 15, 2004 7:08 PM | Permalink | Reply to this

Finding onsgmls

On most Linux systems, the path to onsgmls is

/usr/bin/onsgmls

So you could try typing

/usr/bin/onsgmls -h

If it’s not there, and your webhost can’t help you, you can try downloading the source and compiling it. I expect it compiles pretty straightforwardly, as it is part of the standard distribution on most Linux systems.

Sorry I can’t be of more help.

Posted by: Jacques Distler on June 15, 2004 7:21 PM | Permalink | PGP Sig | Reply to this

Post a New Comment