Skip to Content
Author's profile photo Nick Rankin

How to call a Portal iview directly using NavigationTarget

This blog post will be useful if you would like to link to a specific Portal iview directly, e.g: from a pdf, document, another site etc. Using the NavigationTarget property we can call any iview, role object directly, plus also pass any additional properties via GET method as required (e.g: Application Parameters, NavMode, sap-ie etc.).

This method is also useful for testing iviews under the different document rendering modes: Quirks and Standards, which I will explain below.

The NavigationTarget property supports the following values:
– Full PCD location to a role, iview etc.
– Short URL value

Getting Started

Logging on to your Portal as an administrator user, call the below URL:
http://<host>:<port>/irj/portal?NavigationTarget=pcd:portal_content/administrator/super_admin/super_admin_role/com.sap.portal.user_administration/com.sap.portal.user_admin_wd_ws/com.sap.portal.umeAdminWD&NavMode=3&sap-ie=EmulateIE8
What happens here? We are calling the UserAdmin WebDynpro Java application, we are passing Navigation Mode = 3 so it will display in a seperate headerless portal window and sap-ie=EmulateIE8 to force the application to render under Quirks.

You should see the window open as below:

Looking at the URL in detail, we are passing 3 parameters:
./irj/portal?NavigationTarget=pcd:portal_content/administrator/super_admin/super_admin_role/com.sap.portal.user_administration/com.sap.portal.user_admin_wd_ws/com.sap.portal.umeAdminWD&NavMode=3&sap-ie=EmulateIE8

NavigationTarget: This should include either a PCD Object location, or Short URL value exactly as below (important points in bold):

  • pcd:portal_content/administrator/super_admin/super_admin_role/com.sap.portal.user_administration/com.sap.portal.user_admin_wd_ws/com.sap.portal.umeAdminWD
  • navurl://58a98d4017b7764a04ad86825ecfe16b

For a PCD object location, we must include pcd: prefix before we include the PCD location. For a Short URL we must include navurl:// before the Short URL value.

NavMode: The Navigation Mode is the mode we wish to open the application under. Choosing NavMode=0 for example, the application will be called under the Portal Content Area, so the entire Portal will be loaded. Calling NavMode=1 will open the iview in a frameless window (No iframe).

The list of available navigation modes may be found below:

  • NavMode=0 –> Display in Portal Content Area
  • NavMode=1 –> Display in Separate Window
  • NavMode=2 –> Display in Separate Portal Window
  • NavMode=3 –> Display in Separate Headerless Portal Window (Quirks Mode)
  • NavMode=4 –> Display in separate headerless portal window (embedded)
  • NavMode=10 –> Display in separate headerless portal window (standard mode) (Standards/EDGE Mode)
  • NavMode=11 –> Display in separate headerless portal window (viewport)*

sap-ie: May contain a value of either EmulateIE8 or EDGE. Emulate IE8 will tell the application to run under Quirks, while EDGE will tell it to run under Standards document mode.

Locating the PCD object location

As above, for an example I have picked an iview that you will all have deployed on your Portal. but you will probably have your own iviews/other content you will want to call using this method.
I have created a new iview called UI5, which is based on the SAPUI5 iview object template. This I want to call directly, under Standards document mode, plus using a new headerless Window.

Open the iview via your Content Administration -> Portal Content Management you wish to link to.
Open the Properties section for this iview and choose All properties.
Under the iview properties filter, use Filter as: Location, the iview PCD location will be displayed as below. Copy the value for location:

In this case, the iview is located under potal_content folder, and it is called UI5. To call this iview directly, we would construct the following URL:
http://<host>:<port>/irj/portal?NavigationTarget=pcd:portal_content/UI5&NavMode=10&sap-ie=EDGE

The iview will now get called (for this example, I don’t point the iview to a UI5 application, so the Application Testing screen is displayed):

Notice in the URL I pass NavMode=10, sap-ie=EDGE for Standards mode?

Using Short URLs

In my above example, I have a very short PCD Location consisting of just: pcd:portal_content/UI5. But for many cases, you will be using folders, longer names for the objects and the PCD location does get quite large.
We can see this for our first PCD Location:
pcd:portal_content/administrator/super_admin/super_admin_role/com.sap.portal.user_administration/com.sap.portal.user_admin_wd_ws/com.sap.portal.umeAdminWD

