Displaying the Bank Widget

Use the selectBankWidget function to display a Trustly Widget inline on your page which allows the User to select their bank. The SDK controls opening the Trustly Lightbox where the User will complete their Bank Authorization.

648

When the User exits the Trustly Lightbox, the SDK will direct the User to your returnUrl or cancelUrl. See Handling the Redirect for more information.

Select Bank Widget

Use this HTML to display the Bank Widget on your screen:

<body>
  <div id="widget-id"></div>
  <script>
    Trustly.selectBankWidget(establishData, TrustlyOptions);
  </script>
</body>

Parameters

ParameterDescription
establishDataSee Establish Data
TrustlyOptionsSee Getting Started