|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] first char of first word of first paragraph
Hi,
I am a newbie in xsl, and I have a problem. 1. What I want to do is to select every first paragraph of all chapters 2. Select the first word with grep., and then select the rest of the text
the desired output
<chapter id="c1">
<setion>
<para>
<FirstChar>S</FirstChar><Smallcaps>MALLCAPS WORD PARA 1
</Smallcaps><RestOfPara>text etc.</RestOfPara>
</para>
</setion>
</chapter>--- The following xsltfile works, at least with libxslt. <!--Select the first paragraph of all chapters--> <xsl:template match="//chapter/section[1]/para[1]" priority="1"> <xsl:call-template name="FirstWord"> <xsl:with-param name="string" select="."/> </xsl:call-template> </xsl:template> <!--Select all paragraphs--> <xsl:template match="//para"> <xsl:call-template name="para.template"> </xsl:call-template> </xsl:template>
But how can I do this with grep?
|
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
|

Cart








