English | Français | >> Deutsch << | Magyar | 中文 | Polski | ZVON > Tutorials > XSLT Tutorial |
Intro / Suchen / ZVON |
>> Seite 70 << | Zurück | Vor | Inhalt | Element-Index |
XML Quelltext
<source> <AAA/> <BBB/> <CCC/> </source> Ausgabe
<DIV style="color:red">AAA</DIV> <DIV style="color:red">BBB</DIV> <DIV style="color:red">CCC</DIV> HTML-Ansicht
AAA
BBB
CCC |
XSLT Stylesheet (file: id2.xsl )
<xsl:stylesheet version = '1.0'
xmlns:xsl='http://www.w3.org/1999/XSL/Transform'> <xsl:template match="/*/*"> <DIV style="color:red"> <xsl:value-of select="name()"/> </DIV> </xsl:template> </xsl:stylesheet> |
XML Quelltext
<source> <AAA/> <BBB/> <CCC/> </source> Ausgabe
<EM>AAA</EM> <EM>BBB</EM> <EM>CCC</EM> HTML-Ansicht
AAA
BBB
CCC
|
XSLT Stylesheet (file: id3.xsl )
<xsl:stylesheet version = '1.0'
xmlns:xsl='http://www.w3.org/1999/XSL/Transform'> <xsl:import href="id2.xsl"/> <xsl:template match="/*/*"> <EM> <xsl:value-of select="name()"/> </EM> </xsl:template> </xsl:stylesheet> |
XML Quelltext
<source> <AAA/> <BBB/> <CCC/> </source> Ausgabe
<EM> <DIV style="color:red">AAA</DIV> </EM> <EM> <DIV style="color:red">BBB</DIV> </EM> <EM> <DIV style="color:red">CCC</DIV> </EM> HTML-Ansicht
AAA
BBB
CCC
|
XSLT Stylesheet (file: id4.xsl )
<xsl:stylesheet version = '1.0'
xmlns:xsl='http://www.w3.org/1999/XSL/Transform'> <xsl:import href="id2.xsl"/> <xsl:template match="/*/*"> <EM> <xsl:apply-imports/> </EM> </xsl:template> </xsl:stylesheet> |
XML Quelltext
<source> <AAA/> <BBB/> <CCC/> </source> Ausgabe
<EM/> <EM/> <EM/> HTML-Ansicht
|
XSLT Stylesheet (file: id5.xsl )
<xsl:stylesheet version = '1.0'
xmlns:xsl='http://www.w3.org/1999/XSL/Transform'> <xsl:include href="id2.xsl"/> <xsl:template match="/*/*"> <EM> <xsl:apply-imports/> </EM> </xsl:template> </xsl:stylesheet> |