cancel
Showing results for 
Search instead for 
Did you mean: 

How to use the portal language in the web dynpro application?

Former Member
0 Kudos

Hi,

our web dynpro application runs in a portal. The application gets the portal user via the parameter of the application url. At the moment we use by default in the application the sy-langu of the user on the web dynpro server. If the user wants do have another language he can choose it in the application. But this is not comfortable. It would be nice if the application can use the personalized language of the portal. How can we get the portal language? Is there an example?

Is there also a possibility that if the user changes the language in the web dynpro application that the portal language changes, too? So the language would be the same overall.

Thanks in advance. Regards

Susanne

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

is signle sign on an option ?

Former Member
0 Kudos

Thanks for aswering. But single sign on is not an option. Is there only the possibility to transfer the user language by a parameter in the url of the application? Or do I have another possibility to use the portal language in the web dynpro apllication?

Regards, Susanne

Former Member
0 Kudos

Hi susane,

i think it is better to keep your approach of sending Language parameter along the application parameter. If you want to know the portal language from the Webdynpro then you may use IF_WD_PORTAL_INTEGRATION->M_PORTAL_VERSION to know if you run in portal.

data l_api_component type ref to if_wd_component.

data l_portal_manager type ref to if_wd_portal_integration.

l_api_component = wd_this->wd_get_api( ).

l_portal_manager = l_api_component->get_portal_manager( ).

if l_portal_manager-m_portal_version is initial

" application not in portal

else.

" use some api classes to get the portal session request to get the user/Language.

endif.

Then you may have to use find a way/search in SDN to get the portal session user/Language.