# makecommerce/3.0.11/payment/gateway/woocommerce/js/mc_cc_complete.js

MakeCommerce for WooCommerce, version 3.0.11. 17 lines.

- Page: https://pluginprobe.com/plugins/makecommerce/3.0.11/code/payment/gateway/woocommerce/js/mc_cc_complete.js
- Raw: https://pluginprobe.com/plugins/makecommerce/3.0.11/raw/payment/gateway/woocommerce/js/mc_cc_complete.js
- Modified: 2021-11-01T12:10:04+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/makecommerce/3.0.11/code/payment/gateway/woocommerce/js/mc_cc_complete.js#L10-L20`.

```javascript
function makecommerce_cc_complete(data)
{
    if (data.paymentToken) {
        
        jQuery('div.mc-processing-message').show();

        var submitform = jQuery('<form action="' + MC_CC_COMPLETE.payment_return_url + '" method="POST" style="display: none;"><input type="submit"/><input type="hidden" name="transaction" value="' + MC_CC_COMPLETE.transaction_id + '" /></form>');
        
        for (var key in data) {
            submitform.append(jQuery('<input type="hidden" name="' + key + '" />').val(data[key])); 
        }

        jQuery('body').append(submitform);

        submitform.submit();
    }
}
```
