<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE xsl:stylesheet [
<!ENTITY nbsp   "&#160;">
<!ENTITY lsaquo   "&#8249;">
<!ENTITY rsaquo   "&#8250;">
<!ENTITY laquo  "&#171;">
<!ENTITY raquo  "&#187;">
<!ENTITY copy   "&#169;">
]>
<xsl:stylesheet version="3.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:ou="http://omniupdate.com/XSL/Variables"
xmlns:ouc="http://omniupdate.com/XSL/Variables"
exclude-result-prefixes="xs ou ouc">
	
	<!-- implementation variables and functions -->
	<xsl:import href="../_shared/variables.xsl" />
	<xsl:import href="../_shared/functions.xsl"/>
	<!-- faculty directory specific variables -->
	<xsl:import href="variables.xsl" />
	<!-- faculty directory specific functions -->
	<xsl:import href="functions.xsl" />
	
	<xsl:output method="xml" version="1.0" include-content-type="yes" />
	
	<!-- declaring mode and removing the pcf stylesheet from the matches -->
	<xsl:mode on-no-match="shallow-copy" />
	<xsl:template match="processing-instruction('pcf-stylesheet')" mode="#all" />
	
	<!-- individual profile xml -->
	<xsl:template match="/document">
		<xsl:choose>
			<!-- individual profile -->
			<xsl:when test="profile">
				<xsl:copy-of select="ou:get-profile(.)" />
			</xsl:when>
			<!-- listing xml -->
			<xsl:otherwise>
				<xsl:copy-of select="$all-profiles" />
			</xsl:otherwise>
		</xsl:choose>
	</xsl:template>
</xsl:stylesheet>
