hello this my code is not working internet explorer plz give me solution
Code:
/** * When we click on a card */ $('#btnpay').click(function(){ const paymentRequest = { cardNumber: $('#cartno').val(), expYear: $('#expYear').val(), expMonth: $('#expMonth').val(), cvc: $('#cvcno').val(), currency: 'GBP', amount: $('#amount').val(), nativeElement: document.querySelector('#iframe-payment') }; paymentRequest.nativeElement.innerHTML = 'Loading... Please wait... while you are redirecting payment getway '; $('.frm').hide() doPayment(paymentRequest).then((result) => { $('#formpay').append('<input type="hidden" name="stripeSource" value="'+result.id+'" />'); $('#formpay').submit() }).catch((error) => { paymentRequest.nativeElement.innerHTML = 'Ups! We can\t validate your details...'; setTimeout(function() { location.reload(); }, 3000); }); }) function isNumberKey(evt){ var charCode = (evt.which) ? evt.which : event.keyCode if (charCode > 31 && (charCode < 48 || charCode > 57)) return false; } $('#cartno').keyup(function() { var length = $(this).val().length; if(length==16){ $('#expMonth').focus() } }); $('#expMonth').keyup(function() { var length = $(this).val().length; var firstChar = $(this).val().substr(0, 1); if(firstChar>1){ $(this).val(0)} if(length==2){ $('#expYear').focus() } }); $('#expYear').keyup(function() { var length = $(this).val().length; if(length==2){ $('#cvcno').focus() } }); $('#cvcno').keyup(function() { var length = $(this).val().length; if(length==3){ $('#btnpay').focus() } });
Comment