﻿<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

    <xsl:import href="BrandMemoControl.xslt"/>

    <xsl:output method="xml" indent="yes"/>

    <xsl:template match="/">
        <xsl:variable name="BrandProfileID" select="normalize-space(Brand/HeaderFooterHTML/BrandProfileID)"></xsl:variable>
        <xsl:variable name="BrandID" select="normalize-space(Brand/HeaderFooterHTML/BrandID)"></xsl:variable>
        <xsl:variable name="BrandTabID" select="normalize-space(Brand/HeaderFooterHTML/BrandTabID)"></xsl:variable>
        <xsl:variable name="BrandProfileSectionID" select="normalize-space(Brand/HeaderFooterHTML/BrandProfileSectionID)"></xsl:variable>
        <xsl:variable name="SortOrder" select="normalize-space(Brand/HeaderFooterHTML/SortOrder)"></xsl:variable>
        <xsl:variable name="Section" select="normalize-space(Brand/HeaderFooterHTML/Section)"></xsl:variable>
        <xsl:variable name="SectionName" select="normalize-space(Brand/HeaderFooterHTML/SectionName)"></xsl:variable>
        <xsl:variable name="SectionHTML" select="normalize-space(Brand/HeaderFooterHTML/SectionHTML)"></xsl:variable>
        <xsl:variable name="SectionSummary" select="normalize-space(Brand/HeaderFooterHTML/SectionSummary)"></xsl:variable>
        <xsl:variable name="TimeStamp" select="normalize-space(Brand/HeaderFooterHTML/TimeStamp)"></xsl:variable>
        <xsl:variable name="BrandPermissionID" select="normalize-space(Brand/HeaderFooterHTML/BrandPermissionID)"></xsl:variable>

        <div id="divFooterHTML">
            <div>
                <xsl:value-of select="Brand/HeaderFooterHTML/SectionHTML" disable-output-escaping="yes"/>
            </div>
            <div style="margin-top:5px;">
                <input type="button" value="Edit" class="button" id="btnEditBrandFooter" style="display:none;"
                       onclick="Brand_SectionEdit('divFooterHTMLContainer','divBrandFooterProfileOperations');"/>
            </div>
            <div id="divBrandFooterProfileOperations" class="divEdit">
                <xsl:call-template name="BrandMemo">
                    <xsl:with-param name="BrandProfileID" select="$BrandProfileID"></xsl:with-param>
                    <xsl:with-param name="BrandID" select="$BrandID"></xsl:with-param>
                    <xsl:with-param name="BrandTabID" select="$BrandTabID"></xsl:with-param>
                    <xsl:with-param name="BrandProfileSectionID" select="$BrandProfileSectionID"></xsl:with-param>
                    <xsl:with-param name="SortOrder" select="$SortOrder"></xsl:with-param>
                    <xsl:with-param name="Section" select="$Section"></xsl:with-param>
                    <xsl:with-param name="SectionName" select="$SectionName"></xsl:with-param>
                    <xsl:with-param name="SectionHTML" select="$SectionHTML"></xsl:with-param>
                    <xsl:with-param name="SectionSummary" select="$SectionSummary"></xsl:with-param>
                    <xsl:with-param name="TimeStamp" select="$TimeStamp"></xsl:with-param>
                    <xsl:with-param name="BrandPermissionID" select="$BrandPermissionID"></xsl:with-param>
                    <xsl:with-param name="DivOperationID">
                        <xsl:text>divBrandFooterProfileOperations</xsl:text>
                    </xsl:with-param>
                    <xsl:with-param name="DivContainerID">
                        <xsl:text>divFooterHTMLContainer</xsl:text>
                    </xsl:with-param>
                </xsl:call-template>
            </div>
        </div>


    </xsl:template>
</xsl:stylesheet>
