This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
RE: escaping from CDATA
- To: <xsl-list at lists dot mulberrytech dot com>
- Subject: RE: [xsl] escaping from CDATA
- From: "Michael Kay" <mhkay at iclway dot co dot uk>
- Date: Fri, 26 Oct 2001 14:46:33 +0100
- Reply-To: xsl-list at lists dot mulberrytech dot com
> Thanks Jeni. I got a version of the following to work but I don't
> understand why I need the reference to string() - isn't that the
> problem that my node is text in the first place - why do I have
> to convert it to a string?
Within XPath and XSLT, a node-set consisting of a single text node can be
used anywhere that a string is expected. But not when you call JavaScript;
your JavaScript function is expecting a string, and it doesn't know what to
do if you give it a node-set instead.
Mike Kay
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list