to the main page... about these slides...

Example: article2html.xsl, Part I

The first part of the stylesheet:
<?xml version="1.0"?>
  This is a small example XSLT stylesheet transforming ArticleML documents into HTML.
  The example is incomplete: important things like citation references
  are still missing. (Exercise to the reader: use xsl:variable,
  xsl:sort, and xsl:number to finish the parts about citation references.)
<xsl:stylesheet xmlns:xsl="" version="1.0">

<xsl:variable name="style">my-style</xsl:variable>

<xsl:output method="html" indent="no"/>

<xsl:key name="idkey" match="*[@id]" use="@id"/>


<xsl:template match="article">
    <title><xsl:apply-templates select="title" mode="raw"/></title>
    <xsl:call-template name="{$style}"/>
    <xsl:call-template name="header"/>
    <h1><xsl:apply-templates select="title" mode="raw"/></h1>
    <xsl:apply-templates select="authors"/>
    <xsl:apply-templates select="abstract"/>
    <xsl:apply-templates select="section"/>
    <xsl:apply-templates select="references"/>
    <xsl:apply-templates select="vitae"/>
<xsl:comment>this HTML page was generated by article2html.xsl</xsl:comment>