<xsl:stylesheet xmlns:x="http://www.w3.org/2001/XMLSchema" xmlns:d="http://schemas.microsoft.com/sharepoint/dsp" version="1.0" exclude-result-prefixes="xsl msxsl ddwrt" xmlns:ddwrt="http://schemas.microsoft.com/WebParts/v2/DataView/runtime" xmlns:asp="http://schemas.microsoft.com/ASPNET/20" xmlns:__designer="http://schemas.microsoft.com/WebParts/v2/DataView/designer" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:msxsl="urn:schemas-microsoft-com:xslt" xmlns:SharePoint="Microsoft.SharePoint.WebControls" xmlns:ddwrt2="urn:frontpage:internal">
	<xsl:output method="html" indent="no"/>
	<xsl:decimal-format NaN=""/>
	<xsl:param name="dvt_apos">'</xsl:param>
	<xsl:param name="ManualRefresh"></xsl:param>
	<xsl:param name="UserID">CurrentUserName</xsl:param>
	<xsl:param name="CurrentUrl">CurrentUrl</xsl:param>
	<xsl:variable name="dvt_1_automode">0</xsl:variable>
	<xsl:template match="/" xmlns:x="http://www.w3.org/2001/XMLSchema" xmlns:d="http://schemas.microsoft.com/sharepoint/dsp" xmlns:asp="http://schemas.microsoft.com/ASPNET/20" xmlns:__designer="http://schemas.microsoft.com/WebParts/v2/DataView/designer" xmlns:SharePoint="Microsoft.SharePoint.WebControls">
		<xsl:call-template name="dvt_1"/>
	</xsl:template>
	<xsl:template name="dvt_1.empty">
	</xsl:template>
	<xsl:template name="dvt_1">
		<xsl:variable name="Rows" select="/dsQueryResponse/Rows/Row[@Display = 'Yes' or @Display = '1']" />
		<xsl:variable name="dvt_RowCount" select="count($Rows)" />
		<xsl:variable name="dvt_IsEmpty" select="$dvt_RowCount = 0" />
		<xsl:choose>
			<xsl:when test="$dvt_IsEmpty">
				<xsl:call-template name="dvt_1.empty" />
			</xsl:when>
			<xsl:otherwise>
				<div id="leftNav">
					<ul id="leftNavUL">
						<xsl:call-template name="dvt_1.body">
							<xsl:with-param name="Rows" select="$Rows" />
						</xsl:call-template>
						<xsl:if test="$UserID = 'Webmaster'">
							<!--li class="left_nav level1 sitecontent"><a href="{substring-before($CurrentUrl,'Pages/')}_layouts/viewlsts.aspx">All Site Content</a></li-->
						</xsl:if>
					</ul>
				</div>
			</xsl:otherwise>
		</xsl:choose>
	</xsl:template>
	<xsl:template name="dvt_1.body">
		<xsl:param name="Rows" />
		<xsl:for-each select="$Rows">
			<xsl:call-template name="dvt_1.rowview" />
		</xsl:for-each>
	</xsl:template>
	<xsl:template name="dvt_1.rowview">
		<li class="left_nav">
		<xsl:choose>
			<xsl:when test="@Class = 'Header'">
				<xsl:attribute name="class">left_nav level0</xsl:attribute>
				<xsl:choose>
					<xsl:when test="@URL != ''">
						<xsl:choose>
							<xsl:when test="@Open = 'Yes'">
								<a href="{@URL}" target="_blank"><xsl:value-of select="@Title" /></a>
							</xsl:when>
							<xsl:otherwise>
								<a href="{@URL}" target="_self"><xsl:value-of select="@Title" /></a>
							</xsl:otherwise>
						</xsl:choose>
					</xsl:when>
					<xsl:otherwise>
						<xsl:value-of select="@Title" />
					</xsl:otherwise>
				</xsl:choose>
			</xsl:when>
			<xsl:when test="@Class = 'Level 2'">
				<xsl:attribute name="class">left_nav level2</xsl:attribute>
				<xsl:choose>
					<xsl:when test="@URL != ''">
						<xsl:choose>
							<xsl:when test="@Open = 'Yes'">
								<a href="{@URL}" target="_blank"><xsl:value-of select="@Title" /></a>
							</xsl:when>
							<xsl:otherwise>
								<a href="{@URL}" target="_self"><xsl:value-of select="@Title" /></a>
							</xsl:otherwise>
						</xsl:choose>
					</xsl:when>
					<xsl:otherwise>
						<xsl:value-of select="@Title" />
					</xsl:otherwise>
				</xsl:choose>
			</xsl:when>
			<xsl:otherwise>
				<xsl:attribute name="class">left_nav level1</xsl:attribute>
				<xsl:choose>
					<xsl:when test="@URL != ''">
						<xsl:choose>
							<xsl:when test="@Open = 'Yes'">
								<a href="{@URL}" target="_blank"><xsl:value-of select="@Title" /></a>
							</xsl:when>
							<xsl:otherwise>
								<a href="{@URL}" target="_self"><xsl:value-of select="@Title" /></a>
							</xsl:otherwise>
						</xsl:choose>
					</xsl:when>
					<xsl:otherwise>
						<xsl:value-of select="@Title" />
					</xsl:otherwise>
				</xsl:choose>
			</xsl:otherwise>
		</xsl:choose>
		</li>
	</xsl:template>
</xsl:stylesheet>