cancel
Showing results for 
Search instead for 
Did you mean: 

Redirecting to external URL in web dynpro application accessed in portal

asif_hirani
Active Participant
0 Kudos

Hi All,

I want to redirect to external url (eg http://www.google.com) on click of button in web dynpro application, but I am accessing the application through portal.

I tried SAP's recommended approach

1) EXIT PLUG : http://help.sap.com/saphelp_nw70ehp1/helpdata/en/83/e7c24122e3c317e10000000a155106/frameset.htm

it works when i test web dynpro application separately but when I run it through Portal it gave me Error: saying use portal navigation when running inside portal and do not fire exit plug to navigate to external URL

2) so i tried

WDPortalNavigation.navigateAbsolute( "http://www.google.com", WDPortalNavigationMode.SHOW_INPLACE,(String) null,(String) null,WDPortalNavigationHistoryMode.NO_DUPLICATIONS,(String) null,(String) null,(String) null);

this wont work as google.com web page is not part of portal content's (Role/iview)

3) I also tried

WDClientUser.forceLogoffClientUser("http://www.google.com");

again this work's when web dynpro application is tested standalone but when I run it through portal it doesn't work

please let me know if I need to follow some other approach to do this .

Thanks !

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

hi,

You can code this a dialog box (popup)

http://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/user-interface-tech...

or create a url iview out of the url you want and then call the Iview from your wd app.

http://wiki.sdn.sap.com/wiki/display/WDJava/NavigatebetweenWebDynproApplicationshostedonseperatePortalPages

Srini

asif_hirani
Active Participant
0 Kudos

Thanks for replying Srini..

But I want redirect to happen in the same window.

In my scenario user click's button in web dynpro application accessed through Portal iview and should be redirected to external website in the same window.

Actually user clicks a cancel my account button on button click we terminate user's account in backend and we want user to be redirected to some other corporate website after that (log off from portal is not necessary as we have mechanism to not allow user to access portal using cookies/session once redirected to some external URL like http://sdn.sap.com)

all we want is redirect in same window in portal.

let me know if you have any other suggestion !!

Thanks

Former Member
0 Kudos

Hi,

Did you try the Logoffurl in the wd application parameter

http://help.sap.com/saphelp_nw04s/helpdata/en/09/a4d6a674bc1d4a9e74abf81bed3ef6/content.htm

Srini

asif_hirani
Active Participant
0 Kudos

yes I tried that it's given in this Tutorial :

http://help.sap.com/saphelp_nw70ehp1/helpdata/en/83/e7c24122e3c317e10000000a155106/frameset.htm

It works when we test only web dynpro application but it didn't worked when accessing through Portal iview. Error say's use Portal Navigation instead of EXIT plug so it's again back to square one....

Former Member
0 Kudos

Hi,

Hope this helps. In the same webdynpro application create a viewset and two views, secone view with only iframe ui and pass the url at the runtime while doing some action.

Thanks,

Vivek.

Former Member
0 Kudos

Hi,

There is a UI element called LinkToURL, can you check that.

Srini

asif_hirani
Active Participant
0 Kudos

Thanks srini for your reply !

The LinkToUrl is used to exclusively to open URLs in a separate window we want navigation to happen in the same window so that user no longer able to access portal.

SAP say's to leave the Web Dynpro application and display a new URL use an exit plug.

but Exit plugs do not work in a portal environment. This limitation is also described by note 913972.

they ask to use PortalNavigation...to create URL iview abnd use it to call in using portalnavigation..this open's a redirected page in a iview window portal session still remains active and we keep seeing portal TABS ...

But this look to be very common scenario I wonder why there isn't something already in place to do it...

Thanks...

siarhei_pisarenka3
Active Contributor
0 Kudos

Hi Asif

Have you tried WebDynpro IFrame control?

Regards, Siarhei

asif_hirani
Active Participant
0 Kudos

Hi Siarhei,

Iframe displays the web page / contents in a UI element (BOX) inside web dynpro application..

I need to redirect user entirely from Portal..to other web site so that user cannot perform any activity on portal anymore..

thanks

asif_hirani
Active Participant
0 Kudos

problem was resolved

Below solution Worked -

1) set ume.logoff.url value to <url to be redirceted to>

2) create html file in KM to execute script

EPCM.getSAPTop().document.forms["logoffForm"].submit();

or

(something like: EPCM.getSAPTop().document.location.href=<new url>).

3) create KM Navigation iview using above html file

4) use WdPortal Navigation inside web dynpro code to navigate to the KM

iview.

Answers (1)

Answers (1)

Former Member
0 Kudos

hi,

why dont you bind the reference property of link to url ui element with the link that you are interested to bind.