xsl-list
[Top] [All Lists]

[xsl] text()

2014-03-24 22:05:37
Dear XSLT List,

I'm almost afraid to enter this discussion because it has wandered off in
non-productive and sometimes embarrassing directions, but I'll take a
chance and hope that I can say something constructive and useful and that
any responses (not that any are required or expected) will stay on target:
What I found confusing about text() when I first began learning XPath is
that it ends with a pair of parentheses, like string(), which led me to
the erroneous assumption that it was a function, like string(), and not a
node test, like *. That's not a complaint about XPath syntax or even an
inquiry about why things are the way they are. It's just an observation
that in a world where many things that end in a pair of parentheses are
functions, it perhaps shouldn't be surprising that beginners
overgeneralize and assume, incorrectly, that parentheses imply a function
and that text(), therefore, is a function that says "give me all of the
textual content (that is, the string value) of something."

Best,

David


--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--


<Prev in Thread] Current Thread [Next in Thread>