Proovitud abielu
From ICO wiki
Meeskond "Proovitud abielu"
- Berit Põldoja
- Elina Kuldkepp
XML/XSD/XSLT
XML
XSD
XSLT XML
<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:msxsl="urn:schemas-microsoft-com:xslt" exclude-result-prefixes="msxsl"
>
<xsl:output method="html" indent="yes"/>
<xsl:template match="/">
<html>
<head>
<title>Raamatupoed</title>
</head>
<body>
<h1>Raamatupoed</h1>
</body>
<table border="1">
<tr bgcolor="#9acd32">
<th>Raamatupood ja raamatud</th>
<th>Kirjeldus</th>
<th>Info</th>
</tr>
<xsl:for-each select="Bookstores/Bookstore">
<tr>
<td bgcolor="#9acd32">
<xsl:value-of select="Name"/>
</td>
<xsl:for-each select="Book">
<tr>
<td>
<xsl:value-of select="Title"/>
</td>
<td>
<xsl:value-of select="Description"/>
</td>
<td>
<xsl:value-of select="Author"/>
</td>
</tr>
</xsl:for-each>
</tr>
</xsl:for-each>
</table>
<table border="1">
<tr bgcolor="#9acd32">
<th>Sugu</th>
<th>Eesnimi</th>
<th>Perekonnanimi</th>
<th>Riik</th>
<th>Sünniaasta</th>
</tr>
<xsl:for-each select="Bookstores/Bookstore/Book/Author">
<tr>
<xsl:if test="@gender='Woman'">
<xsl:if test="Country='Estonia'">
<td>
<xsl:value-of select="@gender" />
</td>
<td>
<xsl:value-of select="FirstName" />
</td>
<td>
<xsl:value-of select="LastName" />
</td>
<td>
<xsl:value-of select="Country" />
</td>
<td>
<xsl:value-of select="BirthYear" />
</td>
</xsl:if>
</xsl:if>
</tr>
</xsl:for-each>
</table>
</html>
</xsl:template>
</xsl:stylesheet>