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

RE: Dynamic generation of stylesheets

Subject: RE: Dynamic generation of stylesheets
From: Daniel Rivers-Moore <daniel.rivers-moore@xxxxxxxxxx>
Date: Thu, 16 Mar 2000 10:41:10 -0000
daniel rivers
An XSL stylesheet is an XML document. Therefore it can be produced as the
output from an XSLT transformation of some other XML document or documents.

The following XSLT stylesheet

<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
 <xsl:template match="/">
  <xsl:element name="xsl:stylesheet">
   <xsl:element name="xsl:template">
    <xsl:attribute name="match">//myelemtype[@myatt='myval']</xsl:attribute>
    <xsl:element name="foo">
     <xsl:attribute name="bar">barval</xsl:attribute>
    </xsl:element>
   </xsl:element>
  </xsl:element>
 </xsl:template>
</xsl:stylesheet>

when applied to an arbitrary XML document, will produce this output

<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
 <xsl:template match="//myelemtype[@myatt='myval']">
  <foo bar="barval"/>
 </xsl:template>
</xsl:stylesheet>

which, in turn, when applied to the following XML document:

<myelemtype myatt="myval"/>

will produce the following result

<foo bar="barval"/>

Hope that helps

Daniel Rivers-Moore
Director of New Technologies
RivCom
Tel: +44 (0) 1793 792004
Mobile: +44 (0) 7970 893847
Email: daniel.rivers-moore@xxxxxxxxxx

 -----Original Message-----
From: 	Maria Manuel [mailto:Maria.Manuel@xxxxxxxxxxxx] 
Sent:	15 March 2000 09:26
To:	'xsl-list-digest@xxxxxxxxxxxxxxxx'
Subject:	Dynamic generation of stylesheets

Does anyone know how to generate dynamically XSL stylesheets?

Maria Manuel 


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
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-2013 All Rights Reserved.