View stylesheet

XML schemas http://air-climate.eionet.europa.eu/schemas/AirQualityQuestionnaire/AirQualityQuestionnaire-form8.xsd
Output type HTML
Description HTML
XSL file form8.xslt (Last modified: 15 Apr 2009 16:34 )
<?xml version="1.0" encoding="ISO-8859-1"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
	<xsl:output method="xml" indent="yes"
		doctype-public="-//W3C//DTD XHTML 1.0 Strict//EN"
		doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"
		omit-xml-declaration="yes" />

	<xsl:param name="xml_folder_uri" />
	<xsl:variable name="lang">en</xsl:variable>

	<!-- Uncommment the lines below for production use-->
	<xsl:variable name="labels_xml" select="document(concat($xml_folder_uri,'aqq-labels.xml'))" />

	<!-- Uncomment the lines below for development use
	<xsl:variable name="labels_xml" select="document('../xml/aqq-labels.xml')" />
	 -->

	<xsl:variable name="labels" select="$labels_xml/tmx/body" />
<xsl:template match="form8">
	<html>
		<head>
			<style type="text/css">
				table {
					border: 1px solid black;
					border-collapse: collapse;
					width: 100%;
				}
				table th {
					border: 1px solid black;
				}
				table td {
					border: 1px solid black;
				}
			</style>
		</head>
		<body>
			<h1>
				<xsl:value-of select="$labels/tu[@tuid='lbl-form8']/tuv[@xml:lang=$lang]" />
				- <xsl:value-of select="$labels/tu[@tuid='lbl-form8-title']/tuv[@xml:lang=$lang]" />
			</h1>
			<xsl:apply-templates select="form8a"/>
			<xsl:apply-templates select="form8b"/>
			<xsl:apply-templates select="form8c"/>
			<xsl:apply-templates select="form8d"/>
			<xsl:apply-templates select="form8e"/>
			<xsl:apply-templates select="form8f"/>
			<h2><xsl:value-of select="$labels/tu[@tuid='lbl-form-comments']/tuv[@xml:lang=$lang]" /></h2>
			<p><xsl:value-of select="form-comments"/></p>
		</body>
	</html>
</xsl:template>

<xsl:template match="form8a">
	<h2><xsl:value-of select="$labels/tu[@tuid='lbl-form8a-title']/tuv[@xml:lang=$lang]" /></h2>
	<table>
		<thead>
			<tr>
				<th rowspan="2"><xsl:value-of select="$labels/tu[@tuid='lbl-zone-code']/tuv[@xml:lang=$lang]" /></th>
				<th colspan="3"><xsl:value-of select="$labels/tu[@tuid='lbl-lvhealth-1hr']/tuv[@xml:lang=$lang]" /></th>
				<th colspan="2"><xsl:value-of select="$labels/tu[@tuid='lbl-lvhealth-24hr']/tuv[@xml:lang=$lang]" /></th>
				<th colspan="2"><xsl:value-of select="$labels/tu[@tuid='lbl-lvecosystems-annual']/tuv[@xml:lang=$lang]" /></th>
				<th colspan="2"><xsl:value-of select="$labels/tu[@tuid='lbl-lvecosystems-winter']/tuv[@xml:lang=$lang]" /></th>
			</tr>
			<tr>
				<th>&#x3e;LV + MOT</th>
				<th>&#x2264;LV + MOT; &#x3e;LV</th>
				<th>&#x2264;LV</th>
				<th>&#x3e;LV</th>
				<th>&#x2264;LV</th>
				<th>&#x3e;LV</th>
				<th>&#x2264;LV</th>
				<th>&#x3e;LV</th>
				<th>&#x2264;LV</th>
			</tr>
		</thead>
		<tbody>
			<xsl:for-each select="form8a-row">
				<tr>
					<td><xsl:value-of select="zone-code"/></td>
					<td><xsl:value-of select="lv-health-1/lv-mot"/></td>
					<td><xsl:value-of select="lv-health-1/lv-mot-lv"/></td>
					<td><xsl:value-of select="lv-health-1/lv"/></td>
					<td><xsl:value-of select="lv-health-24/gt-lv"/></td>
					<td><xsl:value-of select="lv-health-24/lt-lv"/></td>
					<td><xsl:value-of select="lv-health-y/gt-lv"/></td>
					<td><xsl:value-of select="lv-health-y/lt-lv"/></td>
					<td><xsl:value-of select="lv-health-w/gt-lv"/></td>
					<td><xsl:value-of select="lv-health-w/lt-lv"/></td>
				</tr>
			</xsl:for-each>
		</tbody>
	</table>
