cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Martin Holz <h...@fiz-chemie.de>
Subject Re: xmldb logicsheet ?
Date Mon, 11 Feb 2002 17:19:12 GMT
Yann Secq wrote:
> heli wrote:

> I could access the file by just pointing this URL :
> http://<your_host_name>:8080/cocoon/xmldb/db/fm2/prj-4
>
> What I get here is the XML file, then I have to write a
> stylesheet that translate it to HTML.
>
> If you try the following URL :
> http://<your_host_name>:8080/cocoon/xmldb/db/fm2
> you get a list of <collection:resource> elements which
> have one attribute 'name' which is the name of the file :
> In my case :
> <collection:collections>
>    <collection:resource name="prj-1"/>
>    <collection:resource name="prj-2"/>
>    <collection:resource name="prj-3"/>
>    <collection:resource name="prj-4"/>
> </collection:collections>
>
> For the moment, I haven't found how to retrieve XML
> documents through an XPath query. If anyone knows, I'll be
> glad to know as well :)

http://<your_host_name>:8080/cocoon/xmldb/db/fm2?xpath='/html/body/h1'

or any other xpath expression. Note, that you must encode the URL, if the 
xpath expression contains characters, whicha are illegal in a URL, most 
notable '='.
 	

---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <cocoon-users-unsubscribe@xml.apache.org>
For additional commands, e-mail: <cocoon-users-help@xml.apache.org>


Mime
View raw message