I'm doing exactly this!!

Again - I'm new to cocoon so take with a pinch of caution :)

The problem with <aggregate> is that the aggregate mechanism allows the
creation of a very complex piece of XML.
The xslt must then transform the whole complex set - whenever you change the
components that are aggregated you must change the template.

I took the approach:
<map:match>
 <map:generate type="..." src="..."/>
 (I used Velocity here - it just has to output the basic XHTML template with
cincludes for the components)
 (eg: <cinclude:include src="cocoon:/menus/sidebar?area=/aboutus"/>)
 (you could certainly use #foreach to generate multiple <cinclude> tags
dynamically)
 <map:transform type="cinclude"/>
 (the cinclude now extends the XHTML template with other cocoon:/...
pipelines)
 <map:serialise/>
</map:match>

The cincluded components can read/set cookies, read the real http request
parameters and any 'private' cinclude parameters (which could be dynamically
generated).

Notice that the interim pages must be valid XHTML.

Later into the development there's a 'private' flag that stops these URLs
being seen from external HTTP reqs

Hope this helps - I have examples if required.

David



> -----Original Message-----
> From: Bertrand Delacretaz [mailto:[EMAIL PROTECTED]]
> Sent: 20 December 2001 07:17
> To: [EMAIL PROTECTED]
> Subject: Re: Can a Transformer include multiple HTML documents?
> 
> 
> On Thursday 20 December 2001 08:05, Bartomeu Adrover wrote:
> > Hello, my idea is: create "n" pipelines that acces to the 
> url's and get
> > html documents into xhtml. After that create an pipeline 
> that include all
> > this sources:
> 
> Thanks for the idea - it will work if you have a known set of 
> "HTML URLs" to 
> access, but in my case it's dynamic: the HTML URLs  are 
> computed based on the 
> initial request, and their number and form can vary.
> 
> What I'm missing is something like "dynamic sitemap 
> aggregation", but maybe 
> there is another way?
> 
> - Bertrand
> 
> ---------------------------------------------------------------------
> 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: <[EMAIL PROTECTED]>
> For additional commands, e-mail: <[EMAIL PROTECTED]>
> 

---------------------------------------------------------------------
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: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>

Reply via email to