You may even have longer PCD locations than above! It is not ideal to include such a large URL in a request. Instead we can use the Short URLs feature of the Portal.

To locate a Short URL value from a PCD Location?

Logon to your Portal as an Admin User and Navigate to System Administration -> System Configuration -> Runtime Settings -> Short URLs

Note: Short URLs must be enabled under this location before you can use Short URLs in Navigation!

Under the Short URL Search box, paste the entire PCD location excluding the PCD: prefix using an asterisk at both start and end of the string.
For the above example (UserAdmin iview), you would search exactly as below:
*portal_content/administrator/super_admin/super_admin_role/com.sap.portal.user_administration/com.sap.portal.user_admin_wd_ws/com.sap.portal.umeAdminWD*

Your iview/role etc. object should be listed now under the results. Press the button next to the result(s) to confirm the location is correct.

You will now see the correct Short URL value for your iview/object as below:

In my case the Short URL to the UserAdmin/umeAdminWD application is (this will be different in your system):
58a98d4017b7764a04ad86825ecfe16b

To Call the UserAdmin application using the Short URL value, I will use the following URL:
http://<host>:<port>/irj/portal?NavigationTarget=navurl://58a98d4017b7764a04ad86825ecfe16b&NavMode=3&sap-ie=EmulateIE8

The UserAdmin application is now opened via Short URL:

Assigned Tags

      7 Comments
      You must be Logged on to comment or reply to a post.
      Author's profile photo Former Member
      Former Member

      Thank you Nick for the explanation! Do you have more information about the parameters ExecuteLocally, PrevNavTarget?

      We are facing a problem. We use Kerberos ticket based authentication via portal. When we successfully logged into the system it leaves a blank explorer there and does not close that. The problem is the same like in the note 973951, but the environment is much newer (7.4).

      Thank you,

      Jani

       

      Author's profile photo Nick Rankin
      Nick Rankin
      Blog Post Author

      Hi Jani,

       

      Could you provide a screenshot of the issue? Does it happen under all browsers? What kind of application are you calling (UI5, WebDynpro, ITS etc.)

       

      Best regards,

      Nick

      Author's profile photo Daniel Weicht
      Daniel Weicht

      Hi Nick,

      Great bog.

      We are facing a problem with the NavMode=0 parameter in IE11. The site remains empty and will only display the objects if we delete the cache. In Chrome it is working fine. If we use the NavMode=1 parameter is working fine, but we do not want the page to open in a separate window.

      We are using 7.52 Version and Vantaio as an Add-on.

      BR

      Daniel

      Author's profile photo Nick Rankin
      Nick Rankin
      Blog Post Author

      Hi Daniel,

       

      Can you access the portal directly in these instances by calling irj/portal directly? I have not come across an issue like this before. If you use a reverse proxy or Webdispatcher, does the error occur bypassing those?

       

      Best regards

      Nick

      Author's profile photo RAVI PRAKASH SRIVASTAVA
      RAVI PRAKASH SRIVASTAVA

      Very userful one Nick..

      Thanks

      Author's profile photo Siong Chao Ng
      Siong Chao Ng

      I have a case where it always show a box "The IE compatibility view is not supported (Note 1970689)/ Tried will all Navigation mode and sap-ie=Edge or EmulateIE8 but no avail. The users here insist on using Edge browser with IE11 compatibility

      Author's profile photo Nick Rankin
      Nick Rankin
      Blog Post Author

      Hi Siong,

      It depends on how the navigation is being executed. For example if the Portal navigation is occurring within a WebDynpro application (e.g clicking a application button or PO Worklist Item) the WebDynpro has built in APIs for generating portal navigation URLs, and it is the WebDynpro itself the NavigationMode is provided by.

      This particular error occurs when wrong X-UA-Compatible header is sent, or sap-ie=EmulateIE8 is sent to the application. Is can also occur if you use the IE Enterprise Mode feature (please ensure that is not used for the EDGE IEMode feature).

      Please do ensure you are testing using the SAP Standard AJAX Standards Framework Page. Sometimes customized framework pages are missing the required components for the document mode/navmode switches to work properly. The Classic Framework Page is now a deprecated functionality and should be avoided.

      Please also see the following KBAs for more details on this problem:

      • 2016845 - Using Portal with Internet Explorer in Quirks or Standards as browser document mode
      • 2400253 - Determining where to set and configure the Navigation Mode under Portal environment

      Best regards,

      Nick