summaryrefslogtreecommitdiff
path: root/doc/yelp-xsl/C/html.page.page
blob: 1e5ce99a1a9417b5bd29fe9ae86481c801ed8060 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
<?xml version="1.0"?>
<page xmlns="http://projectmallard.org/1.0/" id="html.page" type="topic" style="xslt-template"><info><link type="guide" xref="html" group="templates"/><link type="guide" xref="templates" group="html"/><revision version="3.28" date="2017-08-04" status="final"/><desc>Create an HTML document.</desc></info><title>html.page</title><p>Create an HTML document.</p>
  
  
  <synopsis><title>Parameters</title><terms>
    <item>
      <title><code>node</code></title>
      <p>The node to create HTML for.</p>
    </item>
  </terms></synopsis>
  <p>This template creates the actual HTML output for <code style="xslt-param">node</code>. It outputs top-level elements and container divs, and calls various templates and modes to output the inner content. Importing stylesheets should implement at least <code style="xslt-mode" xref="html.title.mode">html.title.mode</code> and <code style="xslt-mode" xref="html.body.mode">html.body.mode</code> for any elements that could be passed as <code style="xslt-param">node</code> to this template. Importing stylesheets should also implement <code style="xslt-mode" xref="html.header.mode">html.header.mode</code> to output link trails and <code style="xslt-mode" xref="html.footer.mode">html.footer.mode</code> to output credits and other page information.</p>
  <p>This template outputs the HTML <code>body</code> element, which takes it attributes from two sources. First, it calls <code style="xslt-template" xref="html.lang.attrs">html.lang.attrs</code>, which automatically outputs correct <code>lang</code>, <code>xml:lang</code>, and <code>dir</code> attributes. It then calls <code style="xslt-mode" xref="html.body.attr.mode">html.body.attr.mode</code> on <code style="xslt-param">node</code> for additional attributes.</p>
  <p>This template also calls a number of stub templates that can be overridden by extension stylesheets. Override the <code style="xslt-template" xref="html.head.custom">html.head.custom</code> template to put custom content at the end of the HTML <code>head</code> element. Override the <code style="xslt-template" xref="html.head.top.custom">html.head.top.custom</code> template to put custom content at the beginning of the HTML <code>head</code> element. Override the <code style="xslt-template" xref="html.top.custom">html.top.custom</code> and <code style="xslt-template" xref="html.bottom.custom">html.bottom.custom</code> templates to add site-specific content at the top and bottom of the page. Override the <code style="xslt-template" xref="html.header.custom">html.header.custom</code> and <code style="xslt-template" xref="html.footer.custom">html.footer.custom</code> templates to provide additional content directoy above and below the main content. Use the <code style="xslt-param" xref="html.sidebar.left">html.sidebar.left</code> and <code style="xslt-param" xref="html.sidebar.right">html.sidebar.right</code> parameters to create stock sidebars, or override <code style="xslt-template" xref="html.sidebar.custom">html.sidebar.custom</code> to create your own.</p>
  <p>This template also calls <code style="xslt-template" xref="html.css">html.css</code> and <code style="xslt-template" xref="html.js">html.js</code> to output CSS and JavaScript elements. See those templates for further extension points.</p>
<list style="compact"><title>Calls Templates</title><item><p><link xref="html.head.top.custom"/></p></item><item><p><link xref="html.sidebar"/></p></item><item><p><link xref="html.header.custom"/></p></item></list><list style="compact"><title>Calls Modes</title><item><p><link xref="html.body.attr.mode"/></p></item><item><p><link xref="html.body.mode"/></p></item><item><p><link xref="html.footer.mode"/></p></item><item><p><link xref="html.header.mode"/></p></item><item><p><link xref="html.title.mode"/></p></item></list></page>