[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: mixed-content values
Assuming you want to output text/plain but not iso-8859-1 then you need to use templates. <xsl:template match = "Content-Type//textnode()"> <xsl:value-of /> </xsl:template> <xsl:template match = "Content-Type/charset"> <!-- leave this empty so it doesn't get processed --> </xsl:template> <xsl:template match = "Content-Type> <xsl:apply-templates /> </xsl:tempate> > -----Original Message----- > From: Borden, Jonathan [SMTP:jborden@xxxxxxxxxxxx] > Sent: Sunday, January 24, 1999 3:29 PM > To: XSL-List > Subject: mixed-content values > > hello, > > I am trying to ouput the text in a mixed content element using XSL > but I'm > not sure how to specify the PCDATA part without the text from child > elements. For example > > <Content-Type><charset>iso-8859-1</charset>text/plain</Content-Type> > > What I would like to do is: > <xsl:choose><xsl:when match="Content-Type[text() = 'text/plain']"> > ... > > but this yeilds: "iso-8859-1text/plain" > > or even: > > <xsl:value-of select="Content-Type/text()" /> > > but I get an error (i am using IE5b2) > > Jonathan Borden > http://jabr.ne.mediaone.net > > > XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list 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
|