Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Hiding the Password in web URL

Hi Guru's,

I need to make my password invisible using ****** in my URL web page. How is it possible to do?

Regards.

Former Member
replied

Hi Meenkshi,

Hope, you are launching WDA application on click on any action.

You can hide the URL parameters by using POST method while launching application.

Please refer the below code

  "------------------------------------------------
  "Data declarations
  "------------------------------------------------
  DATA: lo_window_manager      TYPE REF TO if_wd_window_manager,
        lo_api_component       TYPE REF TO if_wd_component,
        lo_window              TYPE REF TO if_wd_window,
        lt_parameters          TYPE tihttpnvp,
        ls_parameters          LIKE LINE OF lt_parameters,
        lv_url                 TYPE string.
  "----------------------------------------------------
  "get view contoller, window manager
  lo_api_component           = wd_this->wd_get_api( ).
  lo_window_manager          = lo_api_component->get_window_manager( ).

  " Return if window manager is not bound
  "----------------------------------------------------
  IF lo_window_manager IS NOT BOUND.
    RETURN.
  ENDIF.
  "----------------------------------------------------
  " Prepare parameter table
  "----------------------------------------------------
  CLEAR: lt_parameters,
         ls_parameters.
  ls_parameters-name = 'MY_PASSWORD'.
  ls_parameters-value = 'asdf1234'.
  APPEND ls_parameters TO lt_parameters.

  "----------------------------------------------------
  " Construct url for your application
  "----------------------------------------------------
  cl_wd_utilities=>construct_wd_url(
    EXPORTING
      application_name              = 'ZWD_TEST' " this is your WD application name
      in_parameters                 =  lt_parameters
    IMPORTING
      out_absolute_url              =   lv_url
  ).

  lo_window_manager->create_external_window(
    EXPORTING
      url            = lv_url
      use_post       = abap_true
    RECEIVING
      window         = lo_window
  ).
  IF lo_window IS BOUND.
    lo_window->open( ).
  ENDIF.

Hope this helps you.

Regards,

Rama

1 View this answer in context

Helpful Answer

by
Not what you were looking for? View more on this topic or Ask a question