XML schema |
http://dd.eionet.europa.eu/schemas/WFD2016/GML_SubUnit_2016.xsd
|
---|---|
Output type | HTML |
Description | HTML table |
XSL file | SubUnit.xslt (Last modified: 01 May 2016 20:56 ) |
<?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:wfdgml="http://dd.eionet.europa.eu/schemas/WFD2016/wfdgml" version="2.0"> <xsl:output method="html" indent="yes"/> <xsl:template match="/"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <title>SubUnit</title> </head> <body> <h1>SubUnit</h1> <table border="1" style="border-collapse:collapse;"> <xsl:apply-templates select="wfdgml:FeatureCollection/wfdgml:featureMember/wfdgml:SubUnit"/> </table> </body> </html> </xsl:template> <xsl:template match="wfdgml:FeatureCollection/wfdgml:featureMember/wfdgml:SubUnit"> <xsl:if test="position()=1"> <xsl:call-template name="header"/> </xsl:if> <tr> <td> <xsl:value-of select="wfdgml:inspireIdLocalId"/> </td> <td><xsl:value-of select="wfdgml:inspireIdNamespace"/></td> <td><xsl:value-of select="wfdgml:inspireIdVersionId"/></td> <td><a target="_blank" href="{concat('http://dd.eionet.europa.eu/vocabularyconcept/wise/SpatialUnit/', wfdgml:thematicIdIdentifierScheme, '.', wfdgml:thematicIdIdentifier)}"><xsl:value-of select="wfdgml:thematicIdIdentifierScheme"/>.<xsl:value-of select="wfdgml:thematicIdIdentifier"/></a></td> <td><xsl:value-of select="wfdgml:beginLifespanVersion"/></td> <td><xsl:value-of select="wfdgml:endLifespanVersion"/></td> <td> <xsl:choose> <xsl:when test="wfdgml:predecessorsIdentifier != ''"> <xsl:call-template name="tokenizeString"> <xsl:with-param name="list" select="wfdgml:predecessorsIdentifier"/> <xsl:with-param name="delimiter" select="','"/> <xsl:with-param name="scheme" select="wfdgml:predecessorsIdentifierScheme"/> </xsl:call-template> </xsl:when> </xsl:choose> </td> <td> <xsl:choose> <xsl:when test="wfdgml:successorsIdentifier != ''"> <xsl:call-template name="tokenizeString"> <xsl:with-param name="list" select="wfdgml:successorsIdentifier"/> <xsl:with-param name="delimiter" select="','"/> <xsl:with-param name="scheme" select="wfdgml:successorsIdentifierScheme"/> </xsl:call-template> </xsl:when> </xsl:choose> </td> <td><xsl:value-of select="wfdgml:wiseEvolutionType"/></td> <td><xsl:value-of select="wfdgml:nameTextInternational"/></td> <td><xsl:value-of select="wfdgml:nameText"/></td> <td><xsl:value-of select="wfdgml:nameLanguage"/></td> <td><xsl:value-of select="wfdgml:designationPeriodBegin"/></td> <td><xsl:value-of select="wfdgml:designationPeriodEnd"/></td> <td><xsl:value-of select="wfdgml:zoneType"/></td> <td><xsl:value-of select="wfdgml:specialisedZoneType"/></td> <td> <xsl:choose> <xsl:when test="wfdgml:relatedZoneIdentifier != ''"> <a target="_blank" href="{concat('http://dd.eionet.europa.eu/vocabularyconcept/wise/SpatialUnit/', wfdgml:relatedZoneIdentifierScheme, '.', wfdgml:relatedZoneIdentifier)}"><xsl:value-of select="wfdgml:relatedZoneIdentifierScheme"/>.<xsl:value-of select="wfdgml:relatedZoneIdentifier"/></a> </xsl:when> </xsl:choose> </td> <td> <xsl:choose> <xsl:when test="wfdgml:link != ''"> <a target="_blank" href="{wfdgml:link}"><xsl:value-of select="wfdgml:link"/></a> </xsl:when> </xsl:choose> </td> </tr> </xsl:template> <xsl:template name="header"> <tr> <th>inspireIdLocalId</th> <th>inspireIdNamespace</th> <th>inspireIdVersionId</th> <th>thematicIdIdentifier</th> <th>beginLifespanVersion</th> <th>endLifespanVersion</th> <th>predecessorsIdentifier</th> <th>successorsIdentifier</th> <th>wiseEvolutionType</th> <th>nameTextInternational</th> <th>nameText</th> <th>nameLanguage</th> <th>designationPeriodBegin</th> <th>designationPeriodEnd</th> <th>zoneType</th> <th>specialisedZoneType</th> <th>relatedZoneIdentifier</th> <th>link</th> </tr> </xsl:template> <xsl:template name="tokenizeString"> <xsl:param name="list"/> <xsl:param name="delimiter"/> <xsl:param name="scheme"/> <xsl:choose> <xsl:when test="contains($list, $delimiter)"> <a target="_blank" href="{concat('http://dd.eionet.europa.eu/vocabularyconcept/wise/SpatialUnit/', $scheme, '.', substring-before($list,$delimiter))}"><xsl:value-of select="$scheme"/>.<xsl:value-of select="substring-before($list,$delimiter)"/></a> <br/> <xsl:call-template name="tokenizeString"> <xsl:with-param name="list" select="substring-after($list,$delimiter)"/> <xsl:with-param name="delimiter" select="$delimiter"/> <xsl:with-param name="scheme" select="$scheme"/> </xsl:call-template> </xsl:when> <xsl:otherwise> <xsl:choose> <xsl:when test="$list = ''"> <xsl:text/> </xsl:when> <xsl:otherwise> <a target="_blank" href="{concat('http://dd.eionet.europa.eu/vocabularyconcept/wise/SpatialUnit/', $scheme, '.', $list)}"><xsl:value-of select="$scheme"/>.<xsl:value-of select="$list"/></a> </xsl:otherwise> </xsl:choose> </xsl:otherwise> </xsl:choose> </xsl:template> </xsl:stylesheet>
European Environment Agency
Kgs. Nytorv 6, DK-1050 Copenhagen K, Denmark