Re: [xml] XPath question



Igor Zlatkovic wrote:
Whoever produces XML of the sort

  ...
  <a xmlns="foo">
    <n/>
  </a>
  <a xmlns="bar">
    <n/>
  </a>
  ...

should be made aware of the fact that the thing cannot be processed efficiently. Using namespace prefixes solves this without changing anything about the data the document contains.

I don't understand how using namespace prefixes solves anything. For your example we can imagine an well-formed fragment

<x:a xmlns:x="foo:">
  <x:n/>
</x:a>
<x:a xmlns:x="bar:">
  <x:n/>
</x:a>

You still need to refer to the namespace URI (which, by the way, must be a URI unlike in your example) in order to differentiate the two instances of x:a.
--
Chris Burdess




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]