| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 0fe0125 commit 58054ef
2 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -18,7 +18,9 @@ PAYPAL.apps = PAYPAL.apps || {}; | |||
| 18 | 18 | id: "hosted_button_id", | |
| 19 | 19 | name: "item_name", | |
| 20 | 20 | number: "item_number", | |
| 21 | - lang: "lc" | ||
| 21 | + lang: "lc", | ||
| 22 | + recurrence: "p3", | ||
| 23 | + period: "t3" | ||
| 22 | 24 | }, | |
| 23 | 25 | buttonImgs = { | |
| 24 | 26 | buynow: "//www.paypalobjects.com/{locale}/i/btn/btn_buynow_{size}.gif", | |
@@ -89,6 +91,12 @@ PAYPAL.apps = PAYPAL.apps || {}; | |||
| 89 | 91 | // Subscribe buttons | |
| 90 | 92 | } else if (type === "subscribe") { | |
| 91 | 93 | data.add("cmd", "_xclick-subscriptions"); | |
| 94 | + | ||
| 95 | + // TODO: "amount cannot be used in prettyParams since it's overloaded | ||
| 96 | + // Find a better way to do this | ||
| 97 | + if (data.items.amount && !data.items.a3) { | ||
| 98 | + data.add("a3", data.items.amount.value); | ||
| 99 | + } | ||
| 92 | 100 | // Buy Now buttons | |
| 93 | 101 | } else { | |
| 94 | 102 | data.add("cmd", "_xclick"); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -113,11 +113,10 @@ <h2>Subscribe (Small)</h2> | |||
| 113 | 113 | <script src="../src/paypal-button.js?merchant=6XF3MPZBZV6HU" | |
| 114 | 114 | data-button="subscribe" | |
| 115 | 115 | data-name="Subscribe!" | |
| 116 | - data-amount="1.00" | ||
| 117 | 116 | data-size="small" | |
| 118 | - data-a3="1.00" | ||
| 119 | - data-p3="1" | ||
| 120 | - data-t3="M" | ||
| 117 | + data-amount="1.00" | ||
| 118 | + data-recurrence="1" | ||
| 119 | + data-period="M" | ||
| 121 | 120 | ></script> | |
| 122 | 121 | </div> | |
| 123 | 122 | ||
@@ -127,7 +126,8 @@ <h2>Subscribe (Large)</h2> | |||
| 127 | 126 | data-button="subscribe" | |
| 128 | 127 | data-name="Subscribe!" | |
| 129 | 128 | data-amount="1.00" | |
| 130 | - data-size="large" | ||
| 129 | + data-recurrence="1" | ||
| 130 | + data-period="M" | ||
| 131 | 131 | ></script> | |
| 132 | 132 | </div> | |
| 133 | 133 | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments