~evanj/cms

ref: 8efa6eb4fd1aad49d40bb3850530c531add998da cms/internal/s/tmpl/html/stripe.html -rw-r--r-- 883 bytes
8efa6eb4Evan M Jones WIP(stripe): *. 1 year, 2 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
<!DOCTYPE html>
<html lang=en>
<head>
  {{ template "html/_head.html" }}
  <title>CMS | Docs</title>
</head>
<body class='page bg-light'>
  <style>{{ template "css/main.css" }}</style>
  <main>
    {{ template "html/_header.html" $ }}
    <div class="pricing-header px-3 py-3 pt-md-5 pb-md-4 mx-auto text-center">
      <h1 class="display-4">Processing...</h1>
    </div>
    {{ template "html/_footer.html" $ }}
  </main>
  {{ template "html/_scripts.html" }}
  <script src="//js.stripe.com/v3/"></script>
  <script>
    (function() { 
      var stripe = Stripe('{{.StripePK}}');
      var checkoutButton = document.getElementById('checkout-button');
      stripe.redirectToCheckout({
        sessionId: '{{.StripeCheckoutSessionID}}'
      }).then(function (result) {
        console.log(result)
        alert(result.error.message);
      });
    })();
  </script>
</body>
</html>