cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robby Pelssers" <robby.pelss...@ciber.com>
Subject RE: how to access post parameters from sitemap
Date Wed, 27 Apr 2011 10:03:07 GMT
Hi Luca,

thx for the reply...  That was indeed the first option for me to consider.  Unfortunately
this solution will not work for me since I setup a highly generic pipeline which starts an
xquery generator.  So basically the correct xquery is generated and the idea is that all needed
parameters are set by the xquery generator from request parameters as well as post parameters
which are
different for each xquery.

        <map:generate src="xquery/{1}.xquery" type="queryStringXquery">
          <map:parameter name="contextPath" value="{request:contextPath}"/>
          <!-- does not work for post parameters
                <map:parameter name="queryString" value="{request:queryString}"/>
           -->
        </map:generate>

I'm actually debugging the custom Xquery Generator now and it seems somehow deeply nested
I can retrieve those parameters from 'Map objectModel' without the need to inject them from
within my sitemap.  Will keep you posted ;-)

     void setup(SourceResolver resolver, Map objectModel, String source, Parameters parameters)

Kind regards,
Robby


-----Oorspronkelijk bericht-----
Van: Luca Morandini [mailto:lmorandini@ieee.org]
Verzonden: wo 27-4-2011 11:29
Aan: users@cocoon.apache.org
Onderwerp: Re: how to access post parameters from sitemap
 
On 04/26/2011 04:10 PM, Robby Pelssers wrote:
>
> When I post to this url  firebug shows the id's are posted just fine. But when
> I debug the queryString is null when making post requests.

When POST method is used, query string is null, since parameters are passed in the 
body of the request.


> Is there some cocoon component which allows me to get access to BOTH request
> and post parameters?

To access said paramerers, a simple "request-param" should do, for instance:
             <map:call function="addPerson">
               <map:parameter name="bizdata" value="{request-param:bizdata}"/>
             </map:call>

Regards,

Luca Morandini
http://www.lucamorandini.it


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




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


Mime
View raw message