[oXygen-user] Re: complex xpath

George Cristian Bina
Fri Feb 18 07:51:35 CST 2005


Hi Sean, David,

We added support for defining in options proxy to namespace mappings 
that will take precedence over the ones defined in the document so 
basically now any namespace can be accessible via a proxy without the 
need to define that proxy in the document.

The current version of oXygen (5.1) detects a default namespace and maps 
that to the first available proxy from {default, default1, etc.} but in 
the case Sean mentioned default:CVSRepository does not work because 
there is another default namespace for an element before the 
CVSRepository element and default is mapped to that.

Best Regards,
George
---------------------------------------------------------------------
George Cristian Bina
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com


David Sewell wrote:
> On Sat, 22 Jan 2005  wrote:
> 
>> Date: Sat, 22 Jan 2005 18:23:02 +0200
>> From: Sean Wheller <>
>> Subject: [oXygen-user] complex xpath
>>
>> Using the following document as a study
>> http://www.gnome.org/~shaunm/doctable/doaproll.rdf
>>
>> My question is how to perform an XPath that will return all CVSRepository
>> nodes. I try //CVSRepository and get "XPath returned no results".
>>
>> Any hints should be documented and added to Oxygen Help.
> 
> 
> The problem is an XPath one and not an oXygen one. In your XML document, 
> each "<Project>" element is assigned to a namespace without a prefix, 
> making it impossible to find its subelements using XPath. Try adding 
> this attribute to your root RDF element:
> 
>         xmlns:prj="http://www.gnome.org/~shaunm/faux-doap"
> 
> then you can use the XPath expression
> 
>   //prj:CVSRepository
> 
> and find the elements.
> 
> DS
> 



More information about the oXygen-user mailing list