Hi Amit you can retreive your request parameters in the action section of your SCreen Widget like this : parameters.add_product_id. you can set it on another variable to reuse in your ftl if you like
Tibor On 12/4/06, David E Jones <[EMAIL PROTECTED]> wrote:
If I understand right you are trying to add a parameter to an outgoing link, or the HTML in the file being sent to the client. This has absolutely nothing to do with incoming parameters or attributes, which is what the parameters Map represents. It would certainly be possible to implement something like this, but would you really want to add a parameter to ALL links on a page? -David On Dec 3, 2006, at 9:46 PM, Amit Shinde wrote: > David, > Adding the parameter onto the link is definitely the best > solution. But I was wondering for my knowledge, if we could add that > parameter from the screen actions. That way I wouldnt have to go > search > every ftl where this link is called. > > So is it possible to add more parameters to the requestparameters > Map. > > Imagine that this is the link that is present in a ton of ftl pages - > > http://localhost/xyz/control/additem/~category_id=0200/ > ~add_product_id=DEMO > _PRODUCT_04/~quantity=1/ > > I could definitely go in every ftl file and add a parameter and > link would > be - > > http://localhost/xyz/control/additem/~category_id=0200/ > ~add_product_id=DEMO > _PRODUCT_04/~quantity=1/~product_id=DEMO_PRODUCT_04 > > You will notice that the new parameter 'product_id' has the same > value as > 'add_product_id'. The question is, is this the best way or can I do > something from Screen actions to add the parameter which would save > me tons > of time. All I want to do is add 'product_id' to the input > parameters Map > from the actions part. > > > Thanks a lot for your response, > > Amit Shinde > > > > > -----Original Message----- > From: David E Jones [mailto:[EMAIL PROTECTED] > Sent: Saturday, December 02, 2006 7:32 AM > To: [email protected] > Subject: Re: Add Parameter to request from Screen actions > > > > I'm not sure what you're getting at here, but my guess is you are > trying to output parameters into the input parameters Map. To get a > parameter onto a link or other URL, it needs to be added wherever > that URL is defined, like in the form def or ftl file, or whatever. > > -David > > > On Dec 1, 2006, at 5:04 PM, Amit Shinde wrote: > >> Hello Everyone, >> Heres what I am trying to do. I pass a parameter from a >> URL which >> calls a Screen. Now I want to add one more parameter with a >> different name >> to the request in the actions section of the screen. >> >> Heres the address - >> >> http://localhost/xyz/control/additem/~category_id=0200/ >> ~add_product_id=DEMO >> _PRODUCT_04/~quantity=1/ >> >> I want to add product_id in the request but I cant add it in the >> above URL >> else it would have looked like >> http://localhost/xyz/control/additem/~category_id=0200/ >> ~add_product_id=DEMO_ >> PRODUCT_04/~quantity=1/~product_id=DEMO_PRODUCT_04 >> >> I tried this but it didnt work - >> <section> >> <actions> >> <set field="parameters.product_id" >> from-field="parameters.add_product_id"/> >> .... >> </actions> >> <section> >> >> Is it possible to add product_id programmatically in the >> parameters map? >> >> Any inputs would be appreciated. >> >> Thanks in advance, >> >> Amit Shinde >> >> > >
