You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by xweber <xw...@googlemail.com> on 2007/08/01 13:12:42 UTC
Re: [cocoon 2.2.x] how to get request params in called block?
Grzegorz Kossakowski-3 wrote:
>
> xweber pisze:
>> so, how to get request params in called block?
>
> If parameters are simple strings you can pass them using such construct:
> servlet:someblock:/somepipeline?request1={request-param:request1}
>
> Of course, such solution has it's own limitations but may be sufficient in
> many situations.
>
> As you want to use some pipeline for processing XML stream I think that
> the best way would be to use servletService transformer.
> You need your XML data in the pipeline, so you should use:
> <map:generate type="stream">
> <map:parameter name="form-name" value="name_of_request_parameter"/>
> <!-- the name 'form-name' is rather misleading -->
> </map:generate>
>
> And then you should use servletService transformer:
> <map:transform type="servletService">
> <map:parameter name="service"
> value="servlet:myBlock2:/dosomeprocessing"/>
> </map:transform>
>
so if i got you right, there is no way to handle form processing in a called
block, because all information of the request is lost?
That would be a real show-stopper.
Url Parameters (the ?var=xx stuff) is not a big problem, since it could be
set e.g. to the requested page name and so the URI can be put to the called
block. I have that working here.
But this way cannot be used for POST variable. Its hard to believe that this
is impossible with current code.
Alex
--
View this message in context: http://www.nabble.com/-cocoon-2.2.x--how-to-get-request-params-in-called-block--tf4194334.html#a11943630
Sent from the Cocoon - Users mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org