Introduction
Agreement
Authentication
Batch
Browser Payment
Gateway
Hosted Checkout
Payment Plan
Session
Tokenization
Transaction
Wallet
RESOURCES
Changelog
Session
setPlaceholderStyle()
setPlaceholderStyle()
Sets the styling for the placeholder text of the hosted field located inside the iFrame.
This function supports the Multiple Hosted Session functionality.
Usage Copied to clipboard
PaymentSession.setPlaceholderStyle([HostedFieldsRole], styles, scope)
Example Copied to clipboard
PaymentSession.setPlaceholderStyle(["card.number", "card.nameOnCard"], { color: 'green', fontWeight: 'bold', textDecoration: 'underline' });
Arguments Copied to clipboard
HostedFieldRole
Copied to clipboard
String
REQUIRED
The field role for the card field rendered in an iFrame and hosted on the American Express PSP. Valid
field
roles:
card.nameOnCard
card.number
card.expiryMonth
card.expiryYear
card.securityCode
giftCard.number
giftCard.pin
ach.bankAccountNumber
ach.bankAccountNumberConfirmation
ach.bankAccountHolder
ach.routingNumber
directDebitCanada.bankAccountHolder
directDebitCanada.bankAccountNumber
directDebitCanada.financialInstitutionNumber
directDebitCanada.bankAccountNumberConfirmation
directDebitCanada.transitNumber
styles
Copied to clipboard
Object
An object containing JavaScript CSS properties.
scope
Copied to clipboard
String
The optional named instance of a card payment data set within a session. See Multiple Hosted Sessions for more information.
Return Value Copied to clipboard
None