2.4.1.2 XSL Root Template

The starting element for the EBNF notation is XSL_STYLE_SHEET.

 XSL_STYLE_SHEET ::=
 <?xml version="1.0" encoding="UTF-8"?>
 <xsl:stylesheet version="1.0" 
     (XML_NAMESPACE)*
     xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
     (xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance")? 
     (xmlns:xd="http://schemas.microsoft.com/office/infopath/2003")?
     (xmlns:msxsl="urn:schemas-microsoft-com:xslt")? 
     (xmlns:x="urn:schemas-microsoft-com:office:excel")? 
     (xmlns:xdExtension="http://schemas.microsoft.com/office/infopath/2003/xslt/extension")? 
     (xmlns:xdXDocument="http://schemas.microsoft.com/office/infopath/2003/xslt/xDocument")? 
     (xmlns:xdSolution="http://schemas.microsoft.com/office/infopath/2003/xslt/solution")? 
     (xmlns:xdFormatting="http://schemas.microsoft.com/office/infopath/2003/xslt/formatting")? 
     (xmlns:xdImage="http://schemas.microsoft.com/office/infopath/2003/xslt/xImage")? 
     (xmlns:xdUtil="http://schemas.microsoft.com/office/infopath/2003/xslt/Util")? 
     (xmlns:xdMath="http://schemas.microsoft.com/office/infopath/2003/xslt/Math")? 
     (xmlns:xdDate="http://schemas.microsoft.com/office/infopath/2003/xslt/Date")? 
     (xmlns:sig="http://www.w3.org/2000/09/xmldsig#")?     (xmlns:xdSignatureProperties="http://schemas.microsoft.com/office/infopath/2003/SignatureProperties")? 
     (xmlns:ipApp="http://schemas.microsoft.com/office/infopath/2006/XPathExtension/ipApp")?       
     (xmlns:xdEnvironment="http://schemas.microsoft.com/office/infopath/2006/xslt/environment")?
     (xmlns:dfs="http://schemas.microsoft.com/office/infopath/2003/dataFormSolution")?
     (xmlns:xsf="http://schemas.microsoft.com/office/infopath/2003/solutionDefinition")?
   (xmlns:xsf2="http://schemas.microsoft.com/office/infopath/2006/solutionDefinition/extensions")?     
     (xmlns:xsd="http://www.w3.org/2001/XMLSchema")?
     (xmlns:xhtml="http://www.w3.org/1999/xhtml")? 
     (xmlns:xdUser="http://schemas.microsoft.com/office/infopath/2006/xslt/User")? >
     <xsl:output method="html" indent="no"/>
     <xsl:template match="GROUP_XPATH">
         <html (dir="HTML_DIR")?>
             <head>
                (HTML_COMMENTS)?
                <meta http-equiv="Content-Type" content="text/html"></meta>
                (CONTROL_STYLE)?
                TABLE_STYLE
                LANGUAGE_STYLE
                (THEME_STYLE)?
             </head>
             <body (style="CSS1_STYLE")? (background="IMAGE_FILE")? 
                 (scroll="auto")?>MAIN_BODY</body>
         </html>
     </xsl:template>
     (SECTION_BODY | REPEATING_SECTION_BODY)* 
 </xsl:stylesheet>
  
 MAIN_BODY ::= XML_HTML_4_1_WITH_CONTROLS | 
 <span>
     <xsl:attribute name="style">
         (<xsl:if test="BOOLEAN_XPATH_EXPRESSION">STYLE_DISABLE_CHILD_XML_TO_EDIT</xsl:if>)+
     </xsl:attribute>
     XML_HTML_4_1_WITH_CONTROLS 
 </span>

XML_HTML_4_1_WITH_CONTROLS: MUST be an HTML 4.1 fragment, as specified in [HTML], valid under the BODY element that is also a valid XML 1.0 fragment, as specified in [W3C-XML]. If an element inside the fragment contains the xd:xctname attribute, it MUST conform to one of the control productions specified for controls in section 2.4.1.5 to section 2.4.1.20. If the fragment contains an XSL element with the syntax of SECTION_CALL, it MUST be located only in the locations where a <DIV/> element, as specified in [HTML] section 7.5.4, could also be placed.

SECTION_CALL: SIMPLE_SECTION_CALL | OPTIONAL_SECTION_CALL | REPEATING_SECTION_CALL

HTML_COMMENTS: MUST be a concatenation of one or more HTML 4.1 comments, as specified in [HTML] section 3.2.4.

HTML_DIR: The values MUST be as specified in [HTML] section 8.2.

IMAGE_FILE: MUST be the name of an image file, as specified in [CSS-LEVEL1] section 5.3.7. The image file MUST be present in the form template. See section 2.2.98.