Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: Counting self axes

From: "Dimitre Novatchev" <x@---.--->
To: NULL
Date: 8/1/2005 8:47:00 PM
"Joris Gillis" <roac@p...> wrote in message 
news:op.suui5kohyf9v9r@n......
> Hi,
> Tempore 20:28:59, die Monday 01 August 2005 AD, hinc in foro 
> {comp.text.xml} scripsit <rob.guitar.rob@g...>:
>
>> This may be a stupid question, but if you count a self axe will it
>> always return 1?
>
> No, not always.
> This will only return 1 if the context node is a node which has a qname: 
> i.e. elements and processing instructions.

That's not correct.

1)    self::* selects the current node only if it is an element.; not if it 
is a processing instruction.

If the current node is a processing instruction, then the following 
expression (using the "self" axis) selects the current node:

2)    self::processing-instruction()

3)    Regardless of the type of the node, it is selected by:

       self::node()



Cheers,
Dimitre Novatchev


>  Not all XSLT - implementations follow this though: AltovaXSLT allows 
> attributes as well.
>
> regards,
> -- 
> Joris Gillis (http://users.telenet.be/root-jg/me.html)
> Deserta faciunt et innovationem appelant 




transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent