|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Subsection Formatting
<xsl:template match="SubSection"> <xsl:apply-templates/> </xsl:template> <xsl:template match="ssHdr"> <h3><xsl:apply-templates/></h3> </xsl:template> <xsl:template match="TextPara"> <p><xsl:apply-templates/></p> </xsl:template> <xsl:template match="Introduction">
<html>
<head>
<title>
<xsl:apply-templates select="IntroTitle"/>
</title>
<link rel="stylesheet" href="novabasic.css" type="text/css"/>
</head>
<body>
<h2 align="center"><xsl:apply-templates select="IntroTitle"/></h2>
<xsl:apply-templates select="ProbStmt"/>
<!-- where does ssHdr come from? there is no ssHdr in DTD -->
<h3><xsl:value-of select="ssHdr"/></h3>
</body>
</html>
</xsl:template>For a more or less arbitrary XML code, it's mostly better to use <xsl:apply-templates/> instead of <xsl:value-of/>. Your problem was the <xsl:value-of select="ProbStmt"/>, which returns a concatenated string of all the descendant text nodes in <ProbStmt/>. Regards, Joerg Jack Cane wrote: I'm quite new at xml/xslt. Have created a dtd and style sheet which work, to a point. The problem is with separation and formatting of subsection elements. At present the subsection title and all text paragraphs are in one paragraph. XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|






