Skip to content

Commit 7cad0d7

Browse files
committed
feat(support): support button
1 parent 1eb2eb5 commit 7cad0d7

2 files changed

Lines changed: 23 additions & 0 deletions

File tree

docs/support/50rs-button.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
<div id="paypal-button-container-P-5PT799148U8831139M22NQTQ"></div>
2+
<script src="https://www.paypal.com/sdk/js?client-id=ARJpggv6QnaXhloyXEkMFhoGvNyPhl8x717ZcXF67dt-p7ayQE6Xg7ksWzkTSl4xK-uKlmnuTUi2xD1K&vault=true&intent=subscription" data-sdk-integration-source="button-factory"></script>
3+
<script>
4+
paypal.Buttons({
5+
style: {
6+
shape: 'pill',
7+
color: 'gold',
8+
layout: 'vertical',
9+
label: 'subscribe'
10+
},
11+
createSubscription: function(data, actions) {
12+
return actions.subscription.create({
13+
/* Creates the subscription */
14+
plan_id: 'P-5PT799148U8831139M22NQTQ'
15+
});
16+
},
17+
onApprove: function(data, actions) {
18+
alert(data.subscriptionID); // You can add optional success message for the subscriber here
19+
}
20+
}).render('#paypal-button-container-P-5PT799148U8831139M22NQTQ'); // Renders the PayPal button
21+
</script>

mkdocs.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,8 @@ nav:
8787
- CV: portfolio/14-cv/README.md
8888
- Blog:
8989
- blog/index.md
90+
- Support:
91+
- support/50rs-button.md
9092

9193
docs_dir: ./docs
9294

0 commit comments

Comments
 (0)