[Support request] braintree payment

Home Forums Support [Support request] braintree payment

Home Forums Support braintree payment

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • #1050454

    Hello, I would like to integrate braintree-payments into my webshop. I need to integrate this code:

    <meta charset=”utf-8″>
    <script src=”https://js.braintreegateway.com/web/dropin/1.20.4/js/dropin.min.js”></script&gt;

    <button id=”submit-button”>Request payment method</button>
    var button = document.querySelector(‘#submit-button’);

    authorization: ‘CLIENT_TOKEN_FROM_SERVER’,
    container: ‘#dropin-container’
    }, function (createErr, instance) {
    button.addEventListener(‘click’, function () {
    instance.requestPaymentMethod(function (err, payload) {
    // Submit payload.nonce to your server

    I guess I could do this with a head-element and a body-element, right?

    And then I need to integrate this code into my template:

    authorization: CLIENT_TOKEN_FROM_SERVER,
    container: ‘#dropin-container’
    }, function (err, instance) {
    /* … */

    Do you have any idea where to put this code? Thanks Klaus

    Customer Support

    Hi there,
    Apart from the button you can use Hook Element:


    Hook# 1 for the <head></head> tag could – select the WP_header hook.
    Hook# 2 for the two scripts would go in the WP_footer hook.

    The button you would just add that code to your page content where you want the button to be displayed.

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.