In continuare descriem si modul in care dorim sa fie afisata informatia arborescenta din articolul precedent care descrie un orar studentesc. Pentru aceasta vom folosi limbajul XSLT :
<xsl:stylesheet version=”1.0″
xmlns: xsl=”http://www.w3.org/1999/XSL/Transform”>
<xsl: template match=”/”>
<html>
<body>
<xsl:for-each select=”ORAR/ZI/RAND”>
<xsl:choose>
<xsl: when test=”INTERVAL[@begin=12]” >
<font color=”red”>
<xsl: value-of select=”MATERIE”/>
</font>
</xsl: when>
<xsl: otherwise>
<font color=”red”>
<xsl: value-of select=”MATERIE”/>
</font>
</xsl: otherwise>
</xsl: choose>
</xsl: for-each>
</body>
</html>
</xsl: template>
</xsl: stylesheet>
Leave a comment