[XMLSCHEMA-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Validating application-specific XHTML

From: Michael Ludwig <mlu@as-guides.com>
Date: Thu, 27 Nov 2008 11:32:18 +0100
Message-ID: <492E7732.1030802@as-guides.com>
To: xmlschema-dev@w3.org
Re: Validating application-specific XHTML

Robert Koberg schrieb:
> I would hate to see a schema that validates a CSS based XHTML page.
> Even worse, I would hate to maintain it.

Why would you hate to see, or have to maintain such a schema? Is it the
additional tedium you find uninspiring? Or do you think it is a bad
application, or even an abuse of XML Schema? If it is the latter, could
you explain why you think this is bad?

> However, it would be pretty easy to use an XSL to validate your page.
> You could base the XSL off of your CSS rules. For example, you might
> have a CSS containing:
>
> #narrow-col #nav { blah... }

> <xsl:template match="*" mode="validate-nav">
>   <p>
>     Has Nav:
>     <xsl:value-of select="exists(key('ident',
> 'narrow-col')/*[@id='nav'])"/>
>   </p>
> </xsl:template>

That's a good idea. Strangely, it hasn't occurred to me I could use XSLT
for the job. It doesn't seem to have a reputation for being a validator
tool, yet.

Thank you very much!

Michael Ludwig
Received on Thursday, 27 November 2008 10:33:00 GMT

Subscribe to the Stylus Scoop newsletter for helpful XML tips and tutorials.
Email
First Name
Last Name
Company

Download Stylus Studio 6 XML Enterprise Edition

Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2007 All Rights Reserved.