Ingo Schildmann

Greenhorn
+ Follow
since Sep 20, 2000
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Ingo Schildmann

I guess SuSe isn't allowed to deliver SUN's Java for Linux and therefore
delivers the Blackdown Java.
20 years ago

Your test translates to:
Is there any element in the tree that has a child element named 'person' that has an attribute named 'gender' with value 'female' ?
Which is true of course as long as there aren't
just males.
With // you are selecting all elements in tree.
This nodeset is then filtered with the predicate [person/@gender=female] which is evaluated relative to any node of the nodeset.
The filtered nodeset is then evaluated as boolean
for the test, which means the test is only false
when the nodeset is empty.
Copying the first n nodes of a given XML document can be rather complex, so more information like the structure of your document would be helpful.
Maybe you want just the first 5 elements of a flat list instead of every node (including whitespace, comments etc.) of a complex tree.
Why do you think that <xsl:stylesheet/> is a processing instruction?
The XML recommendation and the article you're referring to clearly say, that a processing instruction is something like:
<? pi this is a processing instruction ?>

Originally posted by Mapraputa Is:
XSLT's input is XML, only XML, and nothing besides XML. You can pass session info to XSL stylesheet, if you arrgange it as XML. But why would you do that?


That's not the whole truth. You can also pass parameters to the stylesheet (syntax depending to your processor, but I think it is standardized in JAXP). So you could pass a.e. the system's time.

Originally posted by Mapraputa Is:
I myself wondered why "../Language/$Lang/Title" doesn't work, and it's a deep theoretic question. If I find the asnwer, I'll post it here


That is no mystery. You just can't replace the
NCName that is required as nametest in the step with $Lang's string. Think of them as different data types.
The problem with the DTD (document type definition)
is that it's syntax is different from normal xml,
so parser have to use extra methods to parse the dtd.
That's why schemas are introduced. A schema has the
same function as a DTD but has XML-Syntax.
At the moment DTD is still the standard because
Schemas haven't got the recommended status from
the W3 consortium yet.
Bye, Ingo