问题
I have integrated Card.io successfully and it is working perfectly. But we now want to add the logo of the payment gateway we use in the screen where the card details are entered manually.
As there is no way to customize the SDKs "Enter Manually" screen, we thought of implementing a custom screen to capture the card details.
Is there a way to use the features present in the SDK's screen, in a custom screen? Features such as credit card type detection, number validation, month and year formatting etc…
回答1:
Josh from card.io here. It is a reasonable request, but to keep the API small, we tend not to expose lots of fine-grained functionality. If there is a specific thing you need that is hard/complicated/tedious to build right and stands alone nicely, feel free to file an issue asking for it.
Note that one such feature, credit card type detection, is already exposed. Take a look at CardIOCreditCardInfo.h. You can create a CardIOCreditCardInfo
class, set its cardNumber
, and then read its cardType
.
Generally, take a look around through the header files. They are well documented, and there is more there than is covered in just the integration docs.
来源:https://stackoverflow.com/questions/24255345/can-i-use-card-io-credit-card-number-text-field-in-ios-in-a-custom-enter-manuall