All text displayed as part of the Direct Checkout components can be localised to display language translation or preferred English phrasing. This is optional and is controlled by the integrator, by passing attributes in the config object.
The attributes that may be configured:
Attribute |
Description |
---|---|
Labels |
Field labels including “Card number”, Expiry date”, etc. |
Validation messages / Field errors |
Validation messages for required, incomplete and invalid input. For example: “Card number is mandatory”, “Card number is incomplete”, “Card number is invalid”. |
Titles / Headings |
Titles for “Card details” and, if applicable, “Billing details”
|
Billing address checkbox description |
Text next to checkbox: “Billing address is different to shipping address” |
Other errors |
“Service is currently unavailable” and “Session is timed out due to inactivity, please try again” |
Data type is string for all attributes.
Description |
Attribute name |
Default value |
Maximum Characters |
---|---|---|---|
Label for PAN. |
localisations.pan.label |
Card number |
50 |
validation message when PAN is required. |
localisations.pan.validations.required |
Card number is mandatory |
100 |
Validation message when PAN is incomplete input. |
localisations.pan.validations.incomplete |
Card number is incomplete |
100 |
Validation message for the invalid input. |
localisations.pan.validations.invalid |
Card number is invalid |
100 |
Label for Expiry date. |
localisations.expirydate.label |
Expiry date |
50 |
Placeholder to show expiry date format. |
localisations.expirydate.placeholder |
MM/YY |
5* |
Validation Message when expiry date is required. |
localisations.expirydate.validations.required |
Expiry date is mandatory |
100 |
Validation message when expiry date is incomplete. |
localisations.expirydate.validations.incomplete |
Expiry date is incomplete |
100 |
Validation message when expiry date is invalid. |
localisations.expirydate.validations.invalid |
Expiry date is invalid |
100 |
Validation message when expiry date is expired. |
localisations.expirydate.validations.expired |
Expiry date can't be in the past |
100 |
Label for CVV. |
localisations.cvv.label |
Security code |
50 |
Validation Message when CVV is required. |
localisations.cvv.validations.required |
Security code is mandatory |
100 |
Validation message when CVV is incomplete. |
localisations.cvv.validations.incomplete |
Security code is incomplete |
100 |
Validation message when CVV is invalid. |
localisations.cvv.validations.invalid |
Security code is invalid |
50 |
label for cardholder name. |
localisations.cardholderName.label |
Cardholder name |
50 |
Validation Message when cardholder name is required. |
localisations.cardholderName.validations.required |
Cardholder name is mandatory |
100 |
Validation message when cardholder name exceeds max character length. |
localisations.cardholderName.validations .maxLength |
Maximum allowed length is 50 characters |
100 |
Label for address line 1. |
localisations.addressline1.label |
Address line 1 |
50 |
Validation message when address line 1 is required. |
localisations.addressline1.validations.required |
Address line 1 is mandatory |
100 |
Label for address line 2. |
localisations.addressline2.label |
Address line 2 |
50 |
Validation message when address line 2 is required. |
localisations.addressline2.validations.required |
Address line 2 is mandatory |
100 |
Label for address line 3. |
localisations.addressline3.label |
Address line 3 |
50 |
Label for address line 4. |
localisations.addressline4.label |
Address line 4 |
50 |
Label for city. |
localisations.city.label |
City |
50 |
Validation message when city is required. |
localisations.city.validations.required |
City is mandatory |
100 |
Label for county. |
localisations.county.label |
County |
50 |
Label for country. |
localisations.country.label |
Country |
50 |
Validation message when country is required. |
localisations.country.validations.required |
Country is mandatory |
100 |
Label for postal code. |
localisations.postcode.label |
Postcode |
50 |
Validation message when post code is required. |
localisations.postcode.validations.required |
Postcode is mandatory |
100 |
Label for Email. |
localisations.email.label |
Email address |
50 |
Validation message when email format is incorrect. |
localisations.email.validations.format |
Please enter a valid email address |
NA |
Validation message when email is required. |
localisations.email.validations.required |
Email is mandatory |
NA |
Validation message when mandatory details are missing. |
localisations.mandatoryFieldMissing |
Please provide all mandatory fields |
NA |
Title for the card details section. |
localisations.cardDetailsTitle |
Card details |
NA |
Title for the billing address section. |
localisations.billingAddressTitle |
Billing address |
NA |
Description for the checkbox to toggle billing address. |
localisations.billingAddressCheckboxDescription |
Billing address is different to shipping address |
NA |
Payment submit button text. |
localisations.paymentSubmit |
Pay |
20 |
Message shown when the Access PaySuite service is unavailable. |
localisations.serviceUnavailable |
Service is currently unavailable |
NA |
Message shown when payment session is timed out. |
localisations.timedOut |
Session is timed out due to inactivity, please try again |
NA |
* localisations.expirydate.placeholder must be five characters including central forward slash.
config = { "localisations": { "pan": { "label": "Card number", "validations": { required: "Card number is mandatory", incomplete: "Card number is incomplete", invalid: "Card number is invalid" } }, "expirydate": { "label": "Expiry date", placeholder: "MM/YY" "validations": { "required": "Expiry date is mandatory", "incomplete": "Expiry date is incomplete", "invalid": "Expiry date is invalid", "expired": "Expiry date can't be in the past" } }, "cvv": { "label": "Security code", "validations": { "required": "Security code is mandatory", "incomplete": "Security code is incomplete", "invalid": "Security code is invalid" } }, "cardholderName": { "label": "Cardholder name", "validations": { "required": " Cardholder name is mandatory", "maxLength": "Maximum allowed length is 50 characters" } }, "addressline1": { "label": "Address line 1", "validations": { "required": " Address line 1 is mandatory" } }, "addressline2": { "label": " Address line 2", "validations": { "required": " Address line 2 is mandatory " } }, "addressline3": { "label": " Address line 3" }, "addressline4": { "label": " Address line 4" }, "city": { "label": "City", "validations": { "required": "City is mandatory" } }, "county": { "label": "County" }, "country": { "label": "Country", "validations": { "required": "Country is mandatory" } }, "postcode": { "label": "Postcode", "validations": { "required": "Postcode is mandatory" } }, "email": { "label": "Email address", "validations": { "format": "Please enter a valid email address", "required": "Email is mandatory" } }, "mandatoryFieldMissing": "Please provide all mandatory fields", "cardDetailsTitle": "Card details", "billingAddressTitle": "Billing address", "billingAddressCheckboxDescription": "Billing address is different to shipping address", "paymentSubmit": "Pay", "serviceUnavailable": "Service is currently unavailable", "timedOut": "Payment has timed out and cannot be completed" } }