Subject: [xsl] Subsection Formatting From: "Jack Cane" <jwcane@xxxxxxxxxxx> Date: Thu, 27 Jun 2002 22:26:40 -0400 |
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. Would appreciate some feedback on where I am going wrong here. ======================================== Here is the xsl content: <?xml version = "1.0"?> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns="dissertation.dtd" xmlns:html="http://www.w3.org/1999/xhtml" version="1.0"> <xsl:template match="SubSection"> <h3><xsl:value-of select="ssHdr"/></h3> <p><xsl:value-of select="TextPara"/></p> </xsl:template> <xsl:template match="Introduction"> <html> <head> <title> <xsl:value-of select="IntroTitle"/> </title> <link rel="stylesheet" href="novabasic.css" type="text/css"/> </head> <body> <h2 align="center"><xsl:value-of select="IntroTitle"/></h2> <xsl:value-of select="ProbStmt"/> <h3><xsl:value-of select="ssHdr"/></h3> </body> </html> </xsl:template> </xsl:stylesheet> ======================================== And here is the relevant part of the dtd: <!ELEMENT SubSection (ssHdr, TextPara+)> <!ELEMENT ssHdr (#PCDATA)> <!ELEMENT TextPara (#PCDATA)> <!ELEMENT Section (SectHdr, SubSection+)> <!ELEMENT SectHdr (#PCDATA)> <!ELEMENT SubSect (SubSection)> <!ELEMENT Chapter (ChapHdg, Section+)> <!ELEMENT ChapHdg (#PCDATA)> <!ELEMENT Sect (Section)> <!ELEMENT Introduction (IntroTitle, ProbStmt)> <!ELEMENT IntroTitle (SectHdr)> <!ELEMENT ProbStmt (SubSection)> ======================================== tks, jwc XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] Silicon Valley XSLT event: XS, Wes Lagrone | Thread | Re: [xsl] Subsection Formatting, Joerg Heinicke |
[xsl] Silicon Valley XSLT event: XS, Wes Lagrone | Date | [xsl] Checking value of a previous , Ryan O'Leary |
Month |