xsl-list
[Top] [All Lists]

Re: [xsl] Pattern "node()" and document nodes

2010-02-25 10:59:36
On Thu, Feb 25, 2010 at 10:03 PM, David Carlisle 
<davidc(_at_)nag(_dot_)co(_dot_)uk> wrote:
Mukul's code shows that the node test node() is true for document nodes, but
the pattern node() doesn't match document nodes for the same reason that the
xpath expression node() doesn't select document nodes.
in both cases they are abbreviations of child::node() and document nodes are
never children.

I agree. <xsl:template match="node()" .. or say, xsl:value-of
select=""node()/.. etc can never select a document node with pattern,
node() (as you rightly said, that in these cases, node() is an
abbreviation for, child::node()).

But the test ". instance of node()" returns true for document node,
because document node is a kind of node.

Thanks, for the clarification.


-- 
Regards,
Mukul Gandhi

--~------------------------------------------------------------------
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>
--~--