cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Habib Kaci <>
Subject RE: How Acceding request attribute in sitemap
Date Wed, 06 Dec 2006 17:22:45 GMT
thank Simone for very clear response.

I try to use some think not produced yet.

In cocoon 1 the stylesheet location serving to performe the xslt
transformation are determined in the XSP page (may at runtime).

exemple :

	if({third-party test})
		<xsp:pi target="cocoon-process">type="xslt"</xsp:pi>

In cocoon 2, actions are well designed to do third-party test. But the
migration concerns a large number of xsp pages, so a lot of changes.

I'll get a lookup to archives to find something similar.

Thank you.

-----Message d'origine-----
De : Jeroen Reijn []
Envoyé : mercredi 6 décembre 2006 18:14
À :
Objet : Re: How Acceding request attribute in sitemap

Ah it seems I did not read the message correctly. I thought one thing 
happened after each other in the pipeline.

Habib, could you show use the pipeline structure of your request which 
contains the map:parameter name="test"?


Simone Gianni wrote:
> Hi Habib,
> Habib Kaci wrote:
>> Hi,
>>         I want set request attributes in xsp pages, and use them in
>> the sitemap.
>>         I do that in xsp page : <xsp-request:attribute
>> name="toto">tata</xsp-request:attribute>
>>         in the sitemap : <map:parameter name="test"
>> value="{request-attr:toto}"/>
>>         But that doesn't work.  Any idea ?
> This is a quite common misunderstanding. The pipeline processing is a
> two phase process. In the first phase the pipeline is composed, then the
> generator starts generating, transformers transforming and serializers
> serializing.
> Cocoon streams sax events. That means that when you xsp page sends it's
> first element (say <html>), that element is sent to the first
> transformer, which eventually transform it to and then send it to the
> second transformer etc.. etc.. up to the serializer. The serializer
> sends it to the browser, and then the generator generates the second
> element (say <head>) and so on.
> It's not made in single steps (generator generates all XML, transformer
> 1 transforms it, transformer 2 transforms it, serializer serializes it),
> but it a smooth flow of elements.
> To realize this, the generator needs to be connected to the transformers
> and to the serializers *before* it actually begins to execute. So,
> <map:parameter name="test" value="{request-attr:toto}"/> is executed
> *before* <xsp-request:attribute name="toto">tata</xsp-request:attribute>.
> So, using request attributes is not a solution to your problem.
> Unfortunately I have no idea how the migration from 1.x to 2.0 was
> handled back in 2000/2001, have you tried searching mailing list
> archives for other people having your problem back in that period?
> Simone
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message