cancel
Showing results for 
Search instead for 
Did you mean: 

URL Request Parameter

Former Member
0 Kudos

Hi all,

I have a portal component with a link to a web dynpro iView. This WD iView should read some parameters, of the request, that have been set by the portal component.

In the WD I retrieve the original HTTP Request using:

WDWebContextAdapter.getWebContextAdapter()).getHttpServletRequest();

and then I read the parameter using:

param = request.getParameter("param").

Unfortunately I get a null value for param.

Any idea?

Cheers,

Marco

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Try

WDWebContextAdapter.getWebContextAdapter().getRequestParameter(key)

Armin

Former Member
0 Kudos

Hi,

your suggestion doesn't work. I get null again.

Just to clarify:

I have a portal component where with a link whose target is:

http://localhost:50000/irj/servlet/prt/portal/prtroot/<WD>?param=value

When I click on the link I correctly get a popup for my WebDynpro application. But I am not able to read the parameter as the original request seems not to contain the parameters map.

What could I do?

Thanks a lot,

Marco

Former Member
0 Kudos

Hi Marco,

To make sure the WD app works with the request parameters...Call it directly ..without calling through the portal...like http://<wasserver>:<wasport>/webdynpro/dispatcher/.../WDApp?param=value.

The url when called thru the portal is recreated by the portal framewok.

Thanks & Regards,

Renjith

Adding, if you are having iview in the portal pointing to the WDApp & the params can be given in the webdnpro iview definition...

Message was edited by: Renjith Andrews

Former Member
0 Kudos

Hi,

I can't access it directly as it has to be integrated into the portal.

So if I create a webdynpro iview the url is recreated by the portal framework and the parameters I added are removed.

Unfortunately I can't pass the parameter in the "Application Parameter" section of the iView because their value is determined at runtime.

Any suggestion?

Thank you,

Marco

Former Member
0 Kudos

Hi

I guess you have your WebDynpro Runtime and PRT on 2 different J2EE instances. Meaning you portal running on MachineA and WebDynpro running on Machine B.

You have created a system in the portal pointing to Machine B. Then you create a WebDynpro iView and map it to the system you created.

Hope the above is what you have done.

If that is the case then you will not be able to see the parameters as the time you call a WebDynpro App, it is a new http request to that machine A where the WD App resides and you will have a null value.

The only way to pass is through Application parameters and that also will not pass the value :(.

You can check and see if you can use Portal Service though.

Anyway instead of making guesses :).. Tell me how are your URL parameters determined at runtime. Maybe we could think of a way...

Hope that helps.

regards

Ravi

Former Member
0 Kudos

Hi,

thanks for your suggestions but they apply to a different scenario.

In my current scenario WebDynpro Runtime and PRT are on the same J2E instance.

I have one JSPDynPage iView which, through a custom logic, determins some parameters. Then it creates a link whose target is my WebDynpro iView.

The href of the link is something like the following:

http://localhost:50000/irj/servlet/prt/portal?prtroot=pcd;//portal_content/mypath/myWebDynproiView?<...;

In the previous URL, the <value> is determined at runtime and so cannot be specified in the application parameter field of the WebDynpro iView's profile.

One alternative is the use of cookies but I was wondering if there are other more reliable strategies.

Any suggestion?

Thanks,

marco

Former Member
0 Kudos

Hi

Well in that case shouldnt the URL be something like

http://localhost:50000/irj/servlet/prt/portal?navigationTarget=Roles://portal_content/mypath/myWebDy...;

Well if that is the case you should be getting the value when you say WDWebContextAdapter.getWebContextAdapter().getParameter("param");

URL rewriting should do. Just check and see if the above works.

I dont have a system with me right now else i would have sent you a sample :). Passing values from one iView to a WebDynpro iView has worked for me. I dont see it as a problem.

Hope that helped.

regards

Ravi

Former Member
0 Kudos

Hi,

I'm sorry but neither the "navigationTarget" works fine. I'm redirected to the WebDynpro iView but the paramters are lost. When there's a WebDynpro iView the Protal Framework translates the URL into the format:

http://localhost:50000/webdynpro/dispatcher/local/MyApplication

thus losing the URL parameters.

Any other clue?

Thank you,

Marco

Former Member
0 Kudos

Hi

Try using Portal Eventing (assuming you have both iViews in the same page for it to work). See if you are able to retain the parameters. But i still dont understand where you are losing the parameter value as URL rewriting should work.

Anyway check that let me know.

regards

Ravi

Former Member
0 Kudos

HI,

the problem is that the url when called thru the portal is recreated by the portal framewok that discards the custom parameters.

Then I can't use Portal Eventing as the iView aren't on the same page.

Marco

Former Member
0 Kudos

Hi Ravi,

currently i m in the same scenario that my WebDynpro Runtime and PRT on 2 diffrenet J2EE instances. I want to pass one parameter from portal iview and should retrive that parameter value in web dynpro application. I have 3 views in my web dynpro application i e SEARCH,SEARCH_A,SEARCH_B. i created 3 web dynpro iviews based on same webdynpro application. i am passing application parameter value from iview and retrieving that parameter value in web dynpro application. so based on value i am displaying web dynpro view. This is working perfect in Development portal because i have one instantce for PRT and WebDynpro Runtime. My Production portal contain 2 instances. Could you please suggest some idea how to solve this problem.

Former Member
0 Kudos

I have the same problem.

The parameter is lost when i use NavigationTarget=navurl://07aad3965963a5edf9ed047200d21902&paramter=value.

I have only one j2eee.

Florin

Former Member
0 Kudos

Hi Marco

How did you fix this problem???

every day i get another surprise from wd

Former Member
0 Kudos

done

properties:parameters forwarded by wd

Answers (0)