forrest-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Miroslav Mocek <>
Subject Re: Using XML db as the source of xml files
Date Wed, 05 Oct 2005 22:22:18 GMT
ok, I am really lost, so I tried to get first DirectoryGenerator 
running. (should be simpler, I hope)

I wasn't successfull. What I did:

I've created subdir "my" in content/xdocs and put 2 files in it - 
first.xml and second.xml (which are just easier versions of index.xml now)

I've put this 3 lines in my sitemap.xmap. (found in
<map:match pattern="my*">
    <map:generate src="my"/>

before the
   <map:match pattern="**.xml">

I've created element in site.xml:
<dirLink label="myaddr" href="my/" />

And used the link in index.xml as:
<link href="site:dirLink">link for my dir</link>.

The link is transformed as http://localhost:8888/my/ - it's ok.
But when I click on the link, I get 'The requested resource "/my/" could 
not be found.'

I think, my sitemap.xmap configuration is wrong. But I cannot find any 
documentation how to do it right.
Any suggestions?
Thanks Mirek

Ross Gardler wrote:

> Miroslav Mocek wrote:
>> Hello,
>> I have a set of XML files (in my own vocabulary) in some directory 
>> structure. I was thinking of generating my site from the files. (I 
>> would definitely need the recursing directory approach, because there 
>> is a lot of files and it will be dynamic archive. As stated in user 
>> maillist - 'create a custom sitemap entry that uses the 
>> DirectoryGenerator from Cocoon'. Well, I'm not quite sure, how to get 
>> that working...)
>> But now I'm thinking about converting the whole directory structure 
>> with files into native XML db (xindice - or do you know better? I am 
>> really new in this topic). And use forrest to generate the site from 
>> the XML db.
>> Is THAT possible? As I read documentation, it could be. Forrest 
>> documentation says: 'one can - Read content from exotic sources like 
>> XML databases'. Had someone already tried that?
> Yes, it is possible. How you do it depends on the interfaces made 
> available by your chosen database.
> If there is an http api then you can simply use the locationmap in 
> 0.8-dev, or a custom sitemap in 0.7
> If there is no http api you will need a Cocoon generator to read the 
> files from the DB (this will, most likely, be faster than the 
> locationmap/sitemap technique too).
> Cocoon has an XML:DB block, you can probably leverage that [1]
> Ross
> [1] 

View raw message