[XSL-LIST Mailing List Archive Home]
[By Thread]
[By Date]
RE: [xsl] How to use caracter " in a String
Subject: RE: [xsl] How to use caracter " in a String From: "Andrew Welch" <awelch@xxxxxxxxxxxxxxx> Date: Tue, 25 Jun 2002 16:28:22 +0100 |
Tom P: ><xsl:value select='I want to say "Hello"'/> This won't work ><xsl:value-of select="I want to say "Hello""/> Nor will this. ><xsl:value-of select " 'I want to say "Hello"' "/> This will. (I know you know really Tom, but for everyone else...) The bit between the quotes is a node test, so when you say: <xsl:value-of select="worldcup"/> You are saying 'give me the content of the node <worldcup>', whatever that may be. If you want the string 'worldcup' in your output [as part of a select statement] then you need to enclose it in quotes to identify it as a string: <xsl:value-of select="'worldcup'"/> ^ ^ This tells the processor its a string and not the name of a node. If you then want it to be wrapped in quotes in your output, you need to insert some escaped quotes around it: <xsl:value-of select="'"worldcup"'"/> and that will give you "worldcup" cheers andrew --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.350 / Virus Database: 196 - Release Date: 17/04/2002 XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] How to use caracter " in , Andrew Welch | Thread | Re: [xsl] How to use caracter " in , Thomas B. Passin |
Re: [xsl] functional / declarative, James Fuller | Date | Re: [xsl] Need Thread From Mailing , Antonio Fiol |
Month |