<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE xsl:stylesheet [
<!ENTITY nbsp   "&#160;">
<!ENTITY lsaquo   "&#8249;">
<!ENTITY apos   "&#39;">
<!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:fn="http://omniupdate.com/XSL/Functions"
    xmlns:ouc="http://omniupdate.com/XSL/Variables"
    
    exclude-result-prefixes="ou xsl xs fn ouc"
    >
    
    <xsl:import href="../_shared/template-matches.xsl" />
    <xsl:import href="../_shared/force-self-closing.xsl" />
    <xsl:import href="../_shared/variables.xsl" />
    <xsl:import href="../_shared/functions.xsl" />
    
    <!-- 	<xsl:output method="html" version="4.0" indent="no" encoding="UTF-8" include-content-type="no" omit-xml-declaration="yes"/> -->
    <xsl:output method="xml" version="1.0" omit-xml-declaration="yes"/>
    <xsl:strip-space elements="*"/>
    
    <xsl:template match="/document">
        <xsl:choose>
            <xsl:when test="$ou:action = 'pub'">
                <xsl:call-template name="content" />
            </xsl:when>
            <xsl:otherwise>
                <xsl:call-template name="preview" />
            </xsl:otherwise>
        </xsl:choose>
    </xsl:template>
    
    <xsl:template name="common-headcode">
        <xsl:copy-of select="ou:include-file('/_resources/includes/headcode.inc')" />
    </xsl:template>
    
    <xsl:template name="template-headcode">
        <!--<script>
			(function() {
			var cx = 'partner-pub-2789521296837340:9402765321';
			var gcse = document.createElement('script');
			gcse.type = 'text/javascript';
			gcse.async = true;
			gcse.src = (document.location.protocol == 'https:' ? 'https:' : 'http:') +
			'//www.google.com/cse/cse.js?cx=' + cx;
			var s = document.getElementsByTagName('script')[0];
			s.parentNode.insertBefore(gcse, s);
			})();
		</script>
		<script>
			$( document ).ready(function() {
			
			$( "div.button" ).click(function() {
			$( "form#cse-search-box" ).submit();
			return false;
			});
			
			
			});
		</script>-->
    </xsl:template>
    
    <xsl:template name="preview">
        <html>
            <head>
                <title>Global Header PCF to Include</title>
                <xsl:if test="$ou:action != 'edt'">
                    <xsl:call-template name="common-headcode" />
                </xsl:if>
                <xsl:if test="$ou:action = 'edt'">
                    <xsl:copy-of select="ou:include-file('/_resources/includes/headcode.inc')"/>
                </xsl:if>
            </head>
            <body>
                <xsl:call-template name="content" />
                
                <xsl:if test="$ou:action = 'edt'">
                    <xsl:copy-of select="ou:include-file('/_resources/includes/footcode.inc')"/>
                </xsl:if>
            </body>
        </html>
    </xsl:template>
    
    <xsl:template name="content">
        <img class="secondaryHeader" border="0" src="/_resources/images/header-sm-secondary.jpg" alt="Winthrop University Masthead" usemap="#homePageMap" />
        
        <!-- Email and Wingspan links -->
        <div class="secondaryWhiteTopLinks">
            <a class="whiteTextLinks" href="{ou:pcf-param('utility-link-1')}" target="_blank"><xsl:value-of select="ou:pcf-param('utility-link-1-text')"/></a>
            <a class="whiteTextLinks" href="{ou:pcf-param('utility-link-2')}" target="_blank"><xsl:value-of select="ou:pcf-param('utility-link-2-text')"/></a>
        </div>
        
    </xsl:template>
    
  
</xsl:stylesheet>
