You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to tokenize credit card data without using an iframe submit button. In the Heartland example I see cardExternalTrigger as the solution to this; however no requests are made and the token-success event does not fire.
document.getElementById('place-order-btn').addEventListener('click',function(event){event.preventDefault();for(vartypeincardForm.fields){if(type==="submit"){continue;}varfield=cardForm.frames[type];if(!field){continue;}GlobalPayments.internal.postMessage.post({data: {fields: cardForm.fields,target: field.id},id: field.id,type: "ui:iframe-field:request-data",},field.id);}cardForm.on("token-success",(resp)=>{// Save payment tokenthis.paymentToken=resp.paymentReference;console.log('token recieved')// Submit data to the integration's backend for processing// that.submitForm();});cardForm.on("token-error",(resp)=>{});});
The text was updated successfully, but these errors were encountered:
I am trying to tokenize credit card data without using an iframe submit button. In the Heartland example I see cardExternalTrigger as the solution to this; however no requests are made and the
token-success
event does not fire.The text was updated successfully, but these errors were encountered: