1 <?xml version="1.0" encoding="UTF-8"?>
3 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
5 <!-- Define display/content information -->
6 <xsl:output indent="no"/>
7 <xsl:output encoding="UTF-8"/>
8 <xsl:output media-type="text/xml"/>
9 <xsl:output omit-xml-declaration="no"/>
12 <xsl:template match="/">
14 <xsl:apply-templates select="book/chapter"/>
19 <xsl:template match="/book/chapter">
21 <!-- Calculate the URL to the chapter. Store in $chapter_url -->
22 <xsl:variable name="chapter_url">
23 <xsl:value-of select="concat(/book/prepend_chapter,'ch-',title_uri,'.html')"/>
29 <xsl:value-of select="$chapter_url"/>
32 <xsl:apply-templates select="title"/>
37 <!-- Chapter/Section Title -->
38 <xsl:template match="title|chapter/title">
39 <xsl:apply-templates/>