xml editor

Supported platforms

Compatible with Windows7 & Mac OS X Snow Leopard

Ready for data server software
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

RE: [xsl] A beef with XSLT Sometimes too complicated


Subject: RE: [xsl] A beef with XSLT Sometimes too complicated
From: "Michael Kay" <mike@xxxxxxxxxxxx>
Date: Fri, 14 Jul 2006 12:31:56 +0100

> I am personally fond of using lookup tables. It does not 
> result in a one liner, but might make things clearer. 
> Besides, you can put these lookup tables in separate 
> documents as xml config files..
> 
> <xsl:variable name="lookup-data">
>   <item id="">background_bright</item>
>   <item id="*">background_faded</item>
> </xsl:variable>
> 
> <xsl:variable name="lookup-ref"
> select="document('')/xsl:stylesheet/xsl:variable[@name = 
> 'lookup-data']/item" />

I like lookup tables too, but I hate this kind of run-time reference to the
source stylesheet. Put it in a separate document in 1.0, or use the variable
directly in 2.0.

Michael Kay
http://www.saxonica.com/


Current Thread
Keywords
xml
XML Editor | XML Author | WYSIWYG Editors | Schema Editor | XSD Documentation | XSL/XSLT Editor | XQuery | XML Databases | SVN Client
© 2002-2011 SyncRO Soft Ltd. All rights reserved. | Sitemap | Privacy Policy | This website was created & generated with <oXygen/>®XML Editor