<?xml version='1.0' encoding='utf-8'?>
<xsl:stylesheet
	xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:rs='urn:schemas-microsoft-com:rowset'
 	xmlns:z='#RowsetSchema'
	xmlns:date="http://www.ora.com/XSLTCookbook/NS/dates"
    xml:space="default" 
    xmlns:ddwrt="http://schemas.microsoft.com/WebParts/v2/DataView/runtime" 
	version="1.0">

	<xsl:strip-space elements="true" />
	<xsl:output omit-xml-declaration="yes" />
	<xsl:param name="path"></xsl:param>
	<xsl:param name="url"></xsl:param>
	<xsl:param name="title"></xsl:param>

	<xsl:template match='//rs:data'>
		<xsl:if test="count(*[@ows_Code = $title]) &gt; 0">
			<link rel="stylesheet" type="text/css" href="/xslt/banner.css"/>
			<div id="banner-container">
				<xsl:attribute name="class"><xsl:value-of select="$title" /></xsl:attribute>
					<div id="banner">
						<xsl:apply-templates select="*[@ows_Code = $title]" mode='main' />
					</div>
			</div>
		</xsl:if>
	</xsl:template>

	<xsl:template match='*' mode="main">
		<div class="banner-item">
			<a>
				<xsl:attribute name="href"><xsl:value-of select="@ows_URL"/></xsl:attribute>
				<h2><xsl:value-of select="@ows_LinkTitle" disable-output-escaping="yes"/></h2>
				<xsl:choose>
					<xsl:when test="$title = 'home' and @ows_Volgnummer = 4">
						<img src="/_catalogs/masterpage/designfiles/images/regiokaart.svg" />
					</xsl:when>
					<xsl:otherwise>
						<xsl:if test="@ows_Inleiding != ''">
							<xsl:value-of select="@ows_Inleiding" disable-output-escaping="yes"/><br/>
						</xsl:if>
					</xsl:otherwise>
				</xsl:choose>
				<span>lees meer&#160;</span>
			</a>
		</div>
	</xsl:template>

</xsl:stylesheet>