</xsl:template>

<xsl:template match="form8b">
	<h2><xsl:value-of select="$labels/tu[@tuid='lbl-form8b-title']/tuv[@xml:lang=$lang]" /></h2>
	<table>
		<thead>
			<tr>
				<th rowspan="2"><xsl:value-of select="$labels/tu[@tuid='lbl-zone-code']/tuv[@xml:lang=$lang]" /></th>
				<th colspan="3"><xsl:value-of select="$labels/tu[@tuid='lbl-lvhealth-1hr']/tuv[@xml:lang=$lang]" /></th>
				<th colspan="3"><xsl:value-of select="$labels/tu[@tuid='lbl-lvhealth-annual']/tuv[@xml:lang=$lang]" /></th>
				<th colspan="2"><xsl:value-of select="$labels/tu[@tuid='lbl-lvvegetation']/tuv[@xml:lang=$lang]" /></th>
			</tr>
			<tr>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-lv-mot']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-lv-mot-lv']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-llv']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-lv-mot']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-lv-mot-lv']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-llv']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-glv']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-llv']/tuv[@xml:lang=$lang]" /></th>
			</tr>
		</thead>
		<tbody>
			<xsl:for-each select="form8b-row">
				<tr>
					<td><xsl:value-of select="zone-code"/></td>
					<td><xsl:value-of select="lv-health-1/lv-mot"/></td>
					<td><xsl:value-of select="lv-health-1/lv-mot-lv"/></td>
					<td><xsl:value-of select="lv-health-1/lv"/></td>
					<td><xsl:value-of select="lv-health-y/lv-mot"/></td>
					<td><xsl:value-of select="lv-health-y/lv-mot-lv"/></td>
					<td><xsl:value-of select="lv-health-y/lv"/></td>
					<td><xsl:value-of select="lv-health-veg/gt-lv"/></td>
					<td><xsl:value-of select="lv-health-veg/lt-lv"/></td>
				</tr>
			</xsl:for-each>
		</tbody>
	</table>
</xsl:template>

<xsl:template match="form8c">
	<h2><xsl:value-of select="$labels/tu[@tuid='lbl_form8c-title']/tuv[@xml:lang=$lang]" /></h2>
	<table>
		<thead>
			<tr>
				<th rowspan="2"><xsl:value-of select="$labels/tu[@tuid='lbl-zone-code']/tuv[@xml:lang=$lang]" /></th>
				<th colspan="3"><xsl:value-of select="$labels/tu[@tuid='lbl-lv24h-stage1']/tuv[@xml:lang=$lang]" /></th>
				<th colspan="3"><xsl:value-of select="$labels/tu[@tuid='lbl-lvannual-stage1']/tuv[@xml:lang=$lang]" /></th>
				<th colspan="2"><xsl:value-of select="$labels/tu[@tuid='lbl-lv24h-stage2']/tuv[@xml:lang=$lang]" /></th>
				<th colspan="3"><xsl:value-of select="$labels/tu[@tuid='lbl-lvannual-stage2']/tuv[@xml:lang=$lang]" /></th>
			</tr>
			<tr>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-lv-mot']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-lv-mot-lv']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-llv']/tuv[@xml:lang=$lang]" /></th>

				<th><xsl:value-of select="$labels/tu[@tuid='lbl-lv-mot']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-lv-mot-lv']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-llv']/tuv[@xml:lang=$lang]" /></th>

				<th><xsl:value-of select="$labels/tu[@tuid='lbl-glv']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-llv']/tuv[@xml:lang=$lang]" /></th>

				<th><xsl:value-of select="$labels/tu[@tuid='lbl-lv-mot']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-lv-mot-lv']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-llv']/tuv[@xml:lang=$lang]" /></th>
			</tr>
		</thead>
		<tbody>
			<xsl:for-each select="form8c-row">
				<tr>
					<td><xsl:value-of select="zone-code"/></td>
					<td><xsl:value-of select="lv-24-stage1/lv-mot"/></td>
					<td><xsl:value-of select="lv-24-stage1/lv-mot-lv"/></td>
					<td><xsl:value-of select="lv-24-stage1/lv"/></td>
					<td><xsl:value-of select="lv-y-stage1/lv-mot"/></td>
					<td><xsl:value-of select="lv-y-stage1/lv-mot-lv"/></td>
					<td><xsl:value-of select="lv-y-stage1/lv"/></td>
					<td><xsl:value-of select="lv-24-stage2/gt-lv"/></td>
					<td><xsl:value-of select="lv-24-stage2/lt-lv"/></td>
					<td><xsl:value-of select="lv-y-stage2/lv-mot"/></td>
					<td><xsl:value-of select="lv-y-stage2/lv-mot-lv"/></td>
					<td><xsl:value-of select="lv-y-stage2/lv"/></td>
				</tr>
			</xsl:for-each>
		</tbody>
	</table>
