IBAN element
Learn how to use the IBAN element.
An IBAN, or International Bank Account Number, includes various numeric identifiers, such as account number and country code, which help financial institutions process international payments more quickly and without errors.
With DigitalRiver.js, you can create an IBAN element that will create a field to collect a shopper's IBAN number. The IBAN element can be styled and placed on your page like other DigitalRiver.js elements.
Creating an IBAN element
To create an IBAN element, use the createElement
function exposed through the DigitalRiver Object. This object follows the same pattern and allows for the same custom classes and styles as other elements.
IBAN element functions
iban.mount();
Call this function to place the created IBAN element on your page.
iban.unmount();
Call this function to remove the IBAN element from your page. The element may be re-added to your page by calling mount()
.
iban.destroy();
Call this function to remove the IBAN element from your page, as well as remove its functionality. You cannot re-add the destroyed element to your page via mount()
.
IBAN element events - iban.on('event', handler);
The IBAN Element can receive the following events by creating an event listener. Use this function to listen to events that can be used to build and enhance your purchase flow.
The created element is loaded and ready. | |
A shopper clicked the element's input field. | |
The element has lost focus. | |
The element's state has changed. |
Ready
The Ready event triggers when the IBAN element has loaded.
Focus
The Focus event triggers when the IBAN element has focus.
Blur
The Blur event triggers when the IBAN element no longer has focus.
Change
The Change event triggers when the IBAN element's state has changed. DigitalRiver.js will return a Change Event Error object with the event payload if it detects an error.
Key | Value Description |
---|---|
| Indicates whether the element is in a complete state. |
| Indicates whether the element is empty. |
| Identifies the element type. |
| An error object (if applicable). |
In this flow, you can now use the createSource
method to create a source using the IBAN element.
Last updated