Docbook XSL style sheets

Figure 727. Hooking into XSL Slide presentation
Hooking into XSL

Figure 728. Categories Slide presentation
  • Adding Javascript

    • Touch gestures

    • Dynamic elements

  • Embedded objects

  • Headers and footers

    • Company logo

    • Navigation icons

  • Front page


Figure 729. Example: videos Slide presentation
  <xsl:template match="d:videodata">
    <video controls="controls" preload="auto">
      <xsl:attribute name="title">
        <xsl:value-of select="normalize-space(../../../d:title)"/>
      </xsl:attribute>

      <xsl:variable name="imageFilename">
        <xsl:call-template name="mediaobject.filename">
          <xsl:with-param name="object" select=".."/>
        </xsl:call-template>
      </xsl:variable>

      <source src="{$imageFilename}" type='video/mp4' />
      <source src="{$imageFilename}.ogv"/>
    </video>
  </xsl:template>