</xsl:template>

<xsl:template match="form8d">
	<h2><xsl:value-of select="$labels/tu[@tuid='lbl-form8d-title']/tuv[@xml:lang=$lang]" /></h2>
	<table>
		<thead>
			<tr>
				<th rowspan="2"><xsl:value-of select="$labels/tu[@tuid='lbl-zone-code']/tuv[@xml:lang=$lang]" /></th>
				<th colspan="4"><xsl:value-of select="$labels/tu[@tuid='lbl-lv']/tuv[@xml:lang=$lang]" /></th>
			</tr>
			<tr>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-lv-mot']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-lv-mot-lv']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-llv']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-ss']/tuv[@xml:lang=$lang]" /></th>
			</tr>
		</thead>
		<tbody>
			<xsl:for-each select="form8d-row">
				<tr>
					<td><xsl:value-of select="zone-code"/></td>
					<td><xsl:value-of select="lv/lv-mot"/></td>
					<td><xsl:value-of select="lv/lv-mot-lv"/></td>
					<td><xsl:value-of select="lv/lv"/></td>
					<td><xsl:value-of select="lv/ss"/></td>
				</tr>
			</xsl:for-each>
		</tbody>
	</table>
</xsl:template>

<xsl:template match="form8e">
	<h2><xsl:value-of select="$labels/tu[@tuid='lbl-form8e-title']/tuv[@xml:lang=$lang]" /></h2>
	<table>
		<thead>
			<tr>
				<th rowspan="2"><xsl:value-of select="$labels/tu[@tuid='lbl-zone-code']/tuv[@xml:lang=$lang]" /></th>
				<th colspan="4"><xsl:value-of select="$labels/tu[@tuid='lbl-lv']/tuv[@xml:lang=$lang]" /></th>
			</tr>
			<tr>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-lv-mot']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-lv-mot-lv']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-llv']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-art3']/tuv[@xml:lang=$lang]" /></th>
			</tr>
		</thead>
		<tbody>
			<xsl:for-each select="form8e-row">
				<tr>
					<td><xsl:value-of select="zone-code"/></td>
					<td><xsl:value-of select="lv/lv-mot"/></td>
					<td><xsl:value-of select="lv/lv-mot-lv"/></td>
					<td><xsl:value-of select="lv/lv"/></td>
					<td><xsl:value-of select="lv/art-3-2"/></td>
				</tr>
			</xsl:for-each>
		</tbody>
	</table>
</xsl:template>

<xsl:template match="form8f">
	<h2><xsl:value-of select="$labels/tu[@tuid='lbl-form8f-title']/tuv[@xml:lang=$lang]" /></h2>
	<table>
		<thead>
			<tr>
				<th rowspan="2"><xsl:value-of select="$labels/tu[@tuid='lbl-zone-code']/tuv[@xml:lang=$lang]" /></th>
				<th colspan="4"><xsl:value-of select="$labels/tu[@tuid='lbl-lv']/tuv[@xml:lang=$lang]" /></th>
			</tr>
			<tr>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-lv-mot']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-lv-mot-lv']/tuv[@xml:lang=$lang]" /></th>
				<th><xsl:value-of select="$labels/tu[@tuid='lbl-llv']/tuv[@xml:lang=$lang]" /></th>
			</tr>
		</thead>
		<tbody>
			<xsl:for-each select="form8f-row">
				<tr>
					<td><xsl:value-of select="zone-code"/></td>
					<td><xsl:value-of select="lv/lv-mot"/></td>
					<td><xsl:value-of select="lv/lv-mot-lv"/></td>
					<td><xsl:value-of select="lv/lv"/></td>
				</tr>
			</xsl:for-each>
		</tbody>
	</table>
</xsl:template>
</xsl:stylesheet>