var handler = StripeCheckout.configure({

key: 'pk_test_NIFiGhJBpoH8kDhbdLTx7TPv',
image: 'https://stripe.com/img/documentation/checkout/marketplace.png',
locale: 'fr',
currency: 'EUR',
token: function(token) {
  // You can access the token ID with `token.id`.
  // Get the token ID to your server-side code for use.
}

});

document.getElementById('stripe').addEventListener('click', function(e) {

// Open Checkout with further options:
handler.open({
  name: 'Parsiweb',
  description: 'Un site web, hébergement offert',
  billingAddress: true,
  zipCode: false,
  amount: 48000
});
e.preventDefault();

});

// Close Checkout on page navigation: window.addEventListener('popstate', function() {

handler.close();

});