当我在Chrome中为卡使用自动填充并选择Visa Debit时,它会显示卡类型为Visa而不是Visa Debit。在我们切换到Angular之前,HTML显示了Visa Credit / Visa Debit
我尝试将输入类型更改为'text‘,因为这是在旧网站中使用的,但这并没有解决这个问题(我不确定为什么它被设置为输入类型'tel’,但我猜这是有原因的)。
我目前有:
<input type="tel" class="form-control w-100" formControlName='cardNumber' maxlength="23">
我希望卡类型在输入/选择卡时自动填写Visa Debit或Visa Credit。
发布于 2019-07-03 10:34:26
我最终解决了这个问题,更改了密钥的名称,以确保所有与Visa相关的卡都引用了“Visa”。我猜Chrome需要这个才能让自动补全起作用。
发布于 2019-06-26 11:33:15
根据Google Docs,您可能需要将autocomplete="cc-number"
添加到字段中,以便它能自动正确地为您填写信用卡号。
信用卡号码的整个输入如下所示:
<input name="cardnumber" id="frmCCNum" required autocomplete="cc-number">
https://stackoverflow.com/questions/56770540
复制相似问题