Version Description
Download this release
Release Info
Developer | mordauk |
Plugin | Easy Digital Downloads |
Version | 2.6 |
Comparing to | |
See all releases |
Code changes from version 2.5.17 to 2.6
- assets/css/edd-admin.css +1160 -234
- assets/css/edd-admin.min.css +1 -1
- assets/images/screenshots/26-customer.png +0 -0
- assets/images/screenshots/26-import.png +0 -0
- assets/images/screenshots/26-refund.png +0 -0
- assets/js/admin-scripts.js +267 -3
- assets/js/admin-scripts.min.js +2 -1
- assets/js/edd-ajax.js +68 -0
- assets/js/edd-ajax.min.js +1 -1
- assets/js/edd-checkout-global.js +41 -88
- assets/js/edd-checkout-global.min.js +1 -1
- easy-digital-downloads.php +23 -11
- includes/EDD_SL_Plugin_Updater.php +0 -2
- includes/admin/add-ons.php +3 -3
- includes/admin/class-edd-notices.php +15 -0
- includes/admin/customers/class-customer-table.php +12 -3
- includes/admin/customers/customer-actions.php +193 -0
- includes/admin/customers/customers.php +79 -11
- includes/admin/dashboard-widgets.php +2 -2
- includes/admin/discounts/add-discount.php +1 -1
- includes/admin/discounts/edit-discount.php +1 -1
- includes/admin/downloads/metabox.php +19 -9
- includes/admin/import/class-batch-import-downloads.php +336 -63
- includes/admin/import/class-batch-import-payments.php +582 -0
- includes/admin/import/class-batch-import.php +271 -0
- includes/admin/import/import-actions.php +75 -0
- includes/admin/import/import-functions.php +159 -0
- includes/admin/payments/class-payments-table.php +6 -1
- includes/admin/payments/view-order-details.php +18 -4
- includes/admin/reporting/class-api-requests-logs-list-table.php +1 -1
- includes/admin/reporting/class-gateway-error-logs-list-table.php +2 -2
- includes/admin/reporting/class-sales-logs-list-table.php +33 -9
- includes/admin/reporting/export/class-batch-export-payments.php +75 -49
- includes/admin/reporting/graphing.php +211 -92
- includes/admin/reporting/reports.php +6 -4
- includes/admin/settings/display-settings.php +2 -2
- includes/admin/settings/register-settings.php +311 -195
- includes/admin/thickbox.php +35 -39
- includes/admin/tools.php +488 -4
- includes/admin/upgrades/upgrade-functions.php +38 -0
- includes/admin/welcome.php +35 -38
- includes/ajax-functions.php +1 -1
- includes/api/class-edd-api-v2.php +443 -0
- includes/api/class-edd-api.php +76 -38
- includes/cart/functions.php +44 -16
- includes/checkout/functions.php +8 -22
- includes/checkout/template.php +8 -8
- includes/class-edd-cli.php +1 -1
- includes/class-edd-customer.php +234 -5
- includes/class-edd-db-customer-meta.php +208 -0
- includes/class-edd-db-customers.php +93 -21
- includes/class-edd-db.php +11 -1
- includes/class-edd-download.php +27 -23
- includes/class-edd-fees.php +50 -20
- includes/class-edd-html-elements.php +3 -3
- includes/class-edd-license-handler.php +4 -4
- includes/class-edd-roles.php +2 -1
- includes/class-edd-session.php +3 -3
- includes/deprecated-functions.php +19 -1
- includes/discount-functions.php +126 -3
- includes/download-functions.php +2 -2
- includes/emails/class-edd-email-tags.php +2 -2
- includes/emails/template.php +4 -4
- includes/gateways/actions.php +2 -2
- includes/gateways/amazon-payments.php +3 -3
- includes/gateways/paypal-standard.php +360 -31
- includes/install.php +15 -5
- includes/libraries/parsecsv.lib.php +1163 -0
- includes/mime-types.php +1 -0
- includes/misc-functions.php +30 -15
- includes/payments/class-edd-payment.php +30 -4
- includes/payments/class-payment-stats.php +14 -8
- includes/payments/class-payments-query.php +21 -1
- includes/payments/functions.php +20 -2
- includes/post-types.php +17 -0
- includes/process-purchase.php +38 -5
- includes/scripts.php +15 -33
- includes/shortcodes.php +91 -8
- includes/template-functions.php +66 -4
- includes/user-functions.php +106 -16
- languages/easy-digital-downloads-af.mo +0 -0
- languages/easy-digital-downloads-am.mo +0 -0
- languages/easy-digital-downloads-an.mo +0 -0
- languages/easy-digital-downloads-ar.mo +0 -0
- languages/easy-digital-downloads-ary.mo +0 -0
- languages/easy-digital-downloads-as.mo +0 -0
- languages/easy-digital-downloads-az.mo +0 -0
- languages/easy-digital-downloads-azb.mo +0 -0
- languages/easy-digital-downloads-bel.mo +0 -0
- languages/easy-digital-downloads-bg_BG.mo +0 -0
- languages/easy-digital-downloads-bn_BD.mo +0 -0
- languages/easy-digital-downloads-bs_BA.mo +0 -0
- languages/easy-digital-downloads-ca.mo +0 -0
- languages/easy-digital-downloads-ceb.mo +0 -0
- languages/easy-digital-downloads-co.mo +0 -0
- languages/easy-digital-downloads-cs_CZ.mo +0 -0
- languages/easy-digital-downloads-cy.mo +0 -0
- languages/easy-digital-downloads-da_DK.mo +0 -0
- languages/easy-digital-downloads-de_CH.mo +0 -0
- languages/easy-digital-downloads-de_DE.mo +0 -0
- languages/easy-digital-downloads-el.mo +0 -0
- languages/easy-digital-downloads-en_AU.mo +0 -0
- languages/easy-digital-downloads-en_CA.mo +0 -0
- languages/easy-digital-downloads-en_GB.mo +0 -0
- languages/easy-digital-downloads-en_NZ.mo +0 -0
- languages/easy-digital-downloads-en_ZA.mo +0 -0
- languages/easy-digital-downloads-eo.mo +0 -0
- languages/easy-digital-downloads-es_AR.mo +0 -0
- languages/easy-digital-downloads-es_CL.mo +0 -0
- languages/easy-digital-downloads-es_ES.mo +0 -0
- languages/easy-digital-downloads-es_MX.mo +0 -0
- languages/easy-digital-downloads-es_PE.mo +0 -0
- languages/easy-digital-downloads-es_VE.mo +0 -0
- languages/easy-digital-downloads-et.mo +0 -0
- languages/easy-digital-downloads-eu.mo +0 -0
- languages/easy-digital-downloads-fa_IR.mo +0 -0
- languages/easy-digital-downloads-fi.mo +0 -0
- languages/easy-digital-downloads-fo.mo +0 -0
- languages/easy-digital-downloads-fr_BE.mo +0 -0
- languages/easy-digital-downloads-fr_CA.mo +0 -0
- languages/easy-digital-downloads-fr_FR.mo +0 -0
- languages/easy-digital-downloads-fy.mo +0 -0
- languages/easy-digital-downloads-ga.mo +0 -0
- languages/easy-digital-downloads-gd.mo +0 -0
- languages/easy-digital-downloads-gl_ES.mo +0 -0
- languages/easy-digital-downloads-he_IL.mo +0 -0
- languages/easy-digital-downloads-hi_IN.mo +0 -0
- languages/easy-digital-downloads-hr.mo +0 -0
- languages/easy-digital-downloads-hu_HU.mo +0 -0
- languages/easy-digital-downloads-hy.mo +0 -0
- languages/easy-digital-downloads-id_ID.mo +0 -0
- languages/easy-digital-downloads-is_IS.mo +0 -0
- languages/easy-digital-downloads-it_IT.mo +0 -0
- languages/easy-digital-downloads-ja.mo +0 -0
- languages/easy-digital-downloads-jv_ID.mo +0 -0
- languages/easy-digital-downloads-ka_GE.mo +0 -0
- languages/easy-digital-downloads-kk.mo +0 -0
- languages/easy-digital-downloads-km.mo +0 -0
- languages/easy-digital-downloads-kn.mo +0 -0
- languages/easy-digital-downloads-ko_KR.mo +0 -0
- languages/easy-digital-downloads-ky_KY.mo +0 -0
- languages/easy-digital-downloads-lb_LU.mo +0 -0
- languages/easy-digital-downloads-lo.mo +0 -0
- languages/easy-digital-downloads-lt_LT.mo +0 -0
- languages/easy-digital-downloads-lv.mo +0 -0
- languages/easy-digital-downloads-mg_MG.mo +0 -0
- languages/easy-digital-downloads-mk_MK.mo +0 -0
- languages/easy-digital-downloads-ml_IN.mo +0 -0
- languages/easy-digital-downloads-mn.mo +0 -0
- languages/easy-digital-downloads-ms_MY.mo +0 -0
- languages/easy-digital-downloads-my_MM.mo +0 -0
- languages/easy-digital-downloads-nb_NO.mo +0 -0
- languages/easy-digital-downloads-ne_NP.mo +0 -0
- languages/easy-digital-downloads-nl_NL.mo +0 -0
- languages/easy-digital-downloads-nn_NO.mo +0 -0
- languages/easy-digital-downloads-oci.mo +0 -0
- languages/easy-digital-downloads-os.mo +0 -0
- languages/easy-digital-downloads-pa_IN.mo +0 -0
- languages/easy-digital-downloads-pl_PL.mo +0 -0
- languages/easy-digital-downloads-ps.mo +0 -0
- languages/easy-digital-downloads-pt_BR.mo +0 -0
- languages/easy-digital-downloads-pt_PT.mo +0 -0
- languages/easy-digital-downloads-ro_RO.mo +0 -0
- languages/easy-digital-downloads-ru_RU.mo +0 -0
- languages/easy-digital-downloads-sah.mo +0 -0
- languages/easy-digital-downloads-si_LK.mo +0 -0
- languages/easy-digital-downloads-sk_SK.mo +0 -0
- languages/easy-digital-downloads-sl_SI.mo +0 -0
- languages/easy-digital-downloads-snd.mo +0 -0
- languages/easy-digital-downloads-so_SO.mo +0 -0
- languages/easy-digital-downloads-sq.mo +0 -0
- languages/easy-digital-downloads-sr_RS.mo +0 -0
- languages/easy-digital-downloads-su_ID.mo +0 -0
- languages/easy-digital-downloads-sv_SE.mo +0 -0
- languages/easy-digital-downloads-sw.mo +0 -0
- languages/easy-digital-downloads-ta_IN.mo +0 -0
- languages/easy-digital-downloads-ta_LK.mo +0 -0
- languages/easy-digital-downloads-te.mo +0 -0
- languages/easy-digital-downloads-tg.mo +0 -0
- languages/easy-digital-downloads-th.mo +0 -0
- languages/easy-digital-downloads-tl.mo +0 -0
- languages/easy-digital-downloads-tr_TR.mo +0 -0
- languages/easy-digital-downloads-ug_CN.mo +0 -0
- languages/easy-digital-downloads-uk.mo +0 -0
- languages/easy-digital-downloads-ur.mo +0 -0
- languages/easy-digital-downloads-uz_UZ.mo +0 -0
- languages/easy-digital-downloads-vi.mo +0 -0
- languages/easy-digital-downloads-zh_CN.mo +0 -0
- languages/easy-digital-downloads-zh_TW.mo +0 -0
- languages/easy-digital-downloads.mo +0 -0
- languages/easy-digital-downloads.pot +1711 -1034
- readme.txt +91 -2
- templates/checkout_cart.php +11 -3
- templates/edd.css +16 -1
- templates/edd.min.css +1 -1
- templates/history-downloads.php +1 -1
- templates/history-purchases.php +1 -1
- templates/shortcode-content-excerpt.php +4 -4
- templates/shortcode-content-full.php +3 -2
- templates/shortcode-content-image.php +2 -2
- templates/shortcode-content-price.php +3 -2
- templates/shortcode-content-title.php +4 -3
- templates/shortcode-login.php +3 -3
- templates/shortcode-profile-editor.php +78 -5
- templates/shortcode-receipt.php +2 -2
- templates/shortcode-register.php +2 -2
- uninstall.php +3 -2
assets/css/edd-admin.css
CHANGED
@@ -7,173 +7,466 @@
|
|
7 |
* @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
|
8 |
*/
|
9 |
|
10 |
-
.edd-hidden {
|
11 |
-
|
12 |
-
|
13 |
-
|
14 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
15 |
|
16 |
/* General Settings Styles
|
17 |
-------------------------------------------------------------- */
|
18 |
-
|
19 |
-
.download_page_edd-settings .form-table
|
20 |
-
|
|
|
|
|
|
|
|
|
|
|
21 |
.download_page_edd-settings .form-table input.small-text ~ label,
|
22 |
.download_page_edd-settings .form-table input[type="checkbox"] + label { display: inline; }
|
23 |
.download_page_edd-settings .form-table tr > th > strong,
|
24 |
-
.download_page_edd-settings .form-table tr > th > h3
|
25 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
26 |
|
27 |
/* =Add Ons Styles
|
28 |
-------------------------------------------------------------- */
|
29 |
-
.edd-tab-span { float: right; bottom: 13px; position: relative; }
|
30 |
-
.edd-add-ons-footer { padding-top: 10px; }
|
31 |
-
#edd-add-ons h2 { margin: 0 0 15px; }
|
32 |
-
#edd-add-ons h2 .button-primary { position: absolute; }
|
33 |
-
#edd-add-ons .edd-extension { float: left; margin: 0 15px 15px 0; background: #fff; border: 1px solid #ccc; width: 320px; padding: 14px; height: 315px; position: relative; }
|
34 |
-
#edd-add-ons .edd-extension h3 { margin: 0 0 8px; font-size: 13px; }
|
35 |
-
#edd-add-ons .edd-extension .button-secondary { position: absolute; bottom: 14px; left: 14px; }
|
36 |
-
#edd-add-ons .edd-browse-all { clear:both; width:100%; }
|
37 |
-
#edd-add-ons .edd-extension .third-party { display: none; }
|
38 |
-
#edd-add-ons .edd-starter-package { border-color: #62a9d7; background-color: #85c0e5; color: #fff; }
|
39 |
-
#edd-add-ons .edd-starter-package h3 { color: #fff; }
|
40 |
-
#edd-add-ons .edd-extension .wp-post-image { width: 100%; height: auto; }
|
41 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
42 |
|
43 |
/* Discount Code Styles
|
44 |
-------------------------------------------------------------- */
|
45 |
-
|
46 |
-
#edd-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
47 |
|
48 |
/* Payment History Styles
|
49 |
-------------------------------------------------------------- */
|
|
|
50 |
#edd-payment-filters {
|
51 |
-
|
|
|
52 |
background-image: -webkit-gradient(linear, left bottom, left top, from(#f5f5f5), to(#fafafa));
|
53 |
background-image: -webkit-linear-gradient(bottom, #f5f5f5, #fafafa);
|
54 |
background-image: -moz-linear-gradient(bottom, #f5f5f5, #fafafa);
|
55 |
background-image: -o-linear-gradient(bottom, #f5f5f5, #fafafa);
|
56 |
background-image: linear-gradient(to top, #f5f5f5, #fafafa);
|
57 |
border-color: #dfdfdf;
|
58 |
-
overflow: auto;
|
59 |
-
margin: 8px 0;
|
60 |
-
padding: 12px;
|
61 |
border-width: 1px;
|
62 |
border-style: solid;
|
63 |
border-radius: 3px;
|
64 |
font-size: 13px;
|
65 |
line-height: 2.1em;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
66 |
}
|
67 |
-
|
68 |
-
|
69 |
-
|
70 |
-
|
71 |
-
|
72 |
-
|
73 |
-
.wp-list-table.downloads th#user { width: 130px; }
|
74 |
-
.edd-mobile-link { line-height: 32px; vertical-align: middle; }
|
75 |
-
.edd-mobile-link img { max-width: 80%; height: auto; float: left; }
|
76 |
@media handheld, only screen and (max-width: 640px) {
|
77 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
78 |
}
|
79 |
-
.download_page_edd-payment-history .ui-dialog .ui-dialog-titlebar-close span { margin-left: -8px; margin-top: -8px; }
|
80 |
-
#edd-download-link-textarea { width: 100%; }
|
81 |
|
82 |
/* Metabox Styles
|
83 |
-------------------------------------------------------------- */
|
84 |
-
|
85 |
-
.
|
86 |
-
|
87 |
-
|
88 |
-
|
89 |
-
|
90 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
91 |
#downloadinformation .edd_meta_table_wrap table input,
|
92 |
#downloadinformation .edd_meta_table_wrap table select,
|
93 |
-
#downloadinformation .edd_meta_table_wrap table textarea {
|
94 |
-
|
95 |
-
|
96 |
-
|
97 |
-
.
|
98 |
-
|
99 |
-
|
100 |
-
.
|
101 |
-
|
102 |
-
|
103 |
-
.
|
104 |
-
|
105 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
106 |
|
107 |
/* Payment Details
|
108 |
-------------------------------------------------------------- */
|
109 |
-
|
110 |
-
.edd-admin-box
|
111 |
-
|
112 |
-
|
113 |
-
.edd-
|
114 |
-
|
115 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
116 |
#edd-order-update .inside,
|
117 |
-
#edd-order-details .inside {
|
118 |
-
|
|
|
|
|
|
|
|
|
|
|
119 |
#edd-order-update input[type="number"].edd-payment-time-hour,
|
120 |
-
#edd-order-update input[type="number"].edd-payment-time-min {
|
121 |
-
|
122 |
-
|
123 |
-
#edd-
|
124 |
-
|
125 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
126 |
#edd-purchased-files ul,
|
127 |
#edd-order-address-country-wrap select,
|
128 |
#edd-customer-details .order-data-address input,
|
129 |
#edd-edit-order-form .column input,
|
130 |
-
#edd-customer-details .order-data-column p.data input {
|
131 |
-
|
132 |
-
|
133 |
-
|
134 |
-
#edd-
|
135 |
-
|
136 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
137 |
#edd-edit-order-form .column,
|
138 |
#edd-purchased-files .row > ul > li,
|
139 |
-
#edd-purchased-files .inside > ul > li {
|
140 |
-
|
141 |
-
|
142 |
-
|
143 |
-
|
144 |
-
|
145 |
-
|
146 |
-
#edd-purchased-files .
|
147 |
-
|
148 |
-
|
149 |
-
|
150 |
-
#
|
151 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
152 |
|
153 |
@media screen and ( max-width: 782px ) {
|
|
|
154 |
.order-data-column input[type="email"] {
|
155 |
padding: 6px 10px;
|
156 |
}
|
|
|
157 |
}
|
|
|
158 |
@media screen and ( min-width: 851px ) {
|
|
|
159 |
#edd-purchased-files .inside li.actions {
|
160 |
text-align: right;
|
161 |
}
|
|
|
162 |
}
|
|
|
163 |
@media screen and ( max-width: 1024px ) {
|
|
|
164 |
#edd-edit-order-form .column {
|
165 |
width: 49%;
|
166 |
}
|
|
|
167 |
}
|
|
|
168 |
@media screen and ( max-width: 1280px ) and ( min-width: 1279px ) {
|
|
|
169 |
#edd-purchased-files .inside li.actions {
|
170 |
width: 35%;
|
171 |
}
|
172 |
#edd-edit-order-form .column {
|
173 |
width: 32%;
|
174 |
}
|
|
|
175 |
}
|
|
|
176 |
@media screen and ( min-width: 1280px ) {
|
|
|
177 |
#edd-edit-order-form .column, #edd-purchased-files.columns-3 .row > ul > li,
|
178 |
#edd-purchased-files.columns-3 .inside > ul > li {
|
179 |
width: 32%; margin-right: 3%;
|
@@ -198,145 +491,505 @@ textarea#edd-payment-note { width: 100%; height: 4em; margin: 0; }
|
|
198 |
#edd-purchased-files.columns-4 li.actions {
|
199 |
width: 25%; margin-top: 0; margin-right: 0;
|
200 |
}
|
|
|
201 |
}
|
|
|
202 |
@media screen and ( max-width: 1284px ) {
|
|
|
203 |
#edd-edit-order-form .column strong {
|
204 |
display:block;
|
205 |
}
|
|
|
206 |
}
|
207 |
|
208 |
/** Stats */
|
209 |
-
#edd_product_stats .label {
|
210 |
-
|
211 |
-
|
212 |
-
#edd_product_stats
|
213 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
214 |
|
215 |
/* Dashboard Widget Styles
|
216 |
-------------------------------------------------------------- */
|
217 |
-
|
218 |
-
.edd_dashboard_widget
|
219 |
-
|
220 |
-
|
221 |
-
|
222 |
-
.edd_dashboard_widget .
|
223 |
-
|
224 |
-
|
225 |
-
|
226 |
-
.edd_dashboard_widget .
|
227 |
-
|
228 |
-
|
229 |
-
|
230 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
231 |
@media handheld, only screen and (max-width: 1000px) {
|
232 |
-
|
|
|
|
|
|
|
|
|
233 |
}
|
234 |
|
235 |
/* Reports Styles
|
236 |
-------------------------------------------------------------- */
|
237 |
-
|
|
|
|
|
|
|
238 |
#edd-graphs-date-options,
|
239 |
-
#edd-date-range-options {
|
240 |
-
|
241 |
-
|
242 |
-
|
243 |
-
|
244 |
-
|
245 |
-
|
246 |
-
|
247 |
-
|
248 |
-
.
|
249 |
-
|
250 |
-
|
251 |
-
.
|
252 |
-
|
253 |
-
|
254 |
-
|
255 |
-
|
256 |
-
|
257 |
-
|
258 |
-
.edd-
|
259 |
-
|
260 |
-
|
261 |
-
|
262 |
-
|
263 |
-
.edd-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
264 |
|
265 |
/* Upgrades page styles
|
266 |
-------------------------------------------------------------- */
|
267 |
|
268 |
/* Settings page styles
|
269 |
-------------------------------------------------------------- */
|
270 |
-
|
|
|
|
|
|
|
271 |
#edd_tax_rates .edd_tax_country *,
|
272 |
-
#edd_tax_rates .edd_tax_state * {
|
|
|
|
|
273 |
#edd_tax_rates .edd_tax_country,
|
274 |
-
#edd_tax_rates .edd_tax_state {
|
275 |
-
|
276 |
-
|
277 |
-
|
278 |
-
|
279 |
-
|
280 |
-
|
281 |
-
|
282 |
-
|
283 |
-
.
|
284 |
-
.
|
285 |
-
.
|
286 |
-
.
|
287 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
288 |
|
289 |
/* Taxonomy styles
|
290 |
-------------------------------------------------------------- */
|
291 |
-
|
292 |
-
.post-type-download .fixed .column-
|
293 |
-
|
294 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
295 |
|
296 |
/* System Info page styles
|
297 |
-------------------------------------------------------------- */
|
298 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
299 |
|
300 |
/* Button styles
|
301 |
-------------------------------------------------------------- */
|
302 |
-
|
|
|
|
|
|
|
|
|
|
|
303 |
|
304 |
/* Global Graph Styles
|
305 |
-------------------------------------------------------------- */
|
306 |
-
|
307 |
-
.edd-graph .
|
|
|
|
|
|
|
|
|
|
|
308 |
|
309 |
/* API Table Styles
|
310 |
-------------------------------------------------------------- */
|
311 |
-
|
|
|
|
|
|
|
312 |
|
313 |
/* General styles
|
314 |
-------------------------------------------------------------- */
|
315 |
-
|
316 |
-
.
|
317 |
-
|
318 |
-
|
319 |
-
.chosen-container .
|
320 |
-
|
321 |
-
|
322 |
-
|
323 |
-
|
324 |
-
|
325 |
-
.
|
326 |
-
|
327 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
328 |
|
329 |
@media screen and ( max-width: 1100px ) {
|
|
|
330 |
.edd-mix-chart {
|
331 |
display: block;
|
332 |
width: 100%;
|
333 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
334 |
}
|
335 |
|
336 |
@media screen and ( max-width: 782px ) {
|
|
|
337 |
.post-type-download .nav-tab-wrapper a {
|
338 |
-
padding: 2px 4px;
|
339 |
font-size: 50%;
|
|
|
340 |
}
|
341 |
.download_page_edd-tools .apikeys .column-user {
|
342 |
width: 80px;
|
@@ -349,70 +1002,343 @@ div[class^="license-"] .edd-license-data p { margin-left: 4px; }
|
|
349 |
[class^="license-"] input[type="text"] {
|
350 |
margin-bottom: 3px;
|
351 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
352 |
}
|
353 |
|
354 |
/* Customer Styles
|
355 |
-------------------------------------------------------------- */
|
356 |
-
|
357 |
-
#edd-item-tab-wrapper
|
358 |
-
#edd-item-tab-wrapper-list .inactive { background-color: #fff; color: #eee; border-left: 1px solid #e5e5e5; }
|
359 |
-
#edd-item-tab-wrapper-list .active { border-width: 1px 1px 1px 0; border-style: solid; border-color: #e5e5e5; }
|
360 |
-
#edd-item-tab-wrapper-list :not(:last-child) { margin-bottom: 3px; }
|
361 |
-
#edd-item-tab-wrapper-list .dashicons { font-size: 24px; line-height: 32px; }
|
362 |
-
#edd-item-card-wrapper .left { float: left; }
|
363 |
-
#edd-item-card-wrapper .right { float: right; }
|
364 |
-
#edd-item-card-wrapper input { font-weight: normal; }
|
365 |
-
#edd-item-card-wrapper {
|
366 |
display: inline-block;
|
367 |
margin-left: -1px;
|
368 |
-
|
369 |
-
|
370 |
-
|
371 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
372 |
border: 1px solid #e5e5e5;
|
373 |
webkit-box-shadow: 0 1px 1px rgba(0,0,0,0.04);
|
374 |
box-shadow: 0 1px 1px rgba(0,0,0,0.04);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
375 |
}
|
376 |
-
#edd-item-card-wrapper .customer-section { border-bottom: 1px solid #eee; margin-bottom: 10px; overflow: auto; }
|
377 |
-
#edd-item-card-wrapper .customer-section table { margin-bottom: 20px; }
|
378 |
-
#edd-item-card-wrapper > div { padding: 0px 20px; }
|
379 |
-
#edd-item-card-wrapper > div:first-child { padding-top: 20px; }
|
380 |
-
#edd-item-card-wrapper > div:last-child { padding-bottom: 20px; border: none; }
|
381 |
-
#edd-item-card-wrapper .avatar-wrap { padding-right: 10px; text-align: center; }
|
382 |
-
#edd-item-card-wrapper .customer-id { font-size: 24px; font-weight: 600; }
|
383 |
-
#edd-item-card-wrapper .customer-main-wrapper input { width: 200px; }
|
384 |
-
#edd-item-card-wrapper .customer-address-wrapper { max-width: 33%; margin-right: 25px; width: 202px; }
|
385 |
-
#edd-item-card-wrapper .customer-address-wrapper select { width: 200px;}
|
386 |
-
#edd-item-card-wrapper .customer-info { margin-top: 5px; min-height: 185px; margin-bottom: 10px; }
|
387 |
-
#edd-item-card-wrapper .info-wrapper { min-height: 125px; overflow: visible; }
|
388 |
-
#edd-item-card-wrapper a.delete { text-decoration: none; color: #ff0000; margin-right: 5px; }
|
389 |
-
.customer-info .customer-name { font-size: 24px; font-weight: 600; }
|
390 |
-
.customer-edit-link a, .disconnect-user a { font-size: 12px; font-weight: normal; text-decoration: none; }
|
391 |
-
#customer-edit-actions { text-align: center; margin-bottom: 20px; line-height: 28px; }
|
392 |
-
#customer-edit-actions .button-secondary { margin-right: 10px; }
|
393 |
-
#edd-item-card-wrapper .info-item { line-height: 16px; display: block; padding-bottom: 5px; }
|
394 |
-
#edd-item-card-wrapper .edit-item { display: none; }
|
395 |
-
#edd-item-card-wrapper .edd_user_search_results { left: 1px; top: 16px;}
|
396 |
-
#edd-item-card-wrapper .edd_user_search_results ul { width: 200px }
|
397 |
-
#edd-item-stats-wrapper { margin: 0 auto; text-align: center; min-height: 30px; }
|
398 |
-
#edd-item-stats-wrapper li { width: 50%; float: left; line-height: 22px; font-size: 14px; }
|
399 |
-
#edd-item-stats-wrapper a { text-decoration: none; }
|
400 |
-
#edd-item-stats-wrapper .dashicons { color: #888; }
|
401 |
-
#edd-item-tables-wrapper table { width: 100%; text-align: center; }
|
402 |
-
#edd-item-tables-wrapper th { text-align: center; }
|
403 |
-
#edd-item-tables-wrapper .downloads tr > th:first-child, #edd-item-tables-wrapper .downloads tr > td:first-child { text-align: left; }
|
404 |
-
#edd-item-tables-wrapper .downloads tr > td:only-child { text-align: center; }
|
405 |
-
#edd-item-notes-wrapper { min-height: 50px; }
|
406 |
-
.edd-item-notes-header span, .edd-item-notes-header img { font-weight: 600; line-height: 30px; vertical-align: middle; }
|
407 |
-
.customer-note-input { width: 100%; margin-bottom: 5px; }
|
408 |
-
#edd-customer-notes div:nth-of-type(even) { background-color: #fcfcfc; }
|
409 |
-
.customer-note-wrapper { border-bottom: 1px solid #f9f9f9; min-height: 38px; padding: 7px 0 7px 7px; }
|
410 |
-
.customer-note-wrapper span { display: block; }
|
411 |
-
.note-content-wrap { padding-top: 7px; }
|
412 |
-
.delete-customer { text-align: center; }
|
413 |
-
#edd-item-card-wrapper .notice-wrap { margin-left: -20px; margin-right: -20px; padding-left: 20px; padding-right: 20px; }
|
414 |
|
415 |
/* Tools Styles
|
416 |
-------------------------------------------------------------- */
|
417 |
-
|
418 |
-
.
|
|
|
|
|
|
|
|
|
|
|
|
7 |
* @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
|
8 |
*/
|
9 |
|
10 |
+
.edd-hidden {
|
11 |
+
display: none;
|
12 |
+
}
|
13 |
+
.edd-clearfix:after {
|
14 |
+
content: ".";
|
15 |
+
display: block;
|
16 |
+
height: 0;
|
17 |
+
text-indent: -9999px;
|
18 |
+
visibility: hidden;
|
19 |
+
}
|
20 |
+
.edd-wrap a {
|
21 |
+
text-decoration: none;
|
22 |
+
}
|
23 |
+
a.edd-delete {
|
24 |
+
color: #a00;
|
25 |
+
}
|
26 |
+
a.edd-delete:hover {
|
27 |
+
color: #f00;
|
28 |
+
}
|
29 |
|
30 |
/* General Settings Styles
|
31 |
-------------------------------------------------------------- */
|
32 |
+
|
33 |
+
.download_page_edd-settings .form-table label {
|
34 |
+
color: #666;
|
35 |
+
font-size: 14px;
|
36 |
+
font-style: italic;
|
37 |
+
margin: 4px 0 0;
|
38 |
+
}
|
39 |
+
|
40 |
.download_page_edd-settings .form-table input.small-text ~ label,
|
41 |
.download_page_edd-settings .form-table input[type="checkbox"] + label { display: inline; }
|
42 |
.download_page_edd-settings .form-table tr > th > strong,
|
43 |
+
.download_page_edd-settings .form-table tr > th > h3 {
|
44 |
+
font-size: 1.2em;
|
45 |
+
font-weight: 600;
|
46 |
+
margin: 0 auto;
|
47 |
+
}
|
48 |
+
|
49 |
+
/* Tooltips */
|
50 |
+
.edd-help-tip {
|
51 |
+
cursor: help;
|
52 |
+
}
|
53 |
+
|
54 |
+
.edd-ui-tooltip {
|
55 |
+
background: #333 !important;
|
56 |
+
border-radius: 3px !important;
|
57 |
+
box-shadow: 1px 1px 2px 1px rgba(214,214,214,0.5);
|
58 |
+
color: #dedede !important;
|
59 |
+
max-width: 300px;
|
60 |
+
padding: 7px;
|
61 |
+
text-rendering: optimizeLegibility;
|
62 |
+
}
|
63 |
|
64 |
/* =Add Ons Styles
|
65 |
-------------------------------------------------------------- */
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
66 |
|
67 |
+
#edd-add-ons h2.nav-tab-wrapper {
|
68 |
+
position: relative;
|
69 |
+
}
|
70 |
+
|
71 |
+
.edd-tab-span {
|
72 |
+
top: -6px;
|
73 |
+
right: 0;
|
74 |
+
position: absolute;
|
75 |
+
}
|
76 |
+
.edd-add-ons-footer {
|
77 |
+
padding-top: 10px;
|
78 |
+
}
|
79 |
+
#edd-add-ons h2 {
|
80 |
+
margin: 0 0 15px;
|
81 |
+
}
|
82 |
+
#edd-add-ons h2 .button-primary {
|
83 |
+
position: absolute;
|
84 |
+
}
|
85 |
+
#edd-add-ons .edd-extension {
|
86 |
+
background: #fff;
|
87 |
+
border: 1px solid #ccc;
|
88 |
+
float: left;
|
89 |
+
padding: 14px;
|
90 |
+
position: relative;
|
91 |
+
margin: 0 15px 15px 0;
|
92 |
+
width: 320px;
|
93 |
+
height: 315px;
|
94 |
+
}
|
95 |
+
#edd-add-ons .edd-extension h3 {
|
96 |
+
font-size: 13px;
|
97 |
+
margin: 0 0 8px;
|
98 |
+
}
|
99 |
+
#edd-add-ons .edd-extension .button-secondary {
|
100 |
+
position: absolute;
|
101 |
+
bottom: 14px;
|
102 |
+
left: 14px;
|
103 |
+
}
|
104 |
+
#edd-add-ons .edd-browse-all {
|
105 |
+
clear:both;
|
106 |
+
width:100%;
|
107 |
+
}
|
108 |
+
#edd-add-ons .edd-extension .third-party {
|
109 |
+
display: none;
|
110 |
+
}
|
111 |
+
#edd-add-ons .edd-starter-package {
|
112 |
+
background-color: #85c0e5;
|
113 |
+
border-color: #62a9d7;
|
114 |
+
color: #fff;
|
115 |
+
}
|
116 |
+
#edd-add-ons .edd-starter-package h3 {
|
117 |
+
color: #fff;
|
118 |
+
}
|
119 |
+
#edd-add-ons .edd-extension .wp-post-image {
|
120 |
+
width: 100%;
|
121 |
+
height: auto;
|
122 |
+
}
|
123 |
|
124 |
/* Discount Code Styles
|
125 |
-------------------------------------------------------------- */
|
126 |
+
|
127 |
+
#edd-products {
|
128 |
+
height: 100px;
|
129 |
+
min-width: 200px;
|
130 |
+
}
|
131 |
+
#edd-add-discount input[type="checkbox"],
|
132 |
+
#edd-edit-discount input[type="checkbox"] {
|
133 |
+
width: 15px;
|
134 |
+
}
|
135 |
|
136 |
/* Payment History Styles
|
137 |
-------------------------------------------------------------- */
|
138 |
+
|
139 |
#edd-payment-filters {
|
140 |
+
background: #f5f5f5;
|
141 |
+
clear: both;
|
142 |
background-image: -webkit-gradient(linear, left bottom, left top, from(#f5f5f5), to(#fafafa));
|
143 |
background-image: -webkit-linear-gradient(bottom, #f5f5f5, #fafafa);
|
144 |
background-image: -moz-linear-gradient(bottom, #f5f5f5, #fafafa);
|
145 |
background-image: -o-linear-gradient(bottom, #f5f5f5, #fafafa);
|
146 |
background-image: linear-gradient(to top, #f5f5f5, #fafafa);
|
147 |
border-color: #dfdfdf;
|
|
|
|
|
|
|
148 |
border-width: 1px;
|
149 |
border-style: solid;
|
150 |
border-radius: 3px;
|
151 |
font-size: 13px;
|
152 |
line-height: 2.1em;
|
153 |
+
overflow: auto;
|
154 |
+
padding: 12px;
|
155 |
+
margin: 8px 0;
|
156 |
+
}
|
157 |
+
#edd-payments-filter ul.subsubsub {
|
158 |
+
margin-bottom: 8px;
|
159 |
+
}
|
160 |
+
#edd-payment-filters p {
|
161 |
+
color: #777;
|
162 |
+
}
|
163 |
+
tr.status-refunded td {
|
164 |
+
background: #cecece;
|
165 |
+
border-top-color: #ccc;
|
166 |
+
}
|
167 |
+
.wp-list-table.downloads th#ID {
|
168 |
+
width: 80px;
|
169 |
+
}
|
170 |
+
.wp-list-table.downloads th#details {
|
171 |
+
width: 130px;
|
172 |
+
}
|
173 |
+
.wp-list-table.downloads th#date {
|
174 |
+
width: 140px;
|
175 |
+
}
|
176 |
+
.wp-list-table.downloads th#user {
|
177 |
+
width: 130px;
|
178 |
+
}
|
179 |
+
.edd-mobile-link {
|
180 |
+
line-height: 32px;
|
181 |
+
vertical-align: middle;
|
182 |
}
|
183 |
+
.edd-mobile-link img {
|
184 |
+
max-width: 80%;
|
185 |
+
height: auto;
|
186 |
+
float: left;
|
187 |
+
}
|
188 |
+
|
|
|
|
|
|
|
189 |
@media handheld, only screen and (max-width: 640px) {
|
190 |
+
|
191 |
+
.wp-list-table.downloads th {
|
192 |
+
width: auto!important;
|
193 |
+
}
|
194 |
+
|
195 |
+
}
|
196 |
+
|
197 |
+
.download_page_edd-payment-history .ui-dialog .ui-dialog-titlebar-close span {
|
198 |
+
margin-left: -8px;
|
199 |
+
margin-top: -8px;
|
200 |
+
}
|
201 |
+
#edd-download-link-textarea {
|
202 |
+
width: 100%;
|
203 |
}
|
|
|
|
|
204 |
|
205 |
/* Metabox Styles
|
206 |
-------------------------------------------------------------- */
|
207 |
+
|
208 |
+
.edd_file_help_labels {
|
209 |
+
}
|
210 |
+
.edd_files_name_label {
|
211 |
+
width: 225px;
|
212 |
+
float: left;
|
213 |
+
}
|
214 |
+
.edd_files_url_label {
|
215 |
+
width: 220px;
|
216 |
+
float: left;
|
217 |
+
}
|
218 |
+
#postbox-container-1 .edd_files_name_label {
|
219 |
+
width: 80px;
|
220 |
+
}
|
221 |
+
#postbox-container-1 .edd_files_url_label {
|
222 |
+
width: 80px;
|
223 |
+
}
|
224 |
+
.edd_add_repeatable {
|
225 |
+
display: inline-block;
|
226 |
+
}
|
227 |
+
.edd_repeatable_row td {
|
228 |
+
vertical-align: middle;
|
229 |
+
}
|
230 |
#downloadinformation .edd_meta_table_wrap table input,
|
231 |
#downloadinformation .edd_meta_table_wrap table select,
|
232 |
+
#downloadinformation .edd_meta_table_wrap table textarea {
|
233 |
+
margin: 4px 0;
|
234 |
+
width: 100%;
|
235 |
+
}
|
236 |
+
#downloadinformation .edd_meta_table_wrap table .submit input {
|
237 |
+
width: auto;
|
238 |
+
}
|
239 |
+
.edd_repeatable_upload_wrapper .edd_repeatable_upload_field_container {
|
240 |
+
position: relative;
|
241 |
+
}
|
242 |
+
.edd_upload_file {
|
243 |
+
background: #fff;
|
244 |
+
display: block;
|
245 |
+
padding: 2px 8px 2px;
|
246 |
+
position: absolute;
|
247 |
+
top: 3px;
|
248 |
+
right: 7px;
|
249 |
+
}
|
250 |
+
.edd_upload_field {
|
251 |
+
padding-right: 8em;
|
252 |
+
}
|
253 |
+
.edd_remove_repeatable {
|
254 |
+
border: none;
|
255 |
+
cursor: pointer;
|
256 |
+
display: inline-block;
|
257 |
+
padding: 0;
|
258 |
+
overflow: hidden;
|
259 |
+
margin: 8px 0 0 0;
|
260 |
+
text-indent: -9999px;
|
261 |
+
width: 10px;
|
262 |
+
height: 10px;
|
263 |
+
}
|
264 |
+
.edd_remove_repeatable:active,
|
265 |
+
.edd_remove_repeatable:hover,
|
266 |
+
.edd_remove_repeatable:focus {
|
267 |
+
background-position: -10px 0!important;
|
268 |
+
}
|
269 |
+
.edd_draghandle {
|
270 |
+
background: url(../images/edd-cross-hair.png);
|
271 |
+
cursor: move;
|
272 |
+
display: block;
|
273 |
+
margin: 4px 0 0 0;
|
274 |
+
width: 20px;
|
275 |
+
height: 20px;
|
276 |
+
}
|
277 |
+
textarea#edd-payment-note {
|
278 |
+
width: 100%;
|
279 |
+
height: 4em;
|
280 |
+
margin: 0;
|
281 |
+
}
|
282 |
+
.edd-price-field {
|
283 |
+
width: 80px;
|
284 |
+
}
|
285 |
+
.edd_repeatable_upload_wrapper .pricing select,
|
286 |
+
.edd_repeatable_product_wrapper .edd-select {
|
287 |
+
min-width: 100%;
|
288 |
+
}
|
289 |
+
#edd_product_notes_field {
|
290 |
+
margin: 0;
|
291 |
+
width: 98%;
|
292 |
+
height: 4em;
|
293 |
+
}
|
294 |
+
.edd_repeatable_default_wrapper {
|
295 |
+
text-align: center;
|
296 |
+
width: 25px;
|
297 |
+
}
|
298 |
|
299 |
/* Payment Details
|
300 |
-------------------------------------------------------------- */
|
301 |
+
|
302 |
+
.edd-admin-box .label {
|
303 |
+
font-weight: 600;
|
304 |
+
}
|
305 |
+
.edd-admin-box-inside {
|
306 |
+
border-bottom: 1px solid #eee;
|
307 |
+
clear: both;
|
308 |
+
padding: 3px 12px;
|
309 |
+
margin: 0;
|
310 |
+
word-break: break-word;
|
311 |
+
}
|
312 |
+
.rtl .edd-admin-box-inside {
|
313 |
+
padding: 5px 10px 5px 0;
|
314 |
+
}
|
315 |
+
.edd-admin-box-inside .strong {
|
316 |
+
font-weight: 600;
|
317 |
+
}
|
318 |
+
.edd-payment-fees .fee-label {
|
319 |
+
color: #666;
|
320 |
+
font-weight: normal;
|
321 |
+
}
|
322 |
+
.edd-admin-box .right {
|
323 |
+
float: right;
|
324 |
+
}
|
325 |
+
.rtl .edd-admin-box .right {
|
326 |
+
float: left;
|
327 |
+
margin-left: 10px;
|
328 |
+
}
|
329 |
#edd-order-update .inside,
|
330 |
+
#edd-order-details .inside {
|
331 |
+
margin: 0;
|
332 |
+
padding: 0;
|
333 |
+
}
|
334 |
+
#edd-order-update input.edd_datepicker {
|
335 |
+
width: 180px;
|
336 |
+
}
|
337 |
#edd-order-update input[type="number"].edd-payment-time-hour,
|
338 |
+
#edd-order-update input[type="number"].edd-payment-time-min {
|
339 |
+
width: 50px;
|
340 |
+
}
|
341 |
+
#edd-order-resend-receipt .inside {
|
342 |
+
margin-top: 11px;
|
343 |
+
}
|
344 |
+
.edd-admin-box-inside:last-child {
|
345 |
+
border-bottom: 0;
|
346 |
+
}
|
347 |
+
#edd-edit-order-form .data-payment-key {
|
348 |
+
word-break: break-all;
|
349 |
+
}
|
350 |
+
.edd-order-update-box #major-publishing-actions .button-secondary {
|
351 |
+
margin-right: 10px;
|
352 |
+
}
|
353 |
+
#edd-purchased-files .edd-select-chosen {
|
354 |
+
width: 196px;
|
355 |
+
}
|
356 |
#edd-purchased-files ul,
|
357 |
#edd-order-address-country-wrap select,
|
358 |
#edd-customer-details .order-data-address input,
|
359 |
#edd-edit-order-form .column input,
|
360 |
+
#edd-customer-details .order-data-column p.data input {
|
361 |
+
clear: both;
|
362 |
+
display: block;
|
363 |
+
}
|
364 |
+
#edd-customer-details .actions {
|
365 |
+
float: right;
|
366 |
+
}
|
367 |
+
.edd-order-data input.small-text {
|
368 |
+
margin: 0;
|
369 |
+
}
|
370 |
+
.edd-order-data input.med-text {
|
371 |
+
margin: 0;
|
372 |
+
width: 100px;
|
373 |
+
}
|
374 |
+
#edd-order-update span.label {
|
375 |
+
display: inline;
|
376 |
+
width: 50px;
|
377 |
+
}
|
378 |
+
.edd-order-update-box .button-primary {
|
379 |
+
margin-right: 0;
|
380 |
+
}
|
381 |
+
#edd-edit-order-form .column .description {
|
382 |
+
padding-right: 10px;
|
383 |
+
}
|
384 |
#edd-edit-order-form .column,
|
385 |
#edd-purchased-files .row > ul > li,
|
386 |
+
#edd-purchased-files .inside > ul > li {
|
387 |
+
display: inline-block;
|
388 |
+
line-height: 30px;
|
389 |
+
position: relative;
|
390 |
+
margin-right: 5%;
|
391 |
+
vertical-align: middle;
|
392 |
+
}
|
393 |
+
#edd-purchased-files li.actions {
|
394 |
+
min-width: 200px;
|
395 |
+
text-align: right;
|
396 |
+
}
|
397 |
+
#edd-purchased-files ul li.remove {
|
398 |
+
text-align: right;
|
399 |
+
}
|
400 |
+
#edd-purchased-files .row {
|
401 |
+
border-bottom: 1px solid #eee;
|
402 |
+
padding: 12px;
|
403 |
+
}
|
404 |
+
#edd-purchased-files ul {
|
405 |
+
font-size: 0;
|
406 |
+
}
|
407 |
+
#edd-purchased-files ul li {
|
408 |
+
font-size: 13px;
|
409 |
+
}
|
410 |
+
#edd-order-data .data span {
|
411 |
+
color: #666;
|
412 |
+
font-weight: 600;
|
413 |
+
}
|
414 |
+
#edd-purchased-files .inside {
|
415 |
+
padding: 12px;
|
416 |
+
}
|
417 |
+
#edd-order-recalc-total {
|
418 |
+
float: right;
|
419 |
+
}
|
420 |
+
.edd-price-field {
|
421 |
+
width: 80px;
|
422 |
+
}
|
423 |
+
.edd_repeatable_upload_wrapper .pricing select,
|
424 |
+
.edd_repeatable_product_wrapper .edd-select,
|
425 |
+
#edd_products .edd-select {
|
426 |
+
min-width: 100%;
|
427 |
+
max-width: 200px;
|
428 |
+
}
|
429 |
+
.edd_repeatable_product_wrapper td {
|
430 |
+
overflow: visible;
|
431 |
+
}
|
432 |
|
433 |
@media screen and ( max-width: 782px ) {
|
434 |
+
|
435 |
.order-data-column input[type="email"] {
|
436 |
padding: 6px 10px;
|
437 |
}
|
438 |
+
|
439 |
}
|
440 |
+
|
441 |
@media screen and ( min-width: 851px ) {
|
442 |
+
|
443 |
#edd-purchased-files .inside li.actions {
|
444 |
text-align: right;
|
445 |
}
|
446 |
+
|
447 |
}
|
448 |
+
|
449 |
@media screen and ( max-width: 1024px ) {
|
450 |
+
|
451 |
#edd-edit-order-form .column {
|
452 |
width: 49%;
|
453 |
}
|
454 |
+
|
455 |
}
|
456 |
+
|
457 |
@media screen and ( max-width: 1280px ) and ( min-width: 1279px ) {
|
458 |
+
|
459 |
#edd-purchased-files .inside li.actions {
|
460 |
width: 35%;
|
461 |
}
|
462 |
#edd-edit-order-form .column {
|
463 |
width: 32%;
|
464 |
}
|
465 |
+
|
466 |
}
|
467 |
+
|
468 |
@media screen and ( min-width: 1280px ) {
|
469 |
+
|
470 |
#edd-edit-order-form .column, #edd-purchased-files.columns-3 .row > ul > li,
|
471 |
#edd-purchased-files.columns-3 .inside > ul > li {
|
472 |
width: 32%; margin-right: 3%;
|
491 |
#edd-purchased-files.columns-4 li.actions {
|
492 |
width: 25%; margin-top: 0; margin-right: 0;
|
493 |
}
|
494 |
+
|
495 |
}
|
496 |
+
|
497 |
@media screen and ( max-width: 1284px ) {
|
498 |
+
|
499 |
#edd-edit-order-form .column strong {
|
500 |
display:block;
|
501 |
}
|
502 |
+
|
503 |
}
|
504 |
|
505 |
/** Stats */
|
506 |
+
#edd_product_stats .label {
|
507 |
+
display: inline-block;
|
508 |
+
}
|
509 |
+
#edd_product_stats hr {
|
510 |
+
border-style: solid;
|
511 |
+
border-width: 1px;
|
512 |
+
border-color: #ccc #fff #fff #ccc;
|
513 |
+
}
|
514 |
+
#edd_product_stats .product-sales-stats:before,
|
515 |
+
#edd_product_stats .product-earnings-stats:before {
|
516 |
+
color: #82878c;
|
517 |
+
font: normal 20px/1 'dashicons';
|
518 |
+
display: inline-block;
|
519 |
+
padding: 0 2px 0 0;
|
520 |
+
position: relative;
|
521 |
+
top: 0;
|
522 |
+
left: -1px;
|
523 |
+
speak: none;
|
524 |
+
text-decoration: none !important;
|
525 |
+
vertical-align: top;
|
526 |
+
-webkit-font-smoothing: antialiased;
|
527 |
+
-moz-osx-font-smoothing: grayscale;
|
528 |
+
}
|
529 |
+
#edd_product_stats .product-sales-stats:before {
|
530 |
+
content: '\f174';
|
531 |
+
}
|
532 |
+
#edd_product_stats .product-earnings-stats:before {
|
533 |
+
content: '\f239';
|
534 |
+
}
|
535 |
|
536 |
/* Dashboard Widget Styles
|
537 |
-------------------------------------------------------------- */
|
538 |
+
|
539 |
+
.edd_dashboard_widget table thead td{
|
540 |
+
border-bottom: 1px solid #ececec;
|
541 |
+
color: #777;
|
542 |
+
}
|
543 |
+
.edd_dashboard_widget .table_left {
|
544 |
+
float: left;
|
545 |
+
width: 45%;
|
546 |
+
}
|
547 |
+
.edd_dashboard_widget .table_right {
|
548 |
+
float: right;
|
549 |
+
width: 45%;
|
550 |
+
}
|
551 |
+
.edd_dashboard_widget .inside {
|
552 |
+
font-size: 12px;
|
553 |
+
}
|
554 |
+
.edd_dashboard_widget td {
|
555 |
+
padding: 3px 0;
|
556 |
+
}
|
557 |
+
.edd_dashboard_widget .b {
|
558 |
+
font-size: 14px;
|
559 |
+
font-family: Georgia,"Times New Roman","Bitstream Charter",Times,serif;
|
560 |
+
padding-right: 6px;
|
561 |
+
width: auto;
|
562 |
+
}
|
563 |
+
.edd_dashboard_widget .t {
|
564 |
+
font-size: 12px;
|
565 |
+
padding-right: 12px;
|
566 |
+
padding-top: 6px;
|
567 |
+
color: #777;
|
568 |
+
width: 100%;
|
569 |
+
}
|
570 |
+
.edd_dashboard_widget .label_heading {
|
571 |
+
border-top: 1px solid #ececec;
|
572 |
+
color: #8f8f8f;
|
573 |
+
font-family: Helvetica, Arial, sans-serif;
|
574 |
+
font-size: 12px;
|
575 |
+
font-weight: normal;
|
576 |
+
display: block;
|
577 |
+
padding-top: 10px;
|
578 |
+
margin: 0 0 8px 12px;
|
579 |
+
}
|
580 |
+
.edd_dashboard_widget .edd_dashboard_widget_subheading {
|
581 |
+
border-top: 1px solid #ececec;
|
582 |
+
color: #8f8f8f;
|
583 |
+
font-size: 14px;
|
584 |
+
padding-top: 10px;
|
585 |
+
margin: 1em 0 0 0;
|
586 |
+
}
|
587 |
+
.edd_dashboard_widget .edd_dashboard_widget_subheading + .table {
|
588 |
+
margin: 8px 0 0 0;
|
589 |
+
}
|
590 |
+
.edd_dashboard_widget .edd_price_label {
|
591 |
+
background: rgb(0, 118, 156);
|
592 |
+
border-radius: 3px;
|
593 |
+
color: white;
|
594 |
+
font-size: 10px;
|
595 |
+
padding: 2px 4px;
|
596 |
+
margin-right: 2px;
|
597 |
+
}
|
598 |
+
.edd_dashboard_widget table {
|
599 |
+
width: 100%;
|
600 |
+
margin-left: 0;
|
601 |
+
margin-bottom: 1em;
|
602 |
+
}
|
603 |
+
td.edd_order_label {
|
604 |
+
width: 80%;
|
605 |
+
}
|
606 |
+
td.edd_order_price {
|
607 |
+
text-align: right;
|
608 |
+
}
|
609 |
+
|
610 |
@media handheld, only screen and (max-width: 1000px) {
|
611 |
+
|
612 |
+
.edd_dashboard_widget .edd-recent-email {
|
613 |
+
display: none;
|
614 |
+
}
|
615 |
+
|
616 |
}
|
617 |
|
618 |
/* Reports Styles
|
619 |
-------------------------------------------------------------- */
|
620 |
+
|
621 |
+
#edd-dashboard-widgets-wrap .postbox h3 {
|
622 |
+
cursor: default;
|
623 |
+
}
|
624 |
#edd-graphs-date-options,
|
625 |
+
#edd-date-range-options {
|
626 |
+
float: left;
|
627 |
+
}
|
628 |
+
#edd-date-range-options span {
|
629 |
+
float: left;
|
630 |
+
line-height: 24px;
|
631 |
+
height: 24px;
|
632 |
+
margin-right: 6px;
|
633 |
+
}
|
634 |
+
.edd-import-export-form {
|
635 |
+
position: relative;
|
636 |
+
}
|
637 |
+
.edd-import-export-form .edd-progress {
|
638 |
+
background: #ddd;
|
639 |
+
position: absolute;
|
640 |
+
bottom: 15px;
|
641 |
+
width: 95%;
|
642 |
+
height: 15px;
|
643 |
+
}
|
644 |
+
.edd-import-export-form .edd-progress div {
|
645 |
+
background: #ccc;
|
646 |
+
height: 100%;
|
647 |
+
width: 0;
|
648 |
+
}
|
649 |
+
.edd-import-export-form .notice-wrap {
|
650 |
+
background-color: #f4f4f4;
|
651 |
+
border-style: solid;
|
652 |
+
border-width: 1px 0;
|
653 |
+
border-color: #eae9e9;
|
654 |
+
padding: 12px 12px 4px;
|
655 |
+
overflow: auto;
|
656 |
+
margin: 20px -12px -23px;
|
657 |
+
}
|
658 |
+
.edd-import-export-form .notice-wrap .spinner {
|
659 |
+
margin: 4px 10px 8px;
|
660 |
+
}
|
661 |
+
.admin-color-fresh .edd-import-export-form .edd-progress div {
|
662 |
+
background: #0073aa;
|
663 |
+
}
|
664 |
+
.admin-color-light .edd-import-export-form .edd-progress div {
|
665 |
+
background: #888;
|
666 |
+
}
|
667 |
+
.admin-color-blue .edd-import-export-form .edd-progress div {
|
668 |
+
background: #096484;
|
669 |
+
}
|
670 |
+
.admin-color-coffee .edd-import-export-form .edd-progress div {
|
671 |
+
background: #c7a589;
|
672 |
+
}
|
673 |
+
.admin-color-ectoplasm .edd-import-export-form .edd-progress div {
|
674 |
+
background: #a3b745;
|
675 |
+
}
|
676 |
+
.admin-color-midnight .edd-import-export-form .edd-progress div {
|
677 |
+
background: #e14d43;
|
678 |
+
}
|
679 |
+
.admin-color-sunrise .edd-import-export-form .edd-progress div {
|
680 |
+
background: #dd823b;
|
681 |
+
}
|
682 |
+
#edd-graphs-filter label {
|
683 |
+
vertical-align: inherit;
|
684 |
+
}
|
685 |
+
#edd-graphs-filter .graph-option-section {
|
686 |
+
float: left;
|
687 |
+
line-height: 2.5em;
|
688 |
+
padding-right: 5px;
|
689 |
+
}
|
690 |
+
.edd-mix-totals {
|
691 |
+
background-color: #fff;
|
692 |
+
border: 1px solid #e5e5e5;
|
693 |
+
box-shadow: 0 1px 1px rgba(0,0,0,0.04);
|
694 |
+
padding: 10px;
|
695 |
+
}
|
696 |
+
.edd-mix-chart {
|
697 |
+
display: inline-block;
|
698 |
+
width: 49%;
|
699 |
+
vertical-align: top;
|
700 |
+
}
|
701 |
+
.edd-graph-notes {
|
702 |
+
color: #9c9c9c;
|
703 |
+
}
|
704 |
+
.edd-graph-notes span {
|
705 |
+
display: block;
|
706 |
+
}
|
707 |
+
.edd-pie-graph .legend {
|
708 |
+
display: none;
|
709 |
+
}
|
710 |
+
.edd-pie-legend {
|
711 |
+
overflow: auto;
|
712 |
+
margin-top: 10px;
|
713 |
+
}
|
714 |
+
.edd-legend-item-wrapper {
|
715 |
+
color: #333;
|
716 |
+
display: inline-block;
|
717 |
+
font-size: 8pt;
|
718 |
+
padding: 2px 5px 0px 5px;
|
719 |
+
width: 48%;
|
720 |
+
height: 20px;
|
721 |
+
}
|
722 |
+
.edd-legend-color {
|
723 |
+
border: 1px solid #cfcfcf;
|
724 |
+
display: inline-block;
|
725 |
+
margin-right: 5px;
|
726 |
+
width: 20px;
|
727 |
+
height: 15px;
|
728 |
+
}
|
729 |
+
.edd-pie-legend-item {
|
730 |
+
display: inline-block;
|
731 |
+
vertical-align: top;
|
732 |
+
width: 80%;
|
733 |
+
}
|
734 |
|
735 |
/* Upgrades page styles
|
736 |
-------------------------------------------------------------- */
|
737 |
|
738 |
/* Settings page styles
|
739 |
-------------------------------------------------------------- */
|
740 |
+
|
741 |
+
#edd_tax_rates {
|
742 |
+
margin: 1em 0 0;
|
743 |
+
}
|
744 |
#edd_tax_rates .edd_tax_country *,
|
745 |
+
#edd_tax_rates .edd_tax_state * {
|
746 |
+
max-width: 100%;
|
747 |
+
}
|
748 |
#edd_tax_rates .edd_tax_country,
|
749 |
+
#edd_tax_rates .edd_tax_state {
|
750 |
+
width: 180px;
|
751 |
+
}
|
752 |
+
#edd_tax_rates .edd_tax_rate {
|
753 |
+
width: 80px;
|
754 |
+
}
|
755 |
+
#edd_tax_rates th {
|
756 |
+
padding: 15px 10px;
|
757 |
+
}
|
758 |
+
.wrap-licenses .form-table,
|
759 |
+
.wrap-licenses thead,
|
760 |
+
.wrap-licenses tbody,
|
761 |
+
.wrap-licenses tfoot,
|
762 |
+
.wrap-licenses tr,
|
763 |
+
.wrap-licenses td,
|
764 |
+
.wrap-licenses th,
|
765 |
+
.wrap-licenses caption {
|
766 |
+
display: block;
|
767 |
+
}
|
768 |
+
.wrap-licenses .form-table tr {
|
769 |
+
float: left;
|
770 |
+
margin: 0 15px 15px 0;
|
771 |
+
background: #fff;
|
772 |
+
border: 1px solid #ccc;
|
773 |
+
width: 30.5%;
|
774 |
+
max-width: 350px;
|
775 |
+
padding: 14px;
|
776 |
+
min-height: 220px;
|
777 |
+
position: relative;
|
778 |
+
box-sizing: border-box;
|
779 |
+
}
|
780 |
+
.wrap-licenses .form-table th {
|
781 |
+
background: #f9f9f9;
|
782 |
+
padding: 14px;
|
783 |
+
border-bottom: 1px solid #ccc;
|
784 |
+
margin: -14px -14px 20px;
|
785 |
+
width: 100%;
|
786 |
+
}
|
787 |
+
.wrap-licenses .form-table td {
|
788 |
+
padding: 0;
|
789 |
+
}
|
790 |
+
.wrap-licenses td input.regular-text {
|
791 |
+
margin: 0 0 8px;
|
792 |
+
width: 100%;
|
793 |
+
}
|
794 |
+
.wrap-licenses .edd-license-data[class*="edd-license-"] {
|
795 |
+
position: absolute;
|
796 |
+
background: #fafafa;
|
797 |
+
padding: 14px;
|
798 |
+
border-top: 1px solid #eee;
|
799 |
+
margin: 20px -14px -14px;
|
800 |
+
min-height: 67px;
|
801 |
+
width: 100%;
|
802 |
+
bottom: 14px;
|
803 |
+
box-sizing: border-box;
|
804 |
+
}
|
805 |
+
.wrap-licenses .edd-license-data[class*="edd-license-"] a {
|
806 |
+
color: #444;
|
807 |
+
}
|
808 |
+
.wrap-licenses .edd-license-data[class*="edd-license-"] a:hover {
|
809 |
+
text-decoration: none;
|
810 |
+
}
|
811 |
+
.wrap-licenses .edd-license-data.license-expires-soon-notice {
|
812 |
+
background-color: #00a0d2;
|
813 |
+
color: #fff;
|
814 |
+
border-color: #00a0d2;
|
815 |
+
}
|
816 |
+
.wrap-licenses .edd-license-data.edd-license-expired {
|
817 |
+
background-color: #e24e4e;
|
818 |
+
color: #fff;
|
819 |
+
border-color: #e24e4e;
|
820 |
+
}
|
821 |
+
.wrap-licenses .edd-license-data.edd-license-error,
|
822 |
+
.wrap-licenses .edd-license-data.edd-license-missing,
|
823 |
+
.wrap-licenses .edd-license-data.edd-license-invalid,
|
824 |
+
.wrap-licenses .edd-license-data.edd-license-site_inactive,
|
825 |
+
.wrap-licenses .edd-license-data.edd-license-item_name_mismatch {
|
826 |
+
background-color: #ffebcd;
|
827 |
+
border-color: #ffebcd;
|
828 |
+
}
|
829 |
+
.wrap-licenses .edd-license-data p {
|
830 |
+
font-size: 13px;
|
831 |
+
margin-top: 0;
|
832 |
+
}
|
833 |
+
.wrap-licenses .edd-license-data.license-expires-soon-notice a,
|
834 |
+
.wrap-licenses .edd-license-data.edd-license-expired a {
|
835 |
+
color: #fff;
|
836 |
+
}
|
837 |
+
.wrap-licenses .edd-license-data.license-expires-soon-notice a:hover,
|
838 |
+
.wrap-licenses .edd-license-data.edd-license-expired a:hover {
|
839 |
+
text-decoration: none;
|
840 |
+
}
|
841 |
+
.wrap-licenses p.submit {
|
842 |
+
clear: both;
|
843 |
+
}
|
844 |
|
845 |
/* Taxonomy styles
|
846 |
-------------------------------------------------------------- */
|
847 |
+
|
848 |
+
.post-type-download .fixed .column-name {
|
849 |
+
width: 27%;
|
850 |
+
}
|
851 |
+
.post-type-download .fixed .column-description {
|
852 |
+
width: 30%;
|
853 |
+
}
|
854 |
+
.post-type-download .fixed .column-slug {
|
855 |
+
width: 23%;
|
856 |
+
}
|
857 |
+
.post-type-download .fixed .column-posts {
|
858 |
+
text-align: left;
|
859 |
+
width: 17%;
|
860 |
+
}
|
861 |
|
862 |
/* System Info page styles
|
863 |
-------------------------------------------------------------- */
|
864 |
+
|
865 |
+
#system-info-textarea {
|
866 |
+
background: none;
|
867 |
+
font-family: Menlo, Monaco, monospace;
|
868 |
+
display: block;
|
869 |
+
overflow: auto;
|
870 |
+
white-space: pre;
|
871 |
+
width: 800px;
|
872 |
+
height: 400px;
|
873 |
+
}
|
874 |
|
875 |
/* Button styles
|
876 |
-------------------------------------------------------------- */
|
877 |
+
|
878 |
+
#TB_window #edd-add-download:hover,
|
879 |
+
#TB_window #edd-add-download:active,
|
880 |
+
#TB_window #edd-add-download:focus {
|
881 |
+
color: #fff;
|
882 |
+
}
|
883 |
|
884 |
/* Global Graph Styles
|
885 |
-------------------------------------------------------------- */
|
886 |
+
|
887 |
+
.edd-graph .y1Axis {
|
888 |
+
color: rgb( 237, 194, 64 )!important;
|
889 |
+
}
|
890 |
+
.edd-graph .y2Axis {
|
891 |
+
color: rgb( 175, 216, 248 )!important;
|
892 |
+
}
|
893 |
|
894 |
/* API Table Styles
|
895 |
-------------------------------------------------------------- */
|
896 |
+
|
897 |
+
.download_page_edd-tools .apikeys .column-user {
|
898 |
+
width: 192px;
|
899 |
+
}
|
900 |
|
901 |
/* General styles
|
902 |
-------------------------------------------------------------- */
|
903 |
+
|
904 |
+
.edd-select-chosen {
|
905 |
+
width: 300px;
|
906 |
+
}
|
907 |
+
.chosen-container-multi .chosen-choices {
|
908 |
+
background-image: none;
|
909 |
+
border-color: #dfdfdf;
|
910 |
+
-webkit-border-radius: 3px;
|
911 |
+
border-radius: 3px;
|
912 |
+
}
|
913 |
+
.chosen-container-multi .chosen-choices input {
|
914 |
+
border-color: #dfdfdf;
|
915 |
+
height:27px!important;
|
916 |
+
margin:2px;
|
917 |
+
}
|
918 |
+
.chosen-container .chosen-drop {
|
919 |
+
border-color: #aaa;
|
920 |
+
-webkit-box-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
|
921 |
+
box-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
|
922 |
+
}
|
923 |
+
.chosen-container .search-field {
|
924 |
+
float: none!important;
|
925 |
+
}
|
926 |
+
.chosen-container .search-field input {
|
927 |
+
width: 90%!important;
|
928 |
+
}
|
929 |
+
.chosen-container-active .chosen-choices {
|
930 |
+
border-color: #aaa;
|
931 |
+
-webkit-border-top-left-radius: 3px;
|
932 |
+
border-top-left-radius: 3px;
|
933 |
+
-webkit-border-top-right-radius: 3px;
|
934 |
+
border-top-right-radius: 3px;
|
935 |
+
-webkit-border-bottom-left-radius: 0;
|
936 |
+
border-bottom-left-radius: 0;
|
937 |
+
border-bottom-right-radius: 0;
|
938 |
+
-webkit-box-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
|
939 |
+
box-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
|
940 |
+
}
|
941 |
+
|
942 |
+
.download_page_edd-tools .tablenav .actions {
|
943 |
+
overflow: visible;
|
944 |
+
}
|
945 |
+
.edd_user_search_wrap {
|
946 |
+
position: relative;
|
947 |
+
overflow: visible;
|
948 |
+
}
|
949 |
+
.edd_user_search_results {
|
950 |
+
position: absolute;
|
951 |
+
left: 0;
|
952 |
+
top: 27px;
|
953 |
+
}
|
954 |
+
.edd_user_search_results a.edd-ajax-user-cancel {
|
955 |
+
position: absolute;
|
956 |
+
right: 6px;
|
957 |
+
top: 2px;
|
958 |
+
}
|
959 |
+
.edd_user_search_results ul {
|
960 |
+
background: #f0f0f0;
|
961 |
+
border: 1px solid #dfdfdf;
|
962 |
+
overflow-y: scroll;
|
963 |
+
padding: 10px 10px 4px;
|
964 |
+
margin: 0;
|
965 |
+
max-height: 200px;
|
966 |
+
width: 300px;
|
967 |
+
}
|
968 |
+
|
969 |
+
.wp-list-table .type-download .row-actions {
|
970 |
+
color: #999;
|
971 |
+
}
|
972 |
|
973 |
@media screen and ( max-width: 1100px ) {
|
974 |
+
|
975 |
.edd-mix-chart {
|
976 |
display: block;
|
977 |
width: 100%;
|
978 |
}
|
979 |
+
|
980 |
+
.wrap-licenses .form-table tr {
|
981 |
+
width: 46%;
|
982 |
+
max-width: none;
|
983 |
+
min-height: 230px;
|
984 |
+
}
|
985 |
+
|
986 |
}
|
987 |
|
988 |
@media screen and ( max-width: 782px ) {
|
989 |
+
|
990 |
.post-type-download .nav-tab-wrapper a {
|
|
|
991 |
font-size: 50%;
|
992 |
+
padding: 2px 4px;
|
993 |
}
|
994 |
.download_page_edd-tools .apikeys .column-user {
|
995 |
width: 80px;
|
1002 |
[class^="license-"] input[type="text"] {
|
1003 |
margin-bottom: 3px;
|
1004 |
}
|
1005 |
+
|
1006 |
+
}
|
1007 |
+
|
1008 |
+
@media screen and ( max-width: 600px ) {
|
1009 |
+
.wrap-licenses .form-table tr {
|
1010 |
+
width: 100%;
|
1011 |
+
min-height: 230px;
|
1012 |
+
}
|
1013 |
}
|
1014 |
|
1015 |
/* Customer Styles
|
1016 |
-------------------------------------------------------------- */
|
1017 |
+
|
1018 |
+
#edd-item-tab-wrapper {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1019 |
display: inline-block;
|
1020 |
margin-left: -1px;
|
1021 |
+
text-align: center;
|
1022 |
+
z-index: 1;
|
1023 |
+
}
|
1024 |
+
#edd-item-tab-wrapper-list li {
|
1025 |
+
background-color: #fff;
|
1026 |
+
width: 32px;
|
1027 |
+
height: 32px;
|
1028 |
+
}
|
1029 |
+
#edd-item-tab-wrapper-list .inactive {
|
1030 |
+
background-color: #fff;
|
1031 |
+
border-left: 1px solid #e5e5e5;
|
1032 |
+
color: #eee;
|
1033 |
+
}
|
1034 |
+
#edd-item-tab-wrapper-list .inactive a,
|
1035 |
+
#edd-item-tab-wrapper-list .inactive a:visited {
|
1036 |
+
color: #eee;
|
1037 |
+
display: block;
|
1038 |
+
line-height: 32px;
|
1039 |
+
text-decoration: none;
|
1040 |
+
}
|
1041 |
+
#edd-item-tab-wrapper-list .inactive a:hover,
|
1042 |
+
#edd-item-tab-wrapper-list .inactive a:focus,
|
1043 |
+
#edd-item-tab-wrapper-list .inactive a:active {
|
1044 |
+
color: #444;
|
1045 |
+
}
|
1046 |
+
#edd-item-tab-wrapper-list .active {
|
1047 |
+
border-color: #e5e5e5;
|
1048 |
+
border-style: solid;
|
1049 |
+
border-width: 1px 1px 1px 0;
|
1050 |
+
}
|
1051 |
+
#edd-item-tab-wrapper-list :not(:last-child) {
|
1052 |
+
margin-bottom: 3px;
|
1053 |
+
}
|
1054 |
+
#edd-item-tab-wrapper-list .dashicons {
|
1055 |
+
font-size: 24px; line-height: 32px;
|
1056 |
+
}
|
1057 |
+
#edd-item-card-wrapper .left {
|
1058 |
+
float: left;
|
1059 |
+
}
|
1060 |
+
#edd-item-card-wrapper .right {
|
1061 |
+
float: right;
|
1062 |
+
}
|
1063 |
+
#edd-item-card-wrapper input {
|
1064 |
+
font-weight: normal;
|
1065 |
+
}
|
1066 |
+
#edd-item-card-wrapper {
|
1067 |
+
background-color: #fff;
|
1068 |
border: 1px solid #e5e5e5;
|
1069 |
webkit-box-shadow: 0 1px 1px rgba(0,0,0,0.04);
|
1070 |
box-shadow: 0 1px 1px rgba(0,0,0,0.04);
|
1071 |
+
display: inline-block;
|
1072 |
+
margin-left: -1px;
|
1073 |
+
min-height: 200px;
|
1074 |
+
width: 700px;
|
1075 |
+
z-index: 2;
|
1076 |
+
}
|
1077 |
+
#edd-item-card-wrapper .customer-section {
|
1078 |
+
border-bottom: 1px solid #eee;
|
1079 |
+
margin-bottom: 10px;
|
1080 |
+
overflow: auto;
|
1081 |
+
}
|
1082 |
+
#edd-item-card-wrapper .customer-section table {
|
1083 |
+
margin-bottom: 20px;
|
1084 |
+
}
|
1085 |
+
#edd-item-card-wrapper > div {
|
1086 |
+
padding: 0px 20px;
|
1087 |
+
}
|
1088 |
+
#edd-item-card-wrapper > div:first-child {
|
1089 |
+
padding-top: 20px;
|
1090 |
+
}
|
1091 |
+
#edd-item-card-wrapper > div:last-child {
|
1092 |
+
border: none;
|
1093 |
+
padding-bottom: 20px;
|
1094 |
+
}
|
1095 |
+
#edd-item-card-wrapper .avatar-wrap {
|
1096 |
+
padding-right: 10px;
|
1097 |
+
text-align: center;
|
1098 |
+
}
|
1099 |
+
#edd-item-card-wrapper .customer-id {
|
1100 |
+
font-size: 24px;
|
1101 |
+
font-weight: 600;
|
1102 |
+
}
|
1103 |
+
#edd-item-card-wrapper .customer-main-wrapper input {
|
1104 |
+
width: 200px;
|
1105 |
+
}
|
1106 |
+
#edd-item-card-wrapper .customer-address-wrapper {
|
1107 |
+
margin-right: 25px;
|
1108 |
+
max-width: 33%;
|
1109 |
+
width: 202px;
|
1110 |
+
}
|
1111 |
+
#edd-item-card-wrapper .customer-address-wrapper select {
|
1112 |
+
width: 200px;
|
1113 |
+
}
|
1114 |
+
#edd-item-card-wrapper .customer-info {
|
1115 |
+
margin-top: 5px;
|
1116 |
+
margin-bottom: 10px;
|
1117 |
+
min-height: 185px;
|
1118 |
+
}
|
1119 |
+
#edd-item-card-wrapper .info-wrapper {
|
1120 |
+
min-height: 125px;
|
1121 |
+
overflow: visible;
|
1122 |
+
}
|
1123 |
+
#edd-item-card-wrapper a.delete {
|
1124 |
+
color: #ff0000;
|
1125 |
+
margin-right: 5px;
|
1126 |
+
text-decoration: none;
|
1127 |
+
}
|
1128 |
+
.customer-info .customer-name {
|
1129 |
+
font-size: 24px;
|
1130 |
+
font-weight: 600;
|
1131 |
+
}
|
1132 |
+
.customer-edit-link a,
|
1133 |
+
.disconnect-user a {
|
1134 |
+
font-size: 12px;
|
1135 |
+
font-weight: normal;
|
1136 |
+
text-decoration: none;
|
1137 |
+
}
|
1138 |
+
#customer-edit-actions {
|
1139 |
+
line-height: 28px;
|
1140 |
+
margin-bottom: 20px;
|
1141 |
+
text-align: center;
|
1142 |
+
}
|
1143 |
+
#customer-edit-actions .button-secondary {
|
1144 |
+
margin-right: 10px;
|
1145 |
+
}
|
1146 |
+
#edd-item-card-wrapper .info-item {
|
1147 |
+
display: block;
|
1148 |
+
line-height: 16px;
|
1149 |
+
padding-bottom: 5px;
|
1150 |
+
}
|
1151 |
+
#edd-item-card-wrapper .edit-item {
|
1152 |
+
display: none;
|
1153 |
+
}
|
1154 |
+
#edd-item-card-wrapper .edd_user_search_results {
|
1155 |
+
left: 1px;
|
1156 |
+
top: 16px;
|
1157 |
+
}
|
1158 |
+
#edd-item-card-wrapper .edd_user_search_results ul {
|
1159 |
+
width: 200px;
|
1160 |
+
}
|
1161 |
+
#edd-item-stats-wrapper {
|
1162 |
+
margin: 0 auto;
|
1163 |
+
min-height: 30px;
|
1164 |
+
text-align: center;
|
1165 |
+
}
|
1166 |
+
#edd-item-stats-wrapper li {
|
1167 |
+
font-size: 14px;
|
1168 |
+
float: left;
|
1169 |
+
line-height: 22px;
|
1170 |
+
width: 50%;
|
1171 |
+
}
|
1172 |
+
#edd-item-stats-wrapper a {
|
1173 |
+
text-decoration: none;
|
1174 |
+
}
|
1175 |
+
#edd-item-stats-wrapper .dashicons {
|
1176 |
+
color: #888;
|
1177 |
+
}
|
1178 |
+
#edd-item-tables-wrapper table {
|
1179 |
+
text-align: center;
|
1180 |
+
width: 100%;
|
1181 |
+
}
|
1182 |
+
#edd-item-tables-wrapper th {
|
1183 |
+
text-align: center;
|
1184 |
+
}
|
1185 |
+
#edd-item-tables-wrapper .downloads tr > th:first-child,
|
1186 |
+
#edd-item-tables-wrapper .downloads tr > td:first-child,
|
1187 |
+
#edd-item-tables-wrapper .emails tr > th:first-child,
|
1188 |
+
#edd-item-tables-wrapper .emails tr > td:first-child {
|
1189 |
+
text-align: left;
|
1190 |
+
}
|
1191 |
+
#edd-item-tables-wrapper .downloads tr > td:only-child {
|
1192 |
+
text-align: center;
|
1193 |
+
}
|
1194 |
+
#edd-item-tables-wrapper .emails .add-customer-email-row td {
|
1195 |
+
background-color: #f9f9f9;
|
1196 |
+
border-top: 1px solid #e5e5e5;
|
1197 |
+
}
|
1198 |
+
#edd-item-tables-wrapper .emails .primary-email-icon {
|
1199 |
+
font-size: 13px;
|
1200 |
+
vertical-align: middle;
|
1201 |
+
line-height: 1.5em;
|
1202 |
+
}
|
1203 |
+
#edd-item-tables-wrapper .emails input {
|
1204 |
+
vertical-align: middle;
|
1205 |
+
margin: 6px 0;
|
1206 |
+
}
|
1207 |
+
#edd-item-tables-wrapper .emails .spinner {
|
1208 |
+
float: none;
|
1209 |
+
}
|
1210 |
+
#edd-item-notes-wrapper {
|
1211 |
+
min-height: 50px;
|
1212 |
+
}
|
1213 |
+
.edd-item-notes-header span,
|
1214 |
+
.edd-item-notes-header img {
|
1215 |
+
font-weight: 600;
|
1216 |
+
line-height: 30px;
|
1217 |
+
vertical-align: middle;
|
1218 |
+
}
|
1219 |
+
.customer-note-input {
|
1220 |
+
margin-bottom: 5px;
|
1221 |
+
width: 100%;
|
1222 |
+
}
|
1223 |
+
#edd-customer-notes div:nth-of-type(even) {
|
1224 |
+
background-color: #fcfcfc;
|
1225 |
+
}
|
1226 |
+
.customer-note-wrapper {
|
1227 |
+
border-bottom: 1px solid #f9f9f9;
|
1228 |
+
min-height: 38px;
|
1229 |
+
padding: 7px 0 7px 7px;
|
1230 |
+
}
|
1231 |
+
.customer-note-wrapper span {
|
1232 |
+
display: block;
|
1233 |
+
}
|
1234 |
+
.note-content-wrap {
|
1235 |
+
padding-top: 7px;
|
1236 |
+
}
|
1237 |
+
.delete-customer {
|
1238 |
+
text-align: center;
|
1239 |
+
}
|
1240 |
+
#edd-item-card-wrapper .notice-wrap {
|
1241 |
+
padding-left: 20px;
|
1242 |
+
padding-right: 20px;
|
1243 |
+
margin-left: -20px;
|
1244 |
+
margin-right: -20px;
|
1245 |
+
}
|
1246 |
+
|
1247 |
+
@media screen and ( max-width: 810px ) and ( min-width: 656px ) {
|
1248 |
+
#edd-item-card-wrapper {
|
1249 |
+
width: 600px;
|
1250 |
+
}
|
1251 |
+
.customer-info .customer-name {
|
1252 |
+
font-size: 16px;
|
1253 |
+
}
|
1254 |
+
#edd-item-card-wrapper .widefat td, .widefat th {
|
1255 |
+
padding: 4px 6px;
|
1256 |
+
max-width: 100px!important;
|
1257 |
+
display: table-cell;
|
1258 |
+
}
|
1259 |
+
}
|
1260 |
+
@media screen and ( max-width: 656px ) {
|
1261 |
+
#edd-item-card-wrapper {
|
1262 |
+
margin: 0;
|
1263 |
+
width: 100%;
|
1264 |
+
}
|
1265 |
+
#edd-item-card-wrapper > div:first-child {
|
1266 |
+
height: 230px;
|
1267 |
+
}
|
1268 |
+
#edd-item-tab-wrapper {
|
1269 |
+
margin: 0 0 -5px;
|
1270 |
+
}
|
1271 |
+
#edd-item-tab-wrapper-list {
|
1272 |
+
height: 32px;
|
1273 |
+
margin: 0;
|
1274 |
+
}
|
1275 |
+
#edd-item-tab-wrapper-list .inactive {
|
1276 |
+
border-bottom: 1px solid #e5e5e5;
|
1277 |
+
border-left: none;
|
1278 |
+
}
|
1279 |
+
#edd-item-tab-wrapper-list .active {
|
1280 |
+
border-width: 1px 1px 0 1px;
|
1281 |
+
}
|
1282 |
+
#edd-item-tab-wrapper-list li {
|
1283 |
+
float: left;
|
1284 |
+
margin: 0 0 0 5px !important;
|
1285 |
+
width: 32px;
|
1286 |
+
height: 32px;
|
1287 |
+
}
|
1288 |
+
#edd-item-tab-wrapper-list li span {
|
1289 |
+
width: 32px;
|
1290 |
+
height: 32px;
|
1291 |
+
margin: 0 !important;
|
1292 |
+
}
|
1293 |
+
#edd-item-card-wrapper .customer-info {
|
1294 |
+
min-height: 210px;
|
1295 |
+
}
|
1296 |
+
.edd-item-info.customer-info {
|
1297 |
+
position: relative;
|
1298 |
+
}
|
1299 |
+
#edd-item-card-wrapper .customer-address-wrapper {
|
1300 |
+
float: none;
|
1301 |
+
position: absolute;
|
1302 |
+
top: 84px;
|
1303 |
+
left: 110px;
|
1304 |
+
max-width: 200px;
|
1305 |
+
}
|
1306 |
+
#edd-item-card-wrapper .customer-main-wrapper {
|
1307 |
+
float: none;
|
1308 |
+
position: absolute;
|
1309 |
+
left: 110px;
|
1310 |
+
}
|
1311 |
+
.customer-info .customer-name {
|
1312 |
+
font-size: 16px;
|
1313 |
+
}
|
1314 |
+
#edd-item-card-wrapper #edd-item-stats-wrapper {
|
1315 |
+
padding-left: 0;
|
1316 |
+
padding-right: 0;
|
1317 |
+
}
|
1318 |
+
#edd-item-card-wrapper .customer-section {
|
1319 |
+
margin-bottom: 0;
|
1320 |
+
}
|
1321 |
+
#edd-item-card-wrapper .widefat td, .widefat th {
|
1322 |
+
padding: 4px 6px;
|
1323 |
+
max-width: 100px!important;
|
1324 |
+
display: table-cell;
|
1325 |
+
overflow: hidden;
|
1326 |
+
}
|
1327 |
+
#edd-item-card-wrapper .customer-id {
|
1328 |
+
font-size: 16px;
|
1329 |
+
}
|
1330 |
+
#edd-item-card-wrapper > div:first-child {
|
1331 |
+
height: auto;
|
1332 |
+
}
|
1333 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1334 |
|
1335 |
/* Tools Styles
|
1336 |
-------------------------------------------------------------- */
|
1337 |
+
|
1338 |
+
.recount-stats-controls form {
|
1339 |
+
display: inline;
|
1340 |
+
}
|
1341 |
+
.edd-recount-stats-descriptions span {
|
1342 |
+
display: none;
|
1343 |
+
line-height: 24px;
|
1344 |
+
}
|
assets/css/edd-admin.min.css
CHANGED
@@ -1 +1 @@
|
|
1 |
-
.edd-admin-box .label,.edd-admin-box-inside .strong{font-weight:600}.edd-mobile-link,.edd_repeatable_row td{vertical-align:middle}.edd-hidden{display:none}.edd-clearfix:after{display:block;visibility:hidden;content:".";text-indent:-9999px;height:0}.edd-wrap a{text-decoration:none}a.edd-delete{color:#a00}a.edd-delete:hover{color:red}.download_page_edd-settings .form-table label{color:#666;font-size:14px;font-style:italic;margin:4px 0 0}.download_page_edd-settings .form-table input.regular-text~label,.download_page_edd-settings .form-table select+label{display:block}.download_page_edd-settings .form-table input.small-text~label,.download_page_edd-settings .form-table input[type=checkbox]+label{display:inline}.download_page_edd-settings .form-table tr>th>h3,.download_page_edd-settings .form-table tr>th>strong{font-size:1.2em;font-weight:600;margin:0 auto}.edd-tab-span{float:right;bottom:13px;position:relative}.edd-add-ons-footer{padding-top:10px}#edd-add-ons h2{margin:0 0 15px}#edd-add-ons h2 .button-primary{position:absolute}#edd-add-ons .edd-extension{float:left;margin:0 15px 15px 0;background:#fff;border:1px solid #ccc;width:320px;padding:14px;height:315px;position:relative}#edd-add-ons .edd-extension h3{margin:0 0 8px;font-size:13px}#edd-add-ons .edd-extension .button-secondary{position:absolute;bottom:14px;left:14px}#edd-add-ons .edd-browse-all{clear:both;width:100%}#edd-add-ons .edd-extension .third-party{display:none}#edd-add-ons .edd-starter-package{border-color:#62a9d7;background-color:#85c0e5;color:#fff}#edd-add-ons .edd-starter-package h3{color:#fff}#edd-add-ons .edd-extension .wp-post-image{width:100%;height:auto}#edd-products{height:100px;min-width:200px}#edd-add-discount input[type=checkbox],#edd-edit-discount input[type=checkbox]{width:15px}#edd-payment-filters{clear:both;background:#f5f5f5;background-image:-webkit-gradient(linear,left bottom,left top,from(#f5f5f5),to(#fafafa));background-image:-webkit-linear-gradient(bottom,#f5f5f5,#fafafa);background-image:-moz-linear-gradient(bottom,#f5f5f5,#fafafa);background-image:-o-linear-gradient(bottom,#f5f5f5,#fafafa);background-image:linear-gradient(to top,#f5f5f5,#fafafa);border-color:#dfdfdf;overflow:auto;margin:8px 0;padding:12px;border-width:1px;border-style:solid;border-radius:3px;font-size:13px;line-height:2.1em}#edd-payments-filter ul.subsubsub{margin-bottom:8px}#edd-payment-filters p{color:#777}tr.status-refunded td{background:#cecece;border-top-color:#ccc}.wp-list-table.downloads th#ID{width:80px}.wp-list-table.downloads th#details{width:130px}.wp-list-table.downloads th#date{width:140px}.wp-list-table.downloads th#user{width:130px}.edd-mobile-link{line-height:32px}.edd-mobile-link img{max-width:80%;height:auto;float:left}@media handheld,only screen and (max-width:640px){.wp-list-table.downloads th{width:auto!important}}.download_page_edd-payment-history .ui-dialog .ui-dialog-titlebar-close span{margin-left:-8px;margin-top:-8px}#edd-download-link-textarea{width:100%}.edd_files_name_label{width:225px;float:left}.edd_files_url_label{width:220px;float:left}#postbox-container-1 .edd_files_name_label,#postbox-container-1 .edd_files_url_label{width:80px}.edd_add_repeatable{display:inline-block}#downloadinformation .edd_meta_table_wrap table input,#downloadinformation .edd_meta_table_wrap table select,#downloadinformation .edd_meta_table_wrap table textarea{margin:4px 0;width:100%}#downloadinformation .edd_meta_table_wrap table .submit input{width:auto}.edd_repeatable_upload_wrapper .edd_repeatable_upload_field_container{position:relative}.edd_upload_file{position:absolute;top:3px;right:7px;padding:2px 8px;display:block;background:#fff}.edd_upload_field{padding-right:8em}.edd_remove_repeatable{margin:8px 0 0;cursor:pointer;width:10px;height:10px;display:inline-block;text-indent:-9999px;overflow:hidden}.edd_remove_repeatable:active,.edd_remove_repeatable:hover{background-position:-10px 0!important}.edd_draghandle{display:block;width:20px;height:20px;background:url(../images/edd-cross-hair.png);cursor:move;margin:4px 0 0}textarea#edd-payment-note{width:100%;height:4em;margin:0}.edd_repeatable_product_wrapper .edd-select,.edd_repeatable_upload_wrapper .pricing select{min-width:100%}#edd_product_notes_field{width:98%;margin:0;height:4em}.edd_repeatable_default_wrapper{text-align:center;width:25px}#edd-purchased-files ul li.remove,td.edd_order_price{text-align:right}.edd-admin-box-inside{margin:0;padding:3px 12px;clear:both;border-bottom:1px solid #eee;word-break:break-word}.rtl .edd-admin-box-inside{padding:5px 10px 5px 0}.edd-payment-fees .fee-label{font-weight:400;color:#666}.edd-admin-box .right{float:right}.rtl .edd-admin-box .right{float:left;margin-left:10px}#edd-customer-details .actions,#edd-order-recalc-total{float:right}#edd-order-details .inside,#edd-order-update .inside{margin:0;padding:0}#edd-order-update input.edd_datepicker{width:180px}#edd-order-update input[type=number].edd-payment-time-hour,#edd-order-update input[type=number].edd-payment-time-min{width:50px}#edd-order-resend-receipt .inside{margin-top:11px}.edd-admin-box-inside:last-child{border-bottom:0}#edd-edit-order-form .data-payment-key{word-break:break-all}.edd-order-update-box #major-publishing-actions .button-secondary{margin-right:10px}#edd-purchased-files .edd-select-chosen{width:196px}#edd-customer-details .order-data-address input,#edd-customer-details .order-data-column p.data input,#edd-edit-order-form .column input,#edd-order-address-country-wrap select,#edd-purchased-files ul{clear:both;display:block}.edd-order-data input.small-text{margin:0}.edd-order-data input.med-text{margin:0;width:100px}#edd-order-update span.label{display:inline;width:50px}.edd-order-update-box .button-primary{margin-right:0}#edd-edit-order-form .column .description{padding-right:10px}#edd-edit-order-form .column,#edd-purchased-files .inside>ul>li,#edd-purchased-files .row>ul>li{display:inline-block;position:relative;vertical-align:middle;margin-right:5%;line-height:30px}#edd-purchased-files li.actions{text-align:right;min-width:200px}#edd-purchased-files .row{padding:12px;border-bottom:1px solid #eee}#edd-purchased-files ul{font-size:0}#edd-purchased-files ul li{font-size:13px}#edd-order-data .data span{color:#666;font-weight:600}#edd-purchased-files .inside{padding:12px}.edd-price-field{width:80px}#edd_products .edd-select,.edd_repeatable_product_wrapper .edd-select,.edd_repeatable_upload_wrapper .pricing select{min-width:100%;max-width:200px}.edd_repeatable_product_wrapper td{overflow:visible}@media screen and (max-width:782px){.order-data-column input[type=email]{padding:6px 10px}}@media screen and (min-width:851px){#edd-purchased-files .inside li.actions{text-align:right}}@media screen and (max-width:1024px){#edd-edit-order-form .column{width:49%}}@media screen and (max-width:1280px) and (min-width:1279px){#edd-purchased-files .inside li.actions{width:35%}#edd-edit-order-form .column{width:32%}}@media screen and (min-width:1280px){#edd-edit-order-form .column,#edd-purchased-files.columns-3 .inside>ul>li,#edd-purchased-files.columns-3 .row>ul>li{width:32%;margin-right:3%}#edd-edit-order-form .columns-4 .column,#edd-purchased-files.columns-4 .inside>ul>li,#edd-purchased-files.columns-4 .row>ul>li{width:22%;margin-right:2%}#edd-edit-order-form .column:nth-child(2n+1),#edd-edit-order-form .columns-3 .column:nth-child(2n+1),#edd-edit-order-form .columns-4 .column:nth-child(3n+1){margin-right:0}#edd-purchased-files.columns-4 li.download{width:33%}#edd-purchased-files.columns-3 .inside>ul>li.price,#edd-purchased-files.columns-3 .row>ul>li.price,#edd-purchased-files.columns-4 li.price{width:14%}#edd-purchased-files.columns-4 li.actions{width:25%;margin-top:0;margin-right:0}}@media screen and (max-width:1284px){#edd-edit-order-form .column strong{display:block}}#edd_product_stats .label{display:inline-block}#edd_product_stats hr{border-style:solid;border-width:1px;border-color:#ccc #fff #fff #ccc}#edd_product_stats .product-earnings-stats:before,#edd_product_stats .product-sales-stats:before{color:#82878c;font:400 20px/1 dashicons;speak:none;display:inline-block;padding:0 2px 0 0;top:0;left:-1px;position:relative;vertical-align:top;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-decoration:none!important}#edd_product_stats .product-sales-stats:before{content:'\f174'}#edd_product_stats .product-earnings-stats:before{content:'\f239'}.edd_dashboard_widget table thead td{border-bottom:1px solid #ececec;color:#777}.edd_dashboard_widget .table_left{float:left;width:45%}.edd_dashboard_widget .table_right{float:right;width:45%}.edd_dashboard_widget .inside{font-size:12px}.edd_dashboard_widget td{padding:3px 0}.edd_dashboard_widget .b{font-size:14px;font-family:Georgia,"Times New Roman","Bitstream Charter",Times,serif;padding-right:6px;width:auto}.edd_dashboard_widget .t{font-size:12px;padding-right:12px;padding-top:6px;color:#777;width:100%}.edd_dashboard_widget .label_heading{margin:0 0 8px 12px;display:block;font-size:12px;font-family:Helvetica,Arial,sans-serif;color:#8f8f8f;font-weight:400;padding-top:10px;border-top:1px solid #ececec}.edd_dashboard_widget .edd_dashboard_widget_subheading{margin:1em 0 0;border-top:1px solid #ececec;padding-top:10px;color:#8f8f8f;font-size:14px}.edd_dashboard_widget .edd_dashboard_widget_subheading+.table{margin:8px 0 0}.edd_dashboard_widget .edd_price_label{background:#00769c;padding:2px 4px;border-radius:3px;color:#fff;margin-right:2px;font-size:10px}.edd_dashboard_widget table{width:100%;margin-left:0;margin-bottom:1em}td.edd_order_label{width:80%}@media handheld,only screen and (max-width:1000px){.edd_dashboard_widget .edd-recent-email{display:none}}#edd-dashboard-widgets-wrap .postbox h3{cursor:default}#edd-date-range-options,#edd-graphs-date-options{float:left}#edd-date-range-options span{float:left;margin-right:6px;height:24px;line-height:24px}.edd-export-form{position:relative}.edd-export-form .edd-progress{background:#ddd;position:absolute;bottom:15px;height:15px;width:95%}.edd-export-form .edd-progress div{height:100%;background:#ccc;width:0}.edd-export-form .notice-wrap{background-color:#f4f4f4;padding:12px 12px 4px;margin:20px -12px -23px;border-style:solid;border-width:1px 0;border-color:#eae9e9;overflow:auto}.edd-export-form .notice-wrap .spinner{margin:4px 10px 8px}.admin-color-fresh .edd-export-form .edd-progress div{background:#0073aa}.admin-color-light .edd-export-form .edd-progress div{background:#888}.admin-color-blue .edd-export-form .edd-progress div{background:#096484}.admin-color-coffee .edd-export-form .edd-progress div{background:#c7a589}.admin-color-ectoplasm .edd-export-form .edd-progress div{background:#a3b745}.admin-color-midnight .edd-export-form .edd-progress div{background:#e14d43}.admin-color-sunrise .edd-export-form .edd-progress div{background:#dd823b}#edd-graphs-filter label{vertical-align:inherit}#edd-graphs-filter .graph-option-section{float:left;line-height:2.5em;padding-right:5px}.edd-mix-totals{padding:10px;background-color:#fff;box-shadow:0 1px 1px rgba(0,0,0,.04);border:1px solid #e5e5e5}.edd-mix-chart{display:inline-block;width:49%;vertical-align:top}.edd-graph-notes{color:#9c9c9c}.edd-graph-notes span{display:block}.edd-pie-graph .legend{display:none}.edd-pie-legend{margin-top:10px;overflow:auto}.edd-legend-item-wrapper{width:48%;display:inline-block;font-size:8pt;color:#333;padding:2px 5px 0;height:20px}.edd-legend-color{display:inline-block;height:15px;width:20px;border:1px solid #cfcfcf;margin-right:5px}.edd-pie-legend-item{display:inline-block;vertical-align:top;width:80%}#edd_tax_rates{margin:1em 0 0}#edd_tax_rates .edd_tax_country *,#edd_tax_rates .edd_tax_state *{max-width:100%}#edd_tax_rates .edd_tax_country,#edd_tax_rates .edd_tax_state{width:180px}#edd_tax_rates .edd_tax_rate{width:80px}#edd_tax_rates th{padding:15px 10px}[class^=license-]{padding:10px}[class^=license-] input[type=text]{margin-right:3px}.license-error-notice,.license-expires-soon-notice{background-color:#fff;padding:10px;border-left:4px solid #7ad03a;overflow:auto;-webkit-box-shadow:0 1px 1px 0 rgba(0,0,0,.1);box-shadow:0 1px 1px 0 rgba(0,0,0,.1)}.license-error-notice{border-left:4px solid #dd3d36}.license-expiration-date-notice,.license-lifetime-notice,.license-null{padding:0 0 0 14px}.license-expiration-date-notice .edd-license-data p,.license-lifetime-notice .edd-license-data p{color:#666;font-size:14px;font-style:italic;margin:4px 0 0}div[class^=license-] .edd-license-data p{margin-left:4px}.post-type-download .fixed .column-name{width:27%}.post-type-download .fixed .column-description{width:30%}.post-type-download .fixed .column-slug{width:23%}.post-type-download .fixed .column-posts{text-align:left;width:17%}#system-info-textarea{width:800px;height:400px;font-family:Menlo,Monaco,monospace;background:0 0;white-space:pre;overflow:auto;display:block}#TB_window #edd-add-download:active,#TB_window #edd-add-download:focus,#TB_window #edd-add-download:hover{color:#fff}.edd-graph .y1Axis{color:#edc240!important}.edd-graph .y2Axis{color:#afd8f8!important}.download_page_edd-tools .apikeys .column-user{width:192px}.edd-select-chosen{width:300px}.chosen-container-multi .chosen-choices{-webkit-border-radius:3px;border-radius:3px;border-color:#dfdfdf;background-image:none}.chosen-container-multi .chosen-choices input{margin:2px;height:27px!important;border-color:#dfdfdf}.chosen-container .chosen-drop{border-color:#aaa;-webkit-box-shadow:1px 1px 2px rgba(0,0,0,.1);box-shadow:1px 1px 2px rgba(0,0,0,.1)}.chosen-container .search-field{float:none!important}.chosen-container .search-field input{width:90%!important}.chosen-container-active .chosen-choices{-webkit-border-top-left-radius:3px;-webkit-border-top-right-radius:3px;-webkit-border-bottom-left-radius:0;border-color:#aaa;-webkit-box-shadow:1px 1px 2px rgba(0,0,0,.1);box-shadow:1px 1px 2px rgba(0,0,0,.1);border-radius:3px 3px 0 0}.download_page_edd-tools .tablenav .actions{overflow:visible}.edd_user_search_wrap{position:relative;overflow:visible}.edd_user_search_results{position:absolute;left:0;top:27px}.edd_user_search_results a.edd-ajax-user-cancel{position:absolute;right:6px;top:2px}.edd_user_search_results ul{padding:10px 10px 4px;margin:0;background:#f0f0f0;border:1px solid #DFDFDF;width:300px;max-height:200px;overflow-y:scroll}@media screen and (max-width:1100px){.edd-mix-chart{display:block;width:100%}}@media screen and (max-width:782px){.post-type-download .nav-tab-wrapper a{padding:2px 4px;font-size:50%}.download_page_edd-tools .apikeys .column-user{width:80px}.license-expiration-date-notice,.license-lifetime-notice,.license-null{padding-left:0}[class^=license-] input[type=text]{margin-bottom:3px}}#edd-item-tab-wrapper{margin-left:-1px;z-index:1;text-align:center;display:inline-block}#edd-item-tab-wrapper-list li{background-color:#fff;width:32px;height:32px}#edd-item-tab-wrapper-list .inactive{background-color:#fff;color:#eee;border-left:1px solid #e5e5e5}#edd-item-tab-wrapper-list .active{border-width:1px 1px 1px 0;border-style:solid;border-color:#e5e5e5}#edd-item-tab-wrapper-list :not(:last-child){margin-bottom:3px}#edd-item-tab-wrapper-list .dashicons{font-size:24px;line-height:32px}#edd-item-card-wrapper .left{float:left}#edd-item-card-wrapper .right{float:right}#edd-item-card-wrapper input{font-weight:400}#edd-item-card-wrapper .customer-id,.customer-info .customer-name{font-size:24px;font-weight:600}#edd-item-card-wrapper{display:inline-block;margin-left:-1px;z-index:2;width:700px;background-color:#FFF;min-height:200px;border:1px solid #e5e5e5;webkit-box-shadow:0 1px 1px rgba(0,0,0,.04);box-shadow:0 1px 1px rgba(0,0,0,.04)}#edd-item-card-wrapper .customer-section{border-bottom:1px solid #eee;margin-bottom:10px;overflow:auto}#edd-item-card-wrapper .customer-section table{margin-bottom:20px}#edd-item-card-wrapper>div{padding:0 20px}#edd-item-card-wrapper>div:first-child{padding-top:20px}#edd-item-card-wrapper>div:last-child{padding-bottom:20px;border:none}#edd-item-card-wrapper .avatar-wrap{padding-right:10px;text-align:center}#edd-item-card-wrapper .customer-main-wrapper input{width:200px}#edd-item-card-wrapper .customer-address-wrapper{max-width:33%;margin-right:25px;width:202px}#edd-item-card-wrapper .customer-address-wrapper select,#edd-item-card-wrapper .edd_user_search_results ul{width:200px}#edd-item-card-wrapper .customer-info{margin-top:5px;min-height:185px;margin-bottom:10px}#edd-item-card-wrapper .info-wrapper{min-height:125px;overflow:visible}#edd-item-card-wrapper a.delete{text-decoration:none;color:red;margin-right:5px}.customer-edit-link a,.disconnect-user a{font-size:12px;font-weight:400;text-decoration:none}#customer-edit-actions{text-align:center;margin-bottom:20px;line-height:28px}#customer-edit-actions .button-secondary{margin-right:10px}#edd-item-card-wrapper .info-item{line-height:16px;display:block;padding-bottom:5px}#edd-item-card-wrapper .edit-item{display:none}#edd-item-card-wrapper .edd_user_search_results{left:1px;top:16px}#edd-item-stats-wrapper{margin:0 auto;text-align:center;min-height:30px}#edd-item-stats-wrapper li{width:50%;float:left;line-height:22px;font-size:14px}#edd-item-stats-wrapper a{text-decoration:none}#edd-item-stats-wrapper .dashicons{color:#888}#edd-item-tables-wrapper table{width:100%;text-align:center}#edd-item-tables-wrapper th{text-align:center}#edd-item-tables-wrapper .downloads tr>td:first-child,#edd-item-tables-wrapper .downloads tr>th:first-child{text-align:left}#edd-item-tables-wrapper .downloads tr>td:only-child,.delete-customer{text-align:center}#edd-item-notes-wrapper{min-height:50px}.edd-item-notes-header img,.edd-item-notes-header span{font-weight:600;line-height:30px;vertical-align:middle}.customer-note-input{width:100%;margin-bottom:5px}#edd-customer-notes div:nth-of-type(even){background-color:#fcfcfc}.customer-note-wrapper{border-bottom:1px solid #f9f9f9;min-height:38px;padding:7px 0 7px 7px}.customer-note-wrapper span{display:block}.note-content-wrap{padding-top:7px}#edd-item-card-wrapper .notice-wrap{margin-left:-20px;margin-right:-20px;padding-left:20px;padding-right:20px}.recount-stats-controls form{display:inline}.edd-recount-stats-descriptions span{line-height:24px;display:none}
|
1 |
+
.edd-admin-box .label,.edd-admin-box-inside .strong{font-weight:600}.edd-mobile-link,.edd_repeatable_row td{vertical-align:middle}.edd-hidden{display:none}.edd-clearfix:after{content:".";display:block;height:0;text-indent:-9999px;visibility:hidden}.edd-wrap a{text-decoration:none}a.edd-delete{color:#a00}a.edd-delete:hover{color:red}.download_page_edd-settings .form-table label{color:#666;font-size:14px;font-style:italic;margin:4px 0 0}.download_page_edd-settings .form-table input.small-text~label,.download_page_edd-settings .form-table input[type=checkbox]+label{display:inline}.download_page_edd-settings .form-table tr>th>h3,.download_page_edd-settings .form-table tr>th>strong{font-size:1.2em;font-weight:600;margin:0 auto}.edd-help-tip{cursor:help}.edd-ui-tooltip{background:#333!important;border-radius:3px!important;box-shadow:1px 1px 2px 1px rgba(214,214,214,.5);color:#dedede!important;max-width:300px;padding:7px;text-rendering:optimizeLegibility}#edd-add-ons h2.nav-tab-wrapper{position:relative}#edd-add-ons h2 .button-primary,.edd-tab-span{position:absolute}.edd-tab-span{top:-6px;right:0}.edd-add-ons-footer{padding-top:10px}#edd-add-ons h2{margin:0 0 15px}#edd-add-ons .edd-extension{background:#fff;border:1px solid #ccc;float:left;padding:14px;position:relative;margin:0 15px 15px 0;width:320px;height:315px}#edd-add-ons .edd-extension h3{font-size:13px;margin:0 0 8px}#edd-add-ons .edd-extension .button-secondary{position:absolute;bottom:14px;left:14px}#edd-add-ons .edd-browse-all{clear:both;width:100%}#edd-add-ons .edd-extension .third-party{display:none}#edd-add-ons .edd-starter-package{background-color:#85c0e5;border-color:#62a9d7;color:#fff}#edd-add-ons .edd-starter-package h3{color:#fff}#edd-add-ons .edd-extension .wp-post-image{width:100%;height:auto}#edd-products{height:100px;min-width:200px}#edd-add-discount input[type=checkbox],#edd-edit-discount input[type=checkbox]{width:15px}#edd-payment-filters{background:#f5f5f5;clear:both;background-image:-webkit-gradient(linear,left bottom,left top,from(#f5f5f5),to(#fafafa));background-image:-webkit-linear-gradient(bottom,#f5f5f5,#fafafa);background-image:-moz-linear-gradient(bottom,#f5f5f5,#fafafa);background-image:-o-linear-gradient(bottom,#f5f5f5,#fafafa);background-image:linear-gradient(to top,#f5f5f5,#fafafa);border-color:#dfdfdf;border-width:1px;border-style:solid;border-radius:3px;font-size:13px;line-height:2.1em;overflow:auto;padding:12px;margin:8px 0}#edd-payments-filter ul.subsubsub{margin-bottom:8px}#edd-payment-filters p{color:#777}tr.status-refunded td{background:#cecece;border-top-color:#ccc}.wp-list-table.downloads th#ID{width:80px}.wp-list-table.downloads th#details{width:130px}.wp-list-table.downloads th#date{width:140px}.wp-list-table.downloads th#user{width:130px}.edd-mobile-link{line-height:32px}.edd-mobile-link img{max-width:80%;height:auto;float:left}@media handheld,only screen and (max-width:640px){.wp-list-table.downloads th{width:auto!important}}.download_page_edd-payment-history .ui-dialog .ui-dialog-titlebar-close span{margin-left:-8px;margin-top:-8px}#edd-download-link-textarea{width:100%}.edd_files_name_label{width:225px;float:left}.edd_files_url_label{width:220px;float:left}#postbox-container-1 .edd_files_name_label,#postbox-container-1 .edd_files_url_label{width:80px}.edd_add_repeatable{display:inline-block}#downloadinformation .edd_meta_table_wrap table input,#downloadinformation .edd_meta_table_wrap table select,#downloadinformation .edd_meta_table_wrap table textarea{margin:4px 0;width:100%}#downloadinformation .edd_meta_table_wrap table .submit input{width:auto}.edd_repeatable_upload_wrapper .edd_repeatable_upload_field_container{position:relative}.edd_upload_file{background:#fff;display:block;padding:2px 8px;position:absolute;top:3px;right:7px}.edd_upload_field{padding-right:8em}.edd_remove_repeatable{border:none;cursor:pointer;display:inline-block;padding:0;overflow:hidden;margin:8px 0 0;text-indent:-9999px;width:10px;height:10px}.edd_remove_repeatable:active,.edd_remove_repeatable:focus,.edd_remove_repeatable:hover{background-position:-10px 0!important}.edd_draghandle{background:url(../images/edd-cross-hair.png);cursor:move;display:block;margin:4px 0 0;width:20px;height:20px}textarea#edd-payment-note{width:100%;height:4em;margin:0}.edd_repeatable_product_wrapper .edd-select,.edd_repeatable_upload_wrapper .pricing select{min-width:100%}#edd_product_notes_field{margin:0;width:98%;height:4em}.edd_repeatable_default_wrapper{text-align:center;width:25px}#edd-purchased-files ul li.remove,td.edd_order_price{text-align:right}.edd-admin-box-inside{border-bottom:1px solid #eee;clear:both;padding:3px 12px;margin:0;word-break:break-word}.rtl .edd-admin-box-inside{padding:5px 10px 5px 0}.edd-payment-fees .fee-label{color:#666;font-weight:400}.edd-admin-box .right{float:right}.rtl .edd-admin-box .right{float:left;margin-left:10px}#edd-customer-details .actions,#edd-order-recalc-total{float:right}#edd-order-details .inside,#edd-order-update .inside{margin:0;padding:0}#edd-order-update input.edd_datepicker{width:180px}#edd-order-update input[type=number].edd-payment-time-hour,#edd-order-update input[type=number].edd-payment-time-min{width:50px}#edd-order-resend-receipt .inside{margin-top:11px}.edd-admin-box-inside:last-child{border-bottom:0}#edd-edit-order-form .data-payment-key{word-break:break-all}.edd-order-update-box #major-publishing-actions .button-secondary{margin-right:10px}#edd-purchased-files .edd-select-chosen{width:196px}#edd-customer-details .order-data-address input,#edd-customer-details .order-data-column p.data input,#edd-edit-order-form .column input,#edd-order-address-country-wrap select,#edd-purchased-files ul{clear:both;display:block}.edd-order-data input.small-text{margin:0}.edd-order-data input.med-text{margin:0;width:100px}#edd-order-update span.label{display:inline;width:50px}.edd-order-update-box .button-primary{margin-right:0}#edd-edit-order-form .column .description{padding-right:10px}#edd-edit-order-form .column,#edd-purchased-files .inside>ul>li,#edd-purchased-files .row>ul>li{display:inline-block;line-height:30px;position:relative;margin-right:5%;vertical-align:middle}#edd-purchased-files li.actions{min-width:200px;text-align:right}#edd-purchased-files .row{border-bottom:1px solid #eee;padding:12px}#edd-purchased-files ul{font-size:0}#edd-purchased-files ul li{font-size:13px}#edd-order-data .data span{color:#666;font-weight:600}#edd-purchased-files .inside{padding:12px}.edd-price-field{width:80px}#edd_products .edd-select,.edd_repeatable_product_wrapper .edd-select,.edd_repeatable_upload_wrapper .pricing select{min-width:100%;max-width:200px}.edd_repeatable_product_wrapper td{overflow:visible}@media screen and (max-width:782px){.order-data-column input[type=email]{padding:6px 10px}}@media screen and (min-width:851px){#edd-purchased-files .inside li.actions{text-align:right}}@media screen and (max-width:1024px){#edd-edit-order-form .column{width:49%}}@media screen and (max-width:1280px) and (min-width:1279px){#edd-purchased-files .inside li.actions{width:35%}#edd-edit-order-form .column{width:32%}}@media screen and (min-width:1280px){#edd-edit-order-form .column,#edd-purchased-files.columns-3 .inside>ul>li,#edd-purchased-files.columns-3 .row>ul>li{width:32%;margin-right:3%}#edd-edit-order-form .columns-4 .column,#edd-purchased-files.columns-4 .inside>ul>li,#edd-purchased-files.columns-4 .row>ul>li{width:22%;margin-right:2%}#edd-edit-order-form .column:nth-child(2n+1),#edd-edit-order-form .columns-3 .column:nth-child(2n+1),#edd-edit-order-form .columns-4 .column:nth-child(3n+1){margin-right:0}#edd-purchased-files.columns-4 li.download{width:33%}#edd-purchased-files.columns-3 .inside>ul>li.price,#edd-purchased-files.columns-3 .row>ul>li.price,#edd-purchased-files.columns-4 li.price{width:14%}#edd-purchased-files.columns-4 li.actions{width:25%;margin-top:0;margin-right:0}}@media screen and (max-width:1284px){#edd-edit-order-form .column strong{display:block}}#edd_product_stats .label{display:inline-block}#edd_product_stats hr{border-style:solid;border-width:1px;border-color:#ccc #fff #fff #ccc}#edd_product_stats .product-earnings-stats:before,#edd_product_stats .product-sales-stats:before{color:#82878c;font:400 20px/1 dashicons;display:inline-block;padding:0 2px 0 0;position:relative;top:0;left:-1px;speak:none;text-decoration:none!important;vertical-align:top;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}#edd-item-card-wrapper a.delete,#edd-item-stats-wrapper a,.customer-edit-link a,.disconnect-user a,.wrap-licenses .edd-license-data.edd-license-expired a:hover,.wrap-licenses .edd-license-data.license-expires-soon-notice a:hover,.wrap-licenses .edd-license-data[class*=edd-license-] a:hover{text-decoration:none}#edd_product_stats .product-sales-stats:before{content:'\f174'}#edd_product_stats .product-earnings-stats:before{content:'\f239'}.edd_dashboard_widget table thead td{border-bottom:1px solid #ececec;color:#777}.edd_dashboard_widget .table_left{float:left;width:45%}.edd_dashboard_widget .table_right{float:right;width:45%}.edd_dashboard_widget .inside{font-size:12px}.edd_dashboard_widget td{padding:3px 0}.edd_dashboard_widget .b{font-size:14px;font-family:Georgia,"Times New Roman","Bitstream Charter",Times,serif;padding-right:6px;width:auto}.edd_dashboard_widget .t{font-size:12px;padding-right:12px;padding-top:6px;color:#777;width:100%}.edd_dashboard_widget .label_heading{border-top:1px solid #ececec;color:#8f8f8f;font-family:Helvetica,Arial,sans-serif;font-size:12px;font-weight:400;display:block;padding-top:10px;margin:0 0 8px 12px}.edd_dashboard_widget .edd_dashboard_widget_subheading{border-top:1px solid #ececec;color:#8f8f8f;font-size:14px;padding-top:10px;margin:1em 0 0}.edd_dashboard_widget .edd_dashboard_widget_subheading+.table{margin:8px 0 0}.edd_dashboard_widget .edd_price_label{background:#00769c;border-radius:3px;color:#fff;font-size:10px;padding:2px 4px;margin-right:2px}.edd_dashboard_widget table{width:100%;margin-left:0;margin-bottom:1em}td.edd_order_label{width:80%}@media handheld,only screen and (max-width:1000px){.edd_dashboard_widget .edd-recent-email{display:none}}#edd-dashboard-widgets-wrap .postbox h3{cursor:default}#edd-date-range-options,#edd-graphs-date-options{float:left}#edd-date-range-options span{float:left;line-height:24px;height:24px;margin-right:6px}.edd-import-export-form{position:relative}.edd-import-export-form .edd-progress{background:#ddd;position:absolute;bottom:15px;width:95%;height:15px}.edd-import-export-form .edd-progress div{background:#ccc;height:100%;width:0}.edd-import-export-form .notice-wrap{background-color:#f4f4f4;border-style:solid;border-width:1px 0;border-color:#eae9e9;padding:12px 12px 4px;overflow:auto;margin:20px -12px -23px}.edd-import-export-form .notice-wrap .spinner{margin:4px 10px 8px}.admin-color-fresh .edd-import-export-form .edd-progress div{background:#0073aa}.admin-color-light .edd-import-export-form .edd-progress div{background:#888}.admin-color-blue .edd-import-export-form .edd-progress div{background:#096484}.admin-color-coffee .edd-import-export-form .edd-progress div{background:#c7a589}.admin-color-ectoplasm .edd-import-export-form .edd-progress div{background:#a3b745}.admin-color-midnight .edd-import-export-form .edd-progress div{background:#e14d43}.admin-color-sunrise .edd-import-export-form .edd-progress div{background:#dd823b}#edd-graphs-filter label{vertical-align:inherit}#edd-graphs-filter .graph-option-section{float:left;line-height:2.5em;padding-right:5px}.edd-mix-totals{background-color:#fff;border:1px solid #e5e5e5;box-shadow:0 1px 1px rgba(0,0,0,.04);padding:10px}.edd-mix-chart{display:inline-block;width:49%;vertical-align:top}.edd-graph-notes{color:#9c9c9c}.edd-graph-notes span{display:block}.edd-pie-graph .legend{display:none}.edd-pie-legend{overflow:auto;margin-top:10px}.edd-legend-item-wrapper{color:#333;display:inline-block;font-size:8pt;padding:2px 5px 0;width:48%;height:20px}.edd-legend-color{border:1px solid #cfcfcf;display:inline-block;margin-right:5px;width:20px;height:15px}.edd-pie-legend-item{display:inline-block;vertical-align:top;width:80%}#edd_tax_rates{margin:1em 0 0}#edd_tax_rates .edd_tax_country *,#edd_tax_rates .edd_tax_state *{max-width:100%}#edd_tax_rates .edd_tax_country,#edd_tax_rates .edd_tax_state{width:180px}#edd_tax_rates .edd_tax_rate{width:80px}#edd_tax_rates th{padding:15px 10px}.wrap-licenses .form-table,.wrap-licenses caption,.wrap-licenses tbody,.wrap-licenses td,.wrap-licenses tfoot,.wrap-licenses th,.wrap-licenses thead,.wrap-licenses tr{display:block}.wrap-licenses .form-table tr{float:left;margin:0 15px 15px 0;background:#fff;border:1px solid #ccc;width:30.5%;max-width:350px;padding:14px;min-height:220px;position:relative;box-sizing:border-box}.wrap-licenses .form-table th{background:#f9f9f9;padding:14px;border-bottom:1px solid #ccc;margin:-14px -14px 20px;width:100%}.wrap-licenses .form-table td{padding:0}.wrap-licenses td input.regular-text{margin:0 0 8px;width:100%}.wrap-licenses .edd-license-data[class*=edd-license-]{position:absolute;background:#fafafa;padding:14px;border-top:1px solid #eee;margin:20px -14px -14px;min-height:67px;width:100%;bottom:14px;box-sizing:border-box}.wrap-licenses .edd-license-data[class*=edd-license-] a{color:#444}.wrap-licenses .edd-license-data.license-expires-soon-notice{background-color:#00a0d2;color:#fff;border-color:#00a0d2}.wrap-licenses .edd-license-data.edd-license-expired{background-color:#e24e4e;color:#fff;border-color:#e24e4e}.wrap-licenses .edd-license-data.edd-license-error,.wrap-licenses .edd-license-data.edd-license-invalid,.wrap-licenses .edd-license-data.edd-license-item_name_mismatch,.wrap-licenses .edd-license-data.edd-license-missing,.wrap-licenses .edd-license-data.edd-license-site_inactive{background-color:#ffebcd;border-color:#ffebcd}.wrap-licenses .edd-license-data p{font-size:13px;margin-top:0}.wrap-licenses .edd-license-data.edd-license-expired a,.wrap-licenses .edd-license-data.license-expires-soon-notice a{color:#fff}.wrap-licenses p.submit{clear:both}.post-type-download .fixed .column-name{width:27%}.post-type-download .fixed .column-description{width:30%}.post-type-download .fixed .column-slug{width:23%}.post-type-download .fixed .column-posts{text-align:left;width:17%}#system-info-textarea{background:0 0;font-family:Menlo,Monaco,monospace;display:block;overflow:auto;white-space:pre;width:800px;height:400px}#TB_window #edd-add-download:active,#TB_window #edd-add-download:focus,#TB_window #edd-add-download:hover{color:#fff}.edd-graph .y1Axis{color:#edc240!important}.edd-graph .y2Axis{color:#afd8f8!important}.download_page_edd-tools .apikeys .column-user{width:192px}.edd-select-chosen{width:300px}.chosen-container-multi .chosen-choices{background-image:none;border-color:#dfdfdf;-webkit-border-radius:3px;border-radius:3px}.chosen-container-multi .chosen-choices input{border-color:#dfdfdf;height:27px!important;margin:2px}.chosen-container .chosen-drop{border-color:#aaa;-webkit-box-shadow:1px 1px 2px rgba(0,0,0,.1);box-shadow:1px 1px 2px rgba(0,0,0,.1)}.chosen-container .search-field{float:none!important}.chosen-container .search-field input{width:90%!important}.chosen-container-active .chosen-choices{border-color:#aaa;-webkit-border-top-left-radius:3px;-webkit-border-top-right-radius:3px;-webkit-border-bottom-left-radius:0;-webkit-box-shadow:1px 1px 2px rgba(0,0,0,.1);box-shadow:1px 1px 2px rgba(0,0,0,.1);border-radius:3px 3px 0 0}.download_page_edd-tools .tablenav .actions{overflow:visible}.edd_user_search_wrap{position:relative;overflow:visible}.edd_user_search_results{position:absolute;left:0;top:27px}.edd_user_search_results a.edd-ajax-user-cancel{position:absolute;right:6px;top:2px}.edd_user_search_results ul{background:#f0f0f0;border:1px solid #dfdfdf;overflow-y:scroll;padding:10px 10px 4px;margin:0;max-height:200px;width:300px}.wp-list-table .type-download .row-actions{color:#999}@media screen and (max-width:1100px){.edd-mix-chart{display:block;width:100%}.wrap-licenses .form-table tr{width:46%;max-width:none;min-height:230px}}@media screen and (max-width:782px){.post-type-download .nav-tab-wrapper a{font-size:50%;padding:2px 4px}.download_page_edd-tools .apikeys .column-user{width:80px}.license-expiration-date-notice,.license-lifetime-notice,.license-null{padding-left:0}[class^=license-] input[type=text]{margin-bottom:3px}}@media screen and (max-width:600px){.wrap-licenses .form-table tr{width:100%;min-height:230px}}#edd-item-tab-wrapper{display:inline-block;margin-left:-1px;text-align:center;z-index:1}#edd-item-tab-wrapper-list li{background-color:#fff;width:32px;height:32px}#edd-item-tab-wrapper-list .inactive{background-color:#fff;border-left:1px solid #e5e5e5;color:#eee}#edd-item-tab-wrapper-list .inactive a,#edd-item-tab-wrapper-list .inactive a:visited{color:#eee;display:block;line-height:32px;text-decoration:none}#edd-item-tab-wrapper-list .inactive a:active,#edd-item-tab-wrapper-list .inactive a:focus,#edd-item-tab-wrapper-list .inactive a:hover{color:#444}#edd-item-tab-wrapper-list .active{border-color:#e5e5e5;border-style:solid;border-width:1px 1px 1px 0}#edd-item-tab-wrapper-list :not(:last-child){margin-bottom:3px}#edd-item-tab-wrapper-list .dashicons{font-size:24px;line-height:32px}#edd-item-card-wrapper .left{float:left}#edd-item-card-wrapper .right{float:right}#edd-item-card-wrapper input{font-weight:400}#edd-item-card-wrapper .customer-id,.customer-info .customer-name{font-size:24px;font-weight:600}#edd-item-card-wrapper{background-color:#fff;border:1px solid #e5e5e5;webkit-box-shadow:0 1px 1px rgba(0,0,0,.04);box-shadow:0 1px 1px rgba(0,0,0,.04);display:inline-block;margin-left:-1px;min-height:200px;width:700px;z-index:2}#edd-item-card-wrapper .customer-section{border-bottom:1px solid #eee;margin-bottom:10px;overflow:auto}#edd-item-card-wrapper .customer-section table{margin-bottom:20px}#edd-item-card-wrapper>div{padding:0 20px}#edd-item-card-wrapper>div:first-child{padding-top:20px}#edd-item-card-wrapper>div:last-child{border:none;padding-bottom:20px}#edd-item-card-wrapper .avatar-wrap{padding-right:10px;text-align:center}#edd-item-card-wrapper .customer-main-wrapper input{width:200px}#edd-item-card-wrapper .customer-address-wrapper{margin-right:25px;max-width:33%;width:202px}#edd-item-card-wrapper .customer-address-wrapper select,#edd-item-card-wrapper .edd_user_search_results ul{width:200px}#edd-item-card-wrapper .customer-info{margin-top:5px;margin-bottom:10px;min-height:185px}#edd-item-card-wrapper .info-wrapper{min-height:125px;overflow:visible}#edd-item-card-wrapper a.delete{color:red;margin-right:5px}.customer-edit-link a,.disconnect-user a{font-size:12px;font-weight:400}#customer-edit-actions{line-height:28px;margin-bottom:20px;text-align:center}#customer-edit-actions .button-secondary{margin-right:10px}#edd-item-card-wrapper .info-item{display:block;line-height:16px;padding-bottom:5px}#edd-item-card-wrapper .edit-item{display:none}#edd-item-card-wrapper .edd_user_search_results{left:1px;top:16px}#edd-item-stats-wrapper{margin:0 auto;min-height:30px;text-align:center}#edd-item-stats-wrapper li{font-size:14px;float:left;line-height:22px;width:50%}#edd-item-stats-wrapper .dashicons{color:#888}#edd-item-tables-wrapper table{text-align:center;width:100%}#edd-item-tables-wrapper th{text-align:center}#edd-item-tables-wrapper .downloads tr>td:first-child,#edd-item-tables-wrapper .downloads tr>th:first-child,#edd-item-tables-wrapper .emails tr>td:first-child,#edd-item-tables-wrapper .emails tr>th:first-child{text-align:left}#edd-item-tables-wrapper .downloads tr>td:only-child,.delete-customer{text-align:center}#edd-item-tables-wrapper .emails .add-customer-email-row td{background-color:#f9f9f9;border-top:1px solid #e5e5e5}#edd-item-tables-wrapper .emails .primary-email-icon{font-size:13px;vertical-align:middle;line-height:1.5em}#edd-item-tables-wrapper .emails input{vertical-align:middle;margin:6px 0}#edd-item-tables-wrapper .emails .spinner{float:none}#edd-item-notes-wrapper{min-height:50px}.edd-item-notes-header img,.edd-item-notes-header span{font-weight:600;line-height:30px;vertical-align:middle}.customer-note-input{margin-bottom:5px;width:100%}#edd-customer-notes div:nth-of-type(even){background-color:#fcfcfc}.customer-note-wrapper{border-bottom:1px solid #f9f9f9;min-height:38px;padding:7px 0 7px 7px}.customer-note-wrapper span{display:block}.note-content-wrap{padding-top:7px}#edd-item-card-wrapper .notice-wrap{padding-left:20px;padding-right:20px;margin-left:-20px;margin-right:-20px}@media screen and (max-width:810px) and (min-width:656px){#edd-item-card-wrapper{width:600px}.customer-info .customer-name{font-size:16px}#edd-item-card-wrapper .widefat td,.widefat th{padding:4px 6px;max-width:100px!important;display:table-cell}}@media screen and (max-width:656px){#edd-item-card-wrapper .customer-id,.customer-info .customer-name{font-size:16px}#edd-item-card-wrapper{margin:0;width:100%}#edd-item-tab-wrapper{margin:0 0 -5px}#edd-item-tab-wrapper-list{height:32px;margin:0}#edd-item-tab-wrapper-list .inactive{border-bottom:1px solid #e5e5e5;border-left:none}#edd-item-tab-wrapper-list .active{border-width:1px 1px 0}#edd-item-tab-wrapper-list li{float:left;margin:0 0 0 5px!important;width:32px;height:32px}#edd-item-tab-wrapper-list li span{width:32px;height:32px;margin:0!important}#edd-item-card-wrapper .customer-info{min-height:210px}.edd-item-info.customer-info{position:relative}#edd-item-card-wrapper .customer-address-wrapper{float:none;position:absolute;top:84px;left:110px;max-width:200px}#edd-item-card-wrapper .customer-main-wrapper{float:none;position:absolute;left:110px}#edd-item-card-wrapper #edd-item-stats-wrapper{padding-left:0;padding-right:0}#edd-item-card-wrapper .customer-section{margin-bottom:0}#edd-item-card-wrapper .widefat td,.widefat th{padding:4px 6px;max-width:100px!important;display:table-cell;overflow:hidden}#edd-item-card-wrapper>div:first-child{height:auto}}.recount-stats-controls form{display:inline}.edd-recount-stats-descriptions span{display:none;line-height:24px}
|
assets/images/screenshots/26-customer.png
ADDED
Binary file
|
assets/images/screenshots/26-import.png
ADDED
Binary file
|
assets/images/screenshots/26-refund.png
ADDED
Binary file
|
assets/js/admin-scripts.js
CHANGED
@@ -1,5 +1,24 @@
|
|
1 |
jQuery(document).ready(function ($) {
|
2 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3 |
/**
|
4 |
* Download Configuration Metabox
|
5 |
*/
|
@@ -118,7 +137,20 @@ jQuery(document).ready(function ($) {
|
|
118 |
var row = $(this).parent().parent( 'tr' ),
|
119 |
count = row.parent().find( 'tr' ).length - 1,
|
120 |
type = $(this).data('type'),
|
121 |
-
repeatable = 'tr.edd_repeatable_' + type + 's'
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
122 |
|
123 |
if ( type === 'price' ) {
|
124 |
var price_row_id = row.data('key');
|
@@ -129,6 +161,7 @@ jQuery(document).ready(function ($) {
|
|
129 |
if( count > 1 ) {
|
130 |
$( 'input, select', row ).val( '' );
|
131 |
row.fadeOut( 'fast' ).remove();
|
|
|
132 |
} else {
|
133 |
switch( type ) {
|
134 |
case 'price' :
|
@@ -1173,7 +1206,6 @@ jQuery(document).ready(function ($) {
|
|
1173 |
data: {
|
1174 |
action: search_type,
|
1175 |
s: val,
|
1176 |
-
current_id: edd_vars.post_id,
|
1177 |
no_bundles: no_bundles
|
1178 |
},
|
1179 |
dataType: "json",
|
@@ -1438,6 +1470,200 @@ jQuery(document).ready(function ($) {
|
|
1438 |
};
|
1439 |
EDD_Export.init();
|
1440 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1441 |
/**
|
1442 |
* Customer management screen JS
|
1443 |
*/
|
@@ -1452,6 +1678,7 @@ jQuery(document).ready(function ($) {
|
|
1452 |
},
|
1453 |
init : function() {
|
1454 |
this.edit_customer();
|
|
|
1455 |
this.user_search();
|
1456 |
this.remove_user();
|
1457 |
this.cancel_edit();
|
@@ -1467,6 +1694,43 @@ jQuery(document).ready(function ($) {
|
|
1467 |
EDD_Customer.vars.customer_card_wrap_edit_item.fadeIn().css( 'display', 'block' );
|
1468 |
});
|
1469 |
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1470 |
user_search: function() {
|
1471 |
// Upon selecting a user from the dropdown, we need to update the User ID
|
1472 |
$( document.body ).on('click.eddSelectUser', '.edd_user_search_results a', function( e ) {
|
@@ -1577,7 +1841,7 @@ jQuery(document).ready(function ($) {
|
|
1577 |
};
|
1578 |
EDD_Customer.init();
|
1579 |
|
1580 |
-
//
|
1581 |
$('.edd-ajax-user-search').keyup(function() {
|
1582 |
var user_search = $(this).val();
|
1583 |
var exclude = '';
|
1 |
jQuery(document).ready(function ($) {
|
2 |
|
3 |
+
// Tooltips
|
4 |
+
$('.edd-help-tip').tooltip({
|
5 |
+
content: function() {
|
6 |
+
return $(this).prop('title');
|
7 |
+
},
|
8 |
+
tooltipClass: 'edd-ui-tooltip',
|
9 |
+
position: {
|
10 |
+
my: 'center top',
|
11 |
+
at: 'center bottom+10',
|
12 |
+
collision: 'flipfit',
|
13 |
+
},
|
14 |
+
hide: {
|
15 |
+
duration: 200,
|
16 |
+
},
|
17 |
+
show: {
|
18 |
+
duration: 200,
|
19 |
+
},
|
20 |
+
});
|
21 |
+
|
22 |
/**
|
23 |
* Download Configuration Metabox
|
24 |
*/
|
137 |
var row = $(this).parent().parent( 'tr' ),
|
138 |
count = row.parent().find( 'tr' ).length - 1,
|
139 |
type = $(this).data('type'),
|
140 |
+
repeatable = 'tr.edd_repeatable_' + type + 's',
|
141 |
+
focusElement,
|
142 |
+
focusable,
|
143 |
+
firstFocusable;
|
144 |
+
|
145 |
+
// Set focus on next element if removing the first row. Otherwise set focus on previous element.
|
146 |
+
if ( $(this).is( '.ui-sortable tr:first-child .edd_remove_repeatable:first-child' ) ) {
|
147 |
+
focusElement = row.next( 'tr' );
|
148 |
+
} else {
|
149 |
+
focusElement = row.prev( 'tr' );
|
150 |
+
}
|
151 |
+
|
152 |
+
focusable = focusElement.find( 'select, input, textarea, button' ).filter( ':visible' );
|
153 |
+
firstFocusable = focusable.eq(0);
|
154 |
|
155 |
if ( type === 'price' ) {
|
156 |
var price_row_id = row.data('key');
|
161 |
if( count > 1 ) {
|
162 |
$( 'input, select', row ).val( '' );
|
163 |
row.fadeOut( 'fast' ).remove();
|
164 |
+
firstFocusable.focus();
|
165 |
} else {
|
166 |
switch( type ) {
|
167 |
case 'price' :
|
1206 |
data: {
|
1207 |
action: search_type,
|
1208 |
s: val,
|
|
|
1209 |
no_bundles: no_bundles
|
1210 |
},
|
1211 |
dataType: "json",
|
1470 |
};
|
1471 |
EDD_Export.init();
|
1472 |
|
1473 |
+
/**
|
1474 |
+
* Import screen JS
|
1475 |
+
*/
|
1476 |
+
var EDD_Import = {
|
1477 |
+
|
1478 |
+
init : function() {
|
1479 |
+
this.submit();
|
1480 |
+
},
|
1481 |
+
|
1482 |
+
submit : function() {
|
1483 |
+
|
1484 |
+
var self = this;
|
1485 |
+
|
1486 |
+
$('.edd-import-form').ajaxForm({
|
1487 |
+
beforeSubmit: self.before_submit,
|
1488 |
+
success: self.success,
|
1489 |
+
complete: self.complete,
|
1490 |
+
dataType: 'json',
|
1491 |
+
error: self.error
|
1492 |
+
});
|
1493 |
+
|
1494 |
+
},
|
1495 |
+
|
1496 |
+
before_submit : function( arr, $form, options ) {
|
1497 |
+
|
1498 |
+
$form.find('.notice-wrap').remove();
|
1499 |
+
$form.append( '<div class="notice-wrap"><span class="spinner is-active"></span><div class="edd-progress"><div></div></div></div>' );
|
1500 |
+
|
1501 |
+
//check whether client browser fully supports all File API
|
1502 |
+
if ( window.File && window.FileReader && window.FileList && window.Blob ) {
|
1503 |
+
|
1504 |
+
// HTML5 File API is supported by browser
|
1505 |
+
|
1506 |
+
} else {
|
1507 |
+
|
1508 |
+
var import_form = $('.edd-import-form').find('.edd-progress').parent().parent();
|
1509 |
+
var notice_wrap = import_form.find('.notice-wrap');
|
1510 |
+
|
1511 |
+
import_form.find('.button-disabled').removeClass('button-disabled');
|
1512 |
+
|
1513 |
+
//Error for older unsupported browsers that doesn't support HTML5 File API
|
1514 |
+
notice_wrap.html('<div class="update error"><p>' + edd_vars.unsupported_browser + '</p></div>');
|
1515 |
+
return false;
|
1516 |
+
|
1517 |
+
}
|
1518 |
+
|
1519 |
+
},
|
1520 |
+
|
1521 |
+
success: function( responseText, statusText, xhr, $form ) {},
|
1522 |
+
|
1523 |
+
complete: function( xhr ) {
|
1524 |
+
|
1525 |
+
var response = jQuery.parseJSON( xhr.responseText );
|
1526 |
+
|
1527 |
+
if( response.success ) {
|
1528 |
+
|
1529 |
+
var $form = $('.edd-import-form .notice-wrap').parent();
|
1530 |
+
|
1531 |
+
$form.find('.edd-import-file-wrap,.notice-wrap').remove();
|
1532 |
+
|
1533 |
+
$form.find('.edd-import-options').slideDown();
|
1534 |
+
|
1535 |
+
// Show column mapping
|
1536 |
+
var select = $form.find('select.edd-import-csv-column');
|
1537 |
+
var row = select.parent().parent();
|
1538 |
+
var options = '';
|
1539 |
+
$.each( response.data.columns, function( key, value ) {
|
1540 |
+
options += '<option value="' + value + '">' + value + '</option>';
|
1541 |
+
});
|
1542 |
+
|
1543 |
+
select.append( options );
|
1544 |
+
|
1545 |
+
select.on('change', function() {
|
1546 |
+
var $key = $(this).val();
|
1547 |
+
|
1548 |
+
if( ! $key ) {
|
1549 |
+
|
1550 |
+
$(this).parent().next().html( '' );
|
1551 |
+
|
1552 |
+
} else {
|
1553 |
+
|
1554 |
+
if( false != response.data.first_row[$key] ) {
|
1555 |
+
$(this).parent().next().html( response.data.first_row[$key] );
|
1556 |
+
} else {
|
1557 |
+
$(this).parent().next().html( '' );
|
1558 |
+
}
|
1559 |
+
|
1560 |
+
}
|
1561 |
+
|
1562 |
+
});
|
1563 |
+
|
1564 |
+
$('body').on('click', '.edd-import-proceed', function(e) {
|
1565 |
+
|
1566 |
+
e.preventDefault();
|
1567 |
+
|
1568 |
+
$form.append( '<div class="notice-wrap"><span class="spinner is-active"></span><div class="edd-progress"><div></div></div></div>' );
|
1569 |
+
|
1570 |
+
response.data.mapping = $form.serialize();
|
1571 |
+
|
1572 |
+
EDD_Import.process_step( 1, response.data, self );
|
1573 |
+
});
|
1574 |
+
|
1575 |
+
} else {
|
1576 |
+
|
1577 |
+
EDD_Import.error( xhr );
|
1578 |
+
|
1579 |
+
}
|
1580 |
+
|
1581 |
+
},
|
1582 |
+
|
1583 |
+
error : function( xhr ) {
|
1584 |
+
|
1585 |
+
// Something went wrong. This will display error on form
|
1586 |
+
|
1587 |
+
var response = jQuery.parseJSON( xhr.responseText );
|
1588 |
+
var import_form = $('.edd-import-form').find('.edd-progress').parent().parent();
|
1589 |
+
var notice_wrap = import_form.find('.notice-wrap');
|
1590 |
+
|
1591 |
+
import_form.find('.button-disabled').removeClass('button-disabled');
|
1592 |
+
|
1593 |
+
if ( response.data.error ) {
|
1594 |
+
|
1595 |
+
notice_wrap.html('<div class="update error"><p>' + response.data.error + '</p></div>');
|
1596 |
+
|
1597 |
+
} else {
|
1598 |
+
|
1599 |
+
notice_wrap.remove();
|
1600 |
+
|
1601 |
+
}
|
1602 |
+
},
|
1603 |
+
|
1604 |
+
process_step : function( step, import_data, self ) {
|
1605 |
+
|
1606 |
+
$.ajax({
|
1607 |
+
type: 'POST',
|
1608 |
+
url: ajaxurl,
|
1609 |
+
data: {
|
1610 |
+
form: import_data.form,
|
1611 |
+
nonce: import_data.nonce,
|
1612 |
+
class: import_data.class,
|
1613 |
+
upload: import_data.upload,
|
1614 |
+
mapping: import_data.mapping,
|
1615 |
+
action: 'edd_do_ajax_import',
|
1616 |
+
step: step,
|
1617 |
+
},
|
1618 |
+
dataType: "json",
|
1619 |
+
success: function( response ) {
|
1620 |
+
|
1621 |
+
if( 'done' == response.data.step || response.data.error ) {
|
1622 |
+
|
1623 |
+
// We need to get the actual in progress form, not all forms on the page
|
1624 |
+
var import_form = $('.edd-import-form').find('.edd-progress').parent().parent();
|
1625 |
+
var notice_wrap = import_form.find('.notice-wrap');
|
1626 |
+
|
1627 |
+
import_form.find('.button-disabled').removeClass('button-disabled');
|
1628 |
+
|
1629 |
+
if ( response.data.error ) {
|
1630 |
+
|
1631 |
+
notice_wrap.html('<div class="update error"><p>' + response.data.error + '</p></div>');
|
1632 |
+
|
1633 |
+
} else {
|
1634 |
+
|
1635 |
+
import_form.find( '.edd-import-options' ).hide();
|
1636 |
+
$('html, body').animate({
|
1637 |
+
scrollTop: import_form.parent().offset().top
|
1638 |
+
}, 500 );
|
1639 |
+
|
1640 |
+
notice_wrap.html('<div class="updated"><p>' + response.data.message + '</p></div>');
|
1641 |
+
|
1642 |
+
}
|
1643 |
+
|
1644 |
+
} else {
|
1645 |
+
|
1646 |
+
$('.edd-progress div').animate({
|
1647 |
+
width: response.data.percentage + '%',
|
1648 |
+
}, 50, function() {
|
1649 |
+
// Animation complete.
|
1650 |
+
});
|
1651 |
+
|
1652 |
+
EDD_Import.process_step( parseInt( response.data.step ), import_data, self );
|
1653 |
+
}
|
1654 |
+
|
1655 |
+
}
|
1656 |
+
}).fail(function (response) {
|
1657 |
+
if ( window.console && window.console.log ) {
|
1658 |
+
console.log( response );
|
1659 |
+
}
|
1660 |
+
});
|
1661 |
+
|
1662 |
+
}
|
1663 |
+
|
1664 |
+
};
|
1665 |
+
EDD_Import.init();
|
1666 |
+
|
1667 |
/**
|
1668 |
* Customer management screen JS
|
1669 |
*/
|
1678 |
},
|
1679 |
init : function() {
|
1680 |
this.edit_customer();
|
1681 |
+
this.add_email();
|
1682 |
this.user_search();
|
1683 |
this.remove_user();
|
1684 |
this.cancel_edit();
|
1694 |
EDD_Customer.vars.customer_card_wrap_edit_item.fadeIn().css( 'display', 'block' );
|
1695 |
});
|
1696 |
},
|
1697 |
+
add_email: function() {
|
1698 |
+
$( document.body ).on( 'click', '#add-customer-email', function(e) {
|
1699 |
+
e.preventDefault();
|
1700 |
+
var button = $(this);
|
1701 |
+
var wrapper = button.parent();
|
1702 |
+
|
1703 |
+
wrapper.parent().find('.notice-wrap').remove();
|
1704 |
+
wrapper.find('.spinner').css('visibility', 'visible');
|
1705 |
+
button.attr('disabled', true);
|
1706 |
+
|
1707 |
+
var customer_id = wrapper.find('input[name="customer-id"]').val();
|
1708 |
+
var email = wrapper.find('input[name="additional-email"]').val();
|
1709 |
+
var primary = wrapper.find('input[name="make-additional-primary"]').is(':checked');
|
1710 |
+
var nonce = wrapper.find('input[name="add_email_nonce"]').val();
|
1711 |
+
|
1712 |
+
var postData = {
|
1713 |
+
edd_action: 'customer-add-email',
|
1714 |
+
customer_id: customer_id,
|
1715 |
+
email: email,
|
1716 |
+
primary: primary,
|
1717 |
+
_wpnonce: nonce,
|
1718 |
+
};
|
1719 |
+
|
1720 |
+
$.post(ajaxurl, postData, function( response ) {
|
1721 |
+
|
1722 |
+
if ( true === response.success ) {
|
1723 |
+
window.location.href=response.redirect;
|
1724 |
+
} else {
|
1725 |
+
button.attr('disabled', false);
|
1726 |
+
wrapper.after('<div class="notice-wrap"><div class="notice notice-error inline"><p>' + response.message + '</p></div></div>');
|
1727 |
+
wrapper.find('.spinner').css('visibility', 'hidden');
|
1728 |
+
}
|
1729 |
+
|
1730 |
+
}, 'json');
|
1731 |
+
|
1732 |
+
});
|
1733 |
+
},
|
1734 |
user_search: function() {
|
1735 |
// Upon selecting a user from the dropdown, we need to update the User ID
|
1736 |
$( document.body ).on('click.eddSelectUser', '.edd_user_search_results a', function( e ) {
|
1841 |
};
|
1842 |
EDD_Customer.init();
|
1843 |
|
1844 |
+
// AJAX user search
|
1845 |
$('.edd-ajax-user-search').keyup(function() {
|
1846 |
var user_search = $(this).val();
|
1847 |
var exclude = '';
|
assets/js/admin-scripts.min.js
CHANGED
@@ -1 +1,2 @@
|
|
1 |
-
jQuery(document).ready(function(e){var t={init:function(){this.add(),this.move(),this.remove(),this.type(),this.prices(),this.files(),this.updatePrices()},clone_repeatable:function(t){var d=highest=1;return t.parent().find("tr.edd_repeatable_row").each(function(){var t=e(this).data("key");parseInt(t)>highest&&(highest=t)}),d=highest+=1,clone=t.clone(),clone.find("select").each(function(){e(this).val(t.find('select[name="'+e(this).attr("name")+'"]').val())}),clone.removeClass("edd_add_blank"),clone.attr("data-key",d),clone.find("td input, td select, textarea").val(""),clone.find("input, select, textarea").each(function(){var t=e(this).attr("name"),n=e(this).attr("id");t&&(t=t.replace(/\[(\d+)\]/,"["+parseInt(d)+"]"),e(this).attr("name",t)),"undefined"!=typeof n&&(n=n.replace(/(\d+)/,parseInt(d)),e(this).attr("id",n))}),clone.find("span.edd_price_id").each(function(){e(this).text(parseInt(d))}),clone.find("span.edd_file_id").each(function(){e(this).text(parseInt(d))}),clone.find(".edd_repeatable_default_input").each(function(){e(this).val(parseInt(d)).removeAttr("checked")}),clone.find(".search-choice").remove(),clone.find(".chosen-container").remove(),clone},add:function(){e(document.body).on("click",".submit .edd_add_repeatable",function(d){d.preventDefault();var n=e(this),a=n.parent().parent().prev("tr"),i=t.clone_repeatable(a);i.insertAfter(a).find("input, textarea, select").filter(":visible").eq(0).focus(),i.find(".edd-select-chosen").chosen({inherit_select_classes:!0,placeholder_text_single:edd_vars.one_option,placeholder_text_multiple:edd_vars.one_or_more_option}),i.find(".edd-select-chosen").css("width","100%"),i.find(".edd-select-chosen .chosen-search input").attr("placeholder",edd_vars.search_placeholder)})},move:function(){e(".edd_repeatable_table tbody").sortable({handle:".edd_draghandle",items:".edd_repeatable_row",opacity:.6,cursor:"move",axis:"y",update:function(){var t=0;e(this).find("tr").each(function(){e(this).find("input.edd_repeatable_index").each(function(){e(this).val(t)}),t++})}})},remove:function(){e(document.body).on("click",".edd_remove_repeatable",function(t){t.preventDefault();var d=e(this).parent().parent("tr"),n=d.parent().find("tr").length-1,a=e(this).data("type"),i="tr.edd_repeatable_"+a+"s";if("price"===a){var o=d.data("key");e('.edd_repeatable_condition_field option[value="'+o+'"]').remove()}if(n>1)e("input, select",d).val(""),d.fadeOut("fast").remove();else switch(a){case"price":alert(edd_vars.one_price_min);break;case"file":e("input, select",d).val("");break;default:alert(edd_vars.one_field_min)}e(i).each(function(t){e(this).find("input, select").each(function(){var d=e(this).attr("name");d=d.replace(/\[(\d+)\]/,"["+t+"]"),e(this).attr("name",d).attr("id",d)})})})},type:function(){e(document.body).on("change","#_edd_product_type",function(t){var d=e("#edd_products"),n=e("#edd_download_files"),a=e("#edd_download_limit_wrap");"bundle"===e(this).val()?(d.show(),n.hide(),a.hide()):(d.hide(),n.show(),a.show())})},prices:function(){e(document.body).on("change","#edd_variable_pricing",function(t){e(".edd_pricing_fields,.edd_repeatable_table .pricing").toggle()})},files:function(){if("undefined"==typeof wp||"1"!==edd_vars.new_media_ui)e(".edd_upload_file_button").length>0&&(window.formfield="",e(document.body).on("click",".edd_upload_file_button",function(t){if(t.preventDefault(),window.formfield=e(this).parent().prev(),window.tbframe_interval=setInterval(function(){jQuery("#TB_iframeContent").contents().find(".savesend .button").val(edd_vars.use_this_file).end().find("#insert-gallery, .wp-post-thumbnail").hide()},2e3),null!=edd_vars.post_id)var d="post_id="+edd_vars.post_id+"&";tb_show(edd_vars.add_new_download,"media-upload.php?"+d+"TB_iframe=true")}),window.edd_send_to_editor=window.send_to_editor,window.send_to_editor=function(t){window.formfield?(imgurl=e("a","<div>"+t+"</div>").attr("href"),window.formfield.val(imgurl),window.clearInterval(window.tbframe_interval),tb_remove()):window.edd_send_to_editor(t),window.send_to_editor=window.edd_send_to_editor,window.formfield="",window.imagefield=!1});else{var d;window.formfield="",e(document.body).on("click",".edd_upload_file_button",function(n){n.preventDefault();var a=e(this);return window.formfield=e(this).closest(".edd_repeatable_upload_wrapper"),d?void d.open():(d=wp.media.frames.file_frame=wp.media({frame:"post",state:"insert",title:a.data("uploader-title"),button:{text:a.data("uploader-button-text")},multiple:"0"==e(this).data("multiple")?!1:!0}),d.on("menu:render:default",function(e){var t={};e.unset("library-separator"),e.unset("gallery"),e.unset("featured-image"),e.unset("embed"),e.set(t)}),d.on("insert",function(){var e=d.state().get("selection");e.each(function(e,d){if(e=e.toJSON(),0===d)window.formfield.find(".edd_repeatable_attachment_id_field").val(e.id),window.formfield.find(".edd_repeatable_upload_field").val(e.url),window.formfield.find(".edd_repeatable_name_field").val(e.title);else{var n=window.formfield,a=t.clone_repeatable(n);a.find(".edd_repeatable_attachment_id_field").val(e.id),a.find(".edd_repeatable_upload_field").val(e.url),e.title.length>0?a.find(".edd_repeatable_name_field").val(e.title):a.find(".edd_repeatable_name_field").val(e.filename),a.insertAfter(n)}})}),void d.open())});var d;window.formfield=""}},updatePrices:function(){e("#edd_price_fields").on("keyup",".edd_variable_prices_name",function(){var t=e(this).parents("tr").data("key"),d=e(this).val(),n=e(".edd_repeatable_condition_field option[value="+t+"]");n.length>0?n.text(d):e(".edd_repeatable_condition_field").append(e("<option></option>").attr("value",t).text(d))})}};t.init();var d=e(".edd_datepicker");if(d.length>0){var n="mm/dd/yy";d.datepicker({dateFormat:n})}var a={init:function(){this.edit_address(),this.remove_download(),this.add_download(),this.new_customer(),this.recalculate_total(),this.variable_prices_check(),this.add_note(),this.remove_note(),this.resend_receipt(),this.copy_download_link()},edit_address:function(){e('select[name="edd-payment-address[0][country]"]').change(function(){var t=e(this);return data={action:"edd_get_shop_states",country:t.val(),field_name:"edd-payment-address[0][state]"},e.post(ajaxurl,data,function(t){var d=e("#edd-order-address-state-wrap select, #edd-order-address-state-wrap input");"nostates"==t?d.replaceWith('<input type="text" name="edd-payment-address[0][state]" value="" class="edd-edit-toggles medium-text"/>'):d.replaceWith(t)}),!1})},remove_download:function(){e("#edd-purchased-files").on("click",".edd-order-remove-download",function(){var t=e(document.body).find("#edd-purchased-files > .row").length;if(1===t)return alert(edd_vars.one_download_min),!1;if(confirm(edd_vars.delete_payment_download)){var d=e(this).data("key"),n=(e(".edd-payment-id").val(),e('input[name="edd-payment-details-downloads['+d+'][id]"]').val()),a=e('input[name="edd-payment-details-downloads['+d+'][price_id]"]').val(),i=e('input[name="edd-payment-details-downloads['+d+'][quantity]"]').val(),o=e('input[name="edd-payment-details-downloads['+d+'][amount]"]').val(),r=e('input[name="edd-payment-removed"]').val();r=e.parseJSON(r),r.length<1&&(r={});var s=[{id:n,price_id:a,quantity:i,amount:o,cart_index:d}];r[d]=s,e('input[name="edd-payment-removed"]').val(JSON.stringify(r)),e(this).parent().parent().parent().remove(),e("#edd-payment-downloads-changed").val(1),e(".edd-order-payment-recalc-totals").show()}return!1})},new_customer:function(){e("#edd-customer-details").on("click",".edd-payment-new-customer, .edd-payment-new-customer-cancel",function(t){t.preventDefault(),e(".customer-info").toggle(),e(".new-customer").toggle();var d=e("#edd-new-customer");e(".new-customer").is(":visible")?d.val(1):d.val(0)})},add_download:function(){e("#edd-purchased-files").on("click","#edd-order-add-download",function(t){t.preventDefault();var d=e("#edd_order_download_select"),n=e("#edd-order-download-quantity"),a=e("#edd-order-download-amount"),i=e(".edd_price_options_select option:selected"),o=d.val(),r=d.find(":selected").text(),s=n.val(),c=a.val(),l=i.val(),u=i.text();if(1>o)return!1;if(c||(c=0),c=parseFloat(c),isNaN(c))return alert(edd_vars.numeric_item_price),!1;var p=c;if("1"===edd_vars.quantities_enabled){if(isNaN(parseInt(s)))return alert(edd_vars.numeric_quantity),!1;c*=s}c=c.toFixed(edd_vars.currency_decimals);var _=c+edd_vars.currency_sign;"before"===edd_vars.currency_pos&&(_=edd_vars.currency_sign+c),u&&(r=r+" - "+u);var f=e("#edd-purchased-files div.row").length,m=e("#edd-purchased-files div.row:last").clone();m.find(".download span").html('<a href="post.php?post='+o+'&action=edit"></a>'),m.find(".download span a").text(r),m.find(".price-text").text(_),m.find(".item-quantity").text(s),m.find(".item-price").text(edd_vars.currency_sign+(c/s).toFixed(edd_vars.currency_decimals)),m.find("input.edd-payment-details-download-id").val(o),m.find("input.edd-payment-details-download-price-id").val(l),m.find("input.edd-payment-details-download-item-price").val(p),m.find("input.edd-payment-details-download-amount").val(c),m.find("input.edd-payment-details-download-quantity").val(s),m.find("input.edd-payment-details-download-has-log").val(0),m.find("input").each(function(){var t=e(this).attr("name");t=t.replace(/\[(\d+)\]/,"["+parseInt(f)+"]"),e(this).attr("name",t).attr("id",t)}),e("#edd-payment-downloads-changed").val(1),e(m).insertAfter("#edd-purchased-files div.row:last"),e(".edd-order-payment-recalc-totals").show()})},recalculate_total:function(){e("#edd-order-recalc-total").on("click",function(t){t.preventDefault();var d=0,n=e("#edd-purchased-files .row .edd-payment-details-download-amount");n.length&&n.each(function(){d+=parseFloat(e(this).val())}),e(".edd-payment-fees").length&&e(".edd-payment-fees span.fee-amount").each(function(){d+=parseFloat(e(this).data("fee"))}),e("input[name=edd-payment-total]").val(d.toFixed(edd_vars.currency_decimals))})},variable_prices_check:function(){e("#edd-purchased-files").on("change","select#edd_order_download_select",function(){var t=e(this),d=t.val();if(parseInt(d)>0){var n={action:"edd_check_for_download_price_variations",download_id:d};e.ajax({type:"POST",data:n,url:ajaxurl,success:function(d){e(".edd_price_options_select").remove(),e(d).insertAfter(t.next())}}).fail(function(e){window.console&&window.console.log&&console.log(e)})}})},add_note:function(){e("#edd-add-payment-note").on("click",function(t){t.preventDefault();var d={action:"edd_insert_payment_note",payment_id:e(this).data("payment-id"),note:e("#edd-payment-note").val()};if(d.note)e.ajax({type:"POST",data:d,url:ajaxurl,success:function(t){e("#edd-payment-notes-inner").append(t),e(".edd-no-payment-notes").hide(),e("#edd-payment-note").val("")}}).fail(function(e){window.console&&window.console.log&&console.log(e)});else{var n=e("#edd-payment-note").css("border-color");e("#edd-payment-note").css("border-color","red"),setTimeout(function(){e("#edd-payment-note").css("border-color",n)},500)}})},remove_note:function(){e(document.body).on("click",".edd-delete-payment-note",function(t){if(t.preventDefault(),confirm(edd_vars.delete_payment_note)){var d={action:"edd_delete_payment_note",payment_id:e(this).data("payment-id"),note_id:e(this).data("note-id")};return e.ajax({type:"POST",data:d,url:ajaxurl,success:function(t){return e("#edd-payment-note-"+d.note_id).remove(),e(".edd-payment-note").length||e(".edd-no-payment-notes").show(),!1}}).fail(function(e){window.console&&window.console.log&&console.log(e)}),!0}})},resend_receipt:function(){e(document.body).on("click","#edd-resend-receipt",function(e){return confirm(edd_vars.resend_receipt)})},copy_download_link:function(){e(document.body).on("click",".edd-copy-download-link",function(t){t.preventDefault();var d=e(this),n={action:"edd_get_file_download_link",payment_id:e('input[name="edd_payment_id"]').val(),download_id:d.data("download-id"),price_id:d.data("price-id")};e.ajax({type:"POST",data:n,url:ajaxurl,success:function(t){return e("#edd-download-link").dialog({width:400}).html('<textarea rows="10" cols="40" id="edd-download-link-textarea">'+t+"</textarea>"),e("#edd-download-link-textarea").focus().select(),!1}}).fail(function(e){window.console&&window.console.log&&console.log(e)})})}};a.init();var i={init:function(){this.type_select(),this.product_requirements()},type_select:function(){e("#edd-edit-discount #edd-type, #edd-add-discount #edd-type").change(function(){e(".edd-amount-description").toggle()})},product_requirements:function(){e("#products").change(function(){var t=e("#edd-discount-product-conditions");e(this).val()?t.show():t.hide()})}};i.init();var o={init:function(){this.date_options(),this.customers_export()},date_options:function(){e("#edd-graphs-date-options").change(function(){var t=e(this),d=e("#edd-date-range-options");"other"===t.val()?d.show():d.hide()})},customers_export:function(){e("#edd_customer_export_download").change(function(){var t=e(this),d=e("option:selected",t).val(),n=e("#edd_customer_export_option");if("0"===t.val()?n.show():n.hide(),0!=parseInt(d)){var a={action:"edd_check_for_download_price_variations",download_id:d,all_prices:!0},i=e(".edd_price_options_select");e.post(ajaxurl,a,function(t){i.remove(),e("#edd_customer_export_download_chosen").after(t)})}else i.remove()})}};o.init();var r={init:function(){this.general(),this.taxes(),this.emails(),this.misc()},general:function(){var t=e(".edd-color-picker");if(t.length&&t.wpColorPicker(),"undefined"==typeof wp||"1"!==edd_vars.new_media_ui){var d=e(".edd_settings_upload_button");d.length>0&&(window.formfield="",e(document.body).on("click",d,function(t){t.preventDefault(),window.formfield=e(this).parent().prev(),window.tbframe_interval=setInterval(function(){jQuery("#TB_iframeContent").contents().find(".savesend .button").val(edd_vars.use_this_file).end().find("#insert-gallery, .wp-post-thumbnail").hide()},2e3),tb_show(edd_vars.add_new_download,"media-upload.php?TB_iframe=true")}),window.edd_send_to_editor=window.send_to_editor,window.send_to_editor=function(t){window.formfield?(imgurl=e("a","<div>"+t+"</div>").attr("href"),window.formfield.val(imgurl),window.clearInterval(window.tbframe_interval),tb_remove()):window.edd_send_to_editor(t),window.send_to_editor=window.edd_send_to_editor,window.formfield="",window.imagefield=!1})}else{var n;window.formfield="",e(document.body).on("click",".edd_settings_upload_button",function(t){t.preventDefault();var d=e(this);return window.formfield=e(this).parent().prev(),n?void n.open():(n=wp.media.frames.file_frame=wp.media({frame:"post",state:"insert",title:d.data("uploader_title"),button:{text:d.data("uploader_button_text")},multiple:!1}),n.on("menu:render:default",function(e){var t={};e.unset("library-separator"),e.unset("gallery"),e.unset("featured-image"),e.unset("embed"),e.set(t)}),n.on("insert",function(){var e=n.state().get("selection");e.each(function(e,t){e=e.toJSON(),window.formfield.val(e.url)})}),void n.open())});var n;window.formfield=""}},taxes:function(){var t=e("select.edd-no-states");t.length&&t.closest("tr").hide(),e('select[name="edd_settings[base_country]"]').change(function(){var t=e(this),d=t.closest("tr");return data={action:"edd_get_shop_states",country:e(this).val(),field_name:"edd_settings[base_state]"},e.post(ajaxurl,data,function(e){"nostates"==e?d.next().hide():(d.next().show(),d.next().find("select").replaceWith(e))}),!1}),e(document.body).on("change","#edd_tax_rates select.edd-tax-country",function(){var t=e(this);return data={action:"edd_get_shop_states",country:e(this).val(),field_name:t.attr("name").replace("country","state")},e.post(ajaxurl,data,function(e){if("nostates"==e){var d='<input type="text" name="'+data.field_name+'" value=""/>';t.parent().next().find("select").replaceWith(d)}else t.parent().next().find("input,select").show(),t.parent().next().find("input,select").replaceWith(e)}),!1}),e("#edd_add_tax_rate").on("click",function(){var t=e("#edd_tax_rates tr:last"),d=t.clone(),n=t.parent().find("tr").length;return d.find("td input").not(":input[type=checkbox]").val(""),d.find('td [type="checkbox"]').attr("checked",!1),d.find("input, select").each(function(){var t=e(this).attr("name");t=t.replace(/\[(\d+)\]/,"["+parseInt(n)+"]"),e(this).attr("name",t).attr("id",t)}),d.find("label").each(function(){var t=e(this).attr("for");t=t.replace(/\[(\d+)\]/,"["+parseInt(n)+"]"),e(this).attr("for",t)}),d.insertAfter(t),!1}),e(document.body).on("click","#edd_tax_rates .edd_remove_tax_rate",function(){if(confirm(edd_vars.delete_tax_rate)){var t=e("#edd_tax_rates tr:visible"),d=t.length;2===d?(e("#edd_tax_rates select").val(""),e('#edd_tax_rates input[type="text"]').val(""),e('#edd_tax_rates input[type="number"]').val(""),e('#edd_tax_rates input[type="checkbox"]').attr("checked",!1)):e(this).closest("tr").remove(),e("#edd_tax_rates tr").each(function(t){e(this).children().find("input, select").each(function(){var d=e(this).attr("name");d=d.replace(/\[(\d+)\]/,"["+(t-1)+"]"),e(this).attr("name",d).attr("id",d)})})}return!1})},emails:function(){var t=e("#email-preview-wrap");if(t.length){var d=e("#email-preview");t.colorbox({inline:!0,href:d,width:"80%",height:"auto"})}},misc:function(){var t=e('select[name="edd_settings[download_method]"]'),d=t.parent().parent().next();"direct"==t.val()&&(d.hide(),d.find("input").prop("checked",!1)),t.on("change",function(){"direct"==e(this).val()?(d.hide(),d.find("input").prop("checked",!1)):d.show()})}};r.init(),e(".download_page_edd-payment-history .row-actions .delete a, a.edd-delete-payment").on("click",function(){return confirm(edd_vars.delete_payment)?!0:!1}),e("#the-list").on("click",".editinline",function(){var t=e(this).closest("tr").attr("id");t=t.replace("post-","");var d=e("#post-"+t),n=d.find(".column-price .downloadprice-"+t).val();n!=e("#post-"+t+".column-price .downloadprice-"+t).val()?e(".regprice","#edd-download-data").val(n).attr("disabled",!1):e(".regprice","#edd-download-data").val(edd_vars.quick_edit_warning).attr("disabled","disabled")}),e(document.body).on("click","#bulk_edit",function(){var t=e("#bulk-edit"),d=new Array;t.find("#bulk-titles").children().each(function(){d.push(e(this).attr("id").replace(/^(ttle)/i,""))});var n=e('#edd-download-data input[name="_edd_regprice"]').val(),a={action:"edd_save_bulk_edit",edd_bulk_nonce:d,post_ids:d,price:n};e.post(ajaxurl,a)}),e(".edd-select-chosen").chosen({inherit_select_classes:!0,placeholder_text_single:edd_vars.one_option,placeholder_text_multiple:edd_vars.one_or_more_option}),e(".edd-select-chosen .chosen-search input").attr("placeholder",edd_vars.search_placeholder),e(".chosen-choices").on("click",function(){e(this).children("li").children("input").attr("placeholder",edd_vars.type_to_search)});var s,c=342;e(document.body).on("keyup",".edd-select.chosen-container .chosen-search input, .edd-select.chosen-container .search-field input",function(t){var d=e(this).val(),n=e(this).closest(".edd-select-chosen"),a=n.attr("id").replace("_chosen",""),i=n.hasClass("no-bundles"),o=t.which,r="edd_download_search";n.prev().data("search-type")&&(r="edd_"+n.prev().data("search-type")+"_search"),d.length<=3&&"edd_download_search"==r||16==o||13==o||91==o||17==o||37==o||38==o||39==o||40==o||(clearTimeout(s),s=setTimeout(function(){e.ajax({type:"GET",url:ajaxurl,data:{action:r,s:d,current_id:edd_vars.post_id,no_bundles:i},dataType:"json",beforeSend:function(){e("ul.chosen-results").empty()},success:function(t){e("#"+a+" option:not(:selected)").remove(),e.each(t,function(t,d){e("#"+a+' option[value="'+d.id+'"]').length||e("#"+a).prepend('<option value="'+d.id+'">'+d.name+"</option>")}),e(".edd-select-chosen").trigger("chosen:updated"),e("#"+a).next().find("input").val(d)}}).fail(function(e){window.console&&window.console.log&&console.log(e)}).done(function(e){})},c))}),e("#post").on("click",".edd-thickbox",function(){e(".edd-select-chosen","#choose-download").css("width","100%")});var l={init:function(){this.revoke_api_key(),this.regenerate_api_key(),this.create_api_key(),this.recount_stats()},revoke_api_key:function(){e(document.body).on("click",".edd-revoke-api-key",function(e){return confirm(edd_vars.revoke_api_key)})},regenerate_api_key:function(){e(document.body).on("click",".edd-regenerate-api-key",function(e){return confirm(edd_vars.regenerate_api_key)})},create_api_key:function(){e(document.body).on("submit","#api-key-generate-form",function(t){var d=e('input[type="text"][name="user_id"]');d.css("border-color","#ddd");var n=d.val();return n.length<1||0==n?(d.css("border-color","#ff0000"),!1):void 0})},recount_stats:function(){e("body").on("change","#recount-stats-type",function(){var t=e("#edd-tools-recount-form"),d=e("option:selected",this).data("type"),n=e("#recount-stats-submit"),a=e("#tools-product-dropdown");if(t.find(".notice-wrap").remove(),n.removeClass("button-disabled").attr("disabled",!1),a.hide(),e(".edd-recount-stats-descriptions span").hide(),"recount-download"===d)a.show(),a.find(".edd-select-chosen").css("width","auto");else if("reset-stats"===d){t.append('<div class="notice-wrap"></div>');var i=t.find(".notice-wrap");i.html('<div class="notice notice-warning"><p><input type="checkbox" id="confirm-reset" name="confirm_reset_store" value="1" /> <label for="confirm-reset">'+edd_vars.reset_stats_warn+"</label></p></div>"),e("#recount-stats-submit").addClass("button-disabled").attr("disabled","disabled")}else a.hide(),a.val(0);e("#"+d).show()}),e("body").on("change","#confirm-reset",function(){var t=e(this).is(":checked");t?e("#recount-stats-submit").removeClass("button-disabled").removeAttr("disabled"):e("#recount-stats-submit").addClass("button-disabled").attr("disabled","disabled")}),e("#edd-tools-recount-form").submit(function(t){var d=e("#recount-stats-type").val(),n=e(this),a=e("option:selected",this).data("type");if("reset-stats"===a){var i=e("#confirm-reset").is(":checked");if(i)return!0;r=!0}n.find(".notice-wrap").remove(),n.append('<div class="notice-wrap"></div>');var o=n.find(".notice-wrap"),r=!1;if((null===d||0===d)&&(o.html('<div class="updated error"><p>'+edd_vars.batch_export_no_class+"</p></div>"),r=!0),"recount-download"===a){var s=e('select[name="download_id"]').val();0==s&&(o.html('<div class="updated error"><p>'+edd_vars.batch_export_no_reqs+"</p></div>"),r=!0)}return r?(n.find(".button-disabled").removeClass("button-disabled"),!1):void 0})}};l.init();var u={init:function(){this.submit(),this.dismiss_message()},submit:function(){var t=this;e(document.body).on("submit",".edd-export-form",function(d){d.preventDefault();var n=e(this).find('input[type="submit"]');if(!n.hasClass("button-disabled")){var a=e(this).serialize();n.addClass("button-disabled"),e(this).find(".notice-wrap").remove(),e(this).append('<div class="notice-wrap"><span class="spinner is-active"></span><div class="edd-progress"><div></div></div></div>'),t.process_step(1,a,t)}})},process_step:function(t,d,n){e.ajax({type:"POST",url:ajaxurl,data:{form:d,action:"edd_do_ajax_export",step:t},dataType:"json",success:function(t){if("done"==t.step||t.error||t.success){var a=e(".edd-export-form").find(".edd-progress").parent().parent(),i=a.find(".notice-wrap");if(a.find(".button-disabled").removeClass("button-disabled"),t.error){var o=t.message;i.html('<div class="updated error"><p>'+o+"</p></div>")}else if(t.success){var r=t.message;i.html('<div id="edd-batch-success" class="updated notice is-dismissible"><p>'+r+'<span class="notice-dismiss"></span></p></div>')}else i.remove(),window.location=t.url}else e(".edd-progress div").animate({width:t.percentage+"%"},50,function(){}),n.process_step(parseInt(t.step),d,n)}}).fail(function(e){window.console&&window.console.log&&console.log(e)})},dismiss_message:function(){e("body").on("click","#edd-batch-success .notice-dismiss",function(){e("#edd-batch-success").parent().slideUp("fast")})}};u.init();var p={vars:{customer_card_wrap_editable:e(".edd-customer-card-wrapper .editable"),customer_card_wrap_edit_item:e(".edd-customer-card-wrapper .edit-item"),user_id:e('input[name="customerinfo[user_id]"]'),state_input:e(':input[name="customerinfo[state]"]'),note:e("#customer-note")},init:function(){this.edit_customer(),this.user_search(),this.remove_user(),this.cancel_edit(),this.change_country(),this.add_note(),this.delete_checked()},edit_customer:function(){e(document.body).on("click","#edit-customer",function(e){e.preventDefault(),p.vars.customer_card_wrap_editable.hide(),p.vars.customer_card_wrap_edit_item.fadeIn().css("display","block")})},user_search:function(){e(document.body).on("click.eddSelectUser",".edd_user_search_results a",function(t){t.preventDefault();var d=e(this).data("userid");p.vars.user_id.val(d)})},remove_user:function(){e(document.body).on("click","#disconnect-customer",function(t){t.preventDefault();var d=e('input[name="customerinfo[id]"]').val(),n={edd_action:"disconnect-userid",customer_id:d,_wpnonce:e("#edit-customer-info #_wpnonce").val()};e.post(ajaxurl,n,function(e){window.location.href=window.location.href},"json")})},cancel_edit:function(){e(document.body).on("click","#edd-edit-customer-cancel",function(t){t.preventDefault(),p.vars.customer_card_wrap_edit_item.hide(),p.vars.customer_card_wrap_editable.show(),e(".edd_user_search_results").html("")})},change_country:function(){e('select[name="customerinfo[country]"]').change(function(){var t=e(this);return data={action:"edd_get_shop_states",country:t.val(),field_name:"customerinfo[state]"},e.post(ajaxurl,data,function(e){"nostates"==e?p.vars.state_input.replaceWith('<input type="text" name="'+data.field_name+'" value="" class="edd-edit-toggles medium-text"/>'):p.vars.state_input.replaceWith(e)}),!1})},add_note:function(){e(document.body).on("click","#add-customer-note",function(t){t.preventDefault();var d={edd_action:"add-customer-note",customer_id:e("#customer-id").val(),customer_note:p.vars.note.val(),add_customer_note_nonce:e("#add_customer_note_nonce").val()};if(d.customer_note)e.ajax({type:"POST",data:d,url:ajaxurl,success:function(t){e("#edd-customer-notes").prepend(t),e(".edd-no-customer-notes").hide(),p.vars.note.val("")}}).fail(function(e){window.console&&window.console.log&&console.log(e)});else{var n=p.vars.note.css("border-color");p.vars.note.css("border-color","red"),setTimeout(function(){p.vars.note.css("border-color",n)},500)}})},delete_checked:function(){e("#edd-customer-delete-confirm").change(function(){var t=e("#edd-customer-delete-records"),d=e("#edd-delete-customer");e(this).prop("checked")?(t.attr("disabled",!1),d.attr("disabled",!1)):(t.attr("disabled",!0),t.prop("checked",!1),d.attr("disabled",!0))})}};p.init(),e(".edd-ajax-user-search").keyup(function(){var t=e(this).val(),d="";e(this).data("exclude")&&(d=e(this).data("exclude")),e(".edd-ajax").show(),data={action:"edd_search_users",user_name:t,exclude:d},document.body.style.cursor="wait",e.ajax({type:"POST",data:data,dataType:"json",url:ajaxurl,success:function(t){e(".edd-ajax").hide(),e(".edd_user_search_results").removeClass("hidden"),e(".edd_user_search_results span").html(""),e(t.results).appendTo(".edd_user_search_results span"),document.body.style.cursor="default"}})}),e(document.body).on("click.eddSelectUser",".edd_user_search_results span a",function(t){t.preventDefault();var d=e(this).data("login");e(".edd-ajax-user-search").val(d),e(".edd_user_search_results").addClass("hidden"),e(".edd_user_search_results span").html("")}),e(document.body).on("click.eddCancelUserSearch",".edd_user_search_results a.edd-ajax-user-cancel",function(t){t.preventDefault(),e(".edd-ajax-user-search").val(""),e(".edd_user_search_results").addClass("hidden"),e(".edd_user_search_results span").html("")}),e("#edd_dashboard_sales").length&&e.ajax({type:"GET",data:{action:"edd_load_dashboard_widget"},url:ajaxurl,success:function(t){e("#edd_dashboard_sales .inside").html(t)}}),e(document).on("keydown",".customer-note-input",function(t){13==t.keyCode&&(t.metaKey||t.ctrlKey)&&e("#add-customer-note").click()})});var eddFormatCurrency=function(e){var t=parseFloat(e),d=edd_vars.currency,n=edd_vars.currency_decimals;return t.toLocaleString(d,{style:"currency",currency:d,minimumFractionDigits:n,maximumFractionDigits:n})},eddFormatNumber=function(e){var t=parseFloat(e),d=edd_vars.currency;edd_vars.currency_decimals;return t.toLocaleString(d,{style:"decimal",minimumFractionDigits:0,maximumFractionDigits:0})},eddLabelFormatter=function(e,t){return'<div style="font-size:12px; text-align:center; padding:2px">'+e+"</div>"},eddLegendFormatterSales=function(e,t){var d=e.toLowerCase().replace(/\s/g,"-"),n='<div class="edd-legend-color" style="background-color: '+t.color+'"></div>',a='<div class="edd-pie-legend-item">'+e+": "+Math.round(t.percent)+"% ("+eddFormatNumber(t.data[0][1])+")</div>",i='<div id="'+t.edd_vars.id+d+'" class="edd-legend-item-wrapper">'+n+a+"</div>";return jQuery("#edd-pie-legend-"+t.edd_vars.id).append(i),i},eddLegendFormatterEarnings=function(e,t){var d=e.toLowerCase().replace(/\s/g,"-"),n='<div class="edd-legend-color" style="background-color: '+t.color+'"></div>',a='<div class="edd-pie-legend-item">'+e+": "+Math.round(t.percent)+"% ("+eddFormatCurrency(t.data[0][1])+")</div>",i='<div id="'+t.edd_vars.id+d+'" class="edd-legend-item-wrapper">'+n+a+"</div>";return jQuery("#edd-pie-legend-"+t.edd_vars.id).append(i),i};
|
|
1 |
+
jQuery(document).ready(function(a){a(".edd-help-tip").tooltip({content:function(){return a(this).prop("title")},tooltipClass:"edd-ui-tooltip",position:{my:"center top",at:"center bottom+10",collision:"flipfit"},hide:{duration:200},show:{duration:200}});var b={init:function(){this.add(),this.move(),this.remove(),this.type(),this.prices(),this.files(),this.updatePrices()},clone_repeatable:function(b){var c=highest=1;return b.parent().find("tr.edd_repeatable_row").each(function(){var b=a(this).data("key");parseInt(b)>highest&&(highest=b)}),c=highest+=1,clone=b.clone(),clone.find("select").each(function(){a(this).val(b.find('select[name="'+a(this).attr("name")+'"]').val())}),clone.removeClass("edd_add_blank"),clone.attr("data-key",c),clone.find("td input, td select, textarea").val(""),clone.find("input, select, textarea").each(function(){var b=a(this).attr("name"),d=a(this).attr("id");b&&(b=b.replace(/\[(\d+)\]/,"["+parseInt(c)+"]"),a(this).attr("name",b)),"undefined"!=typeof d&&(d=d.replace(/(\d+)/,parseInt(c)),a(this).attr("id",d))}),clone.find("span.edd_price_id").each(function(){a(this).text(parseInt(c))}),clone.find("span.edd_file_id").each(function(){a(this).text(parseInt(c))}),clone.find(".edd_repeatable_default_input").each(function(){a(this).val(parseInt(c)).removeAttr("checked")}),clone.find(".search-choice").remove(),clone.find(".chosen-container").remove(),clone},add:function(){a(document.body).on("click",".submit .edd_add_repeatable",function(c){c.preventDefault();var d=a(this),e=d.parent().parent().prev("tr"),f=b.clone_repeatable(e);f.insertAfter(e).find("input, textarea, select").filter(":visible").eq(0).focus(),f.find(".edd-select-chosen").chosen({inherit_select_classes:!0,placeholder_text_single:edd_vars.one_option,placeholder_text_multiple:edd_vars.one_or_more_option}),f.find(".edd-select-chosen").css("width","100%"),f.find(".edd-select-chosen .chosen-search input").attr("placeholder",edd_vars.search_placeholder)})},move:function(){a(".edd_repeatable_table tbody").sortable({handle:".edd_draghandle",items:".edd_repeatable_row",opacity:.6,cursor:"move",axis:"y",update:function(){var b=0;a(this).find("tr").each(function(){a(this).find("input.edd_repeatable_index").each(function(){a(this).val(b)}),b++})}})},remove:function(){a(document.body).on("click",".edd_remove_repeatable",function(b){b.preventDefault();var g,h,i,c=a(this).parent().parent("tr"),d=c.parent().find("tr").length-1,e=a(this).data("type"),f="tr.edd_repeatable_"+e+"s";if(g=a(this).is(".ui-sortable tr:first-child .edd_remove_repeatable:first-child")?c.next("tr"):c.prev("tr"),h=g.find("select, input, textarea, button").filter(":visible"),i=h.eq(0),"price"===e){var j=c.data("key");a('.edd_repeatable_condition_field option[value="'+j+'"]').remove()}if(d>1)a("input, select",c).val(""),c.fadeOut("fast").remove(),i.focus();else switch(e){case"price":alert(edd_vars.one_price_min);break;case"file":a("input, select",c).val("");break;default:alert(edd_vars.one_field_min)}a(f).each(function(b){a(this).find("input, select").each(function(){var c=a(this).attr("name");c=c.replace(/\[(\d+)\]/,"["+b+"]"),a(this).attr("name",c).attr("id",c)})})})},type:function(){a(document.body).on("change","#_edd_product_type",function(b){var c=a("#edd_products"),d=a("#edd_download_files"),e=a("#edd_download_limit_wrap");"bundle"===a(this).val()?(c.show(),d.hide(),e.hide()):(c.hide(),d.show(),e.show())})},prices:function(){a(document.body).on("change","#edd_variable_pricing",function(b){a(".edd_pricing_fields,.edd_repeatable_table .pricing").toggle()})},files:function(){if("undefined"==typeof wp||"1"!==edd_vars.new_media_ui)a(".edd_upload_file_button").length>0&&(window.formfield="",a(document.body).on("click",".edd_upload_file_button",function(b){if(b.preventDefault(),window.formfield=a(this).parent().prev(),window.tbframe_interval=setInterval(function(){jQuery("#TB_iframeContent").contents().find(".savesend .button").val(edd_vars.use_this_file).end().find("#insert-gallery, .wp-post-thumbnail").hide()},2e3),null!=edd_vars.post_id)var c="post_id="+edd_vars.post_id+"&";tb_show(edd_vars.add_new_download,"media-upload.php?"+c+"TB_iframe=true")}),window.edd_send_to_editor=window.send_to_editor,window.send_to_editor=function(b){window.formfield?(imgurl=a("a","<div>"+b+"</div>").attr("href"),window.formfield.val(imgurl),window.clearInterval(window.tbframe_interval),tb_remove()):window.edd_send_to_editor(b),window.send_to_editor=window.edd_send_to_editor,window.formfield="",window.imagefield=!1});else{var c;window.formfield="",a(document.body).on("click",".edd_upload_file_button",function(d){d.preventDefault();var e=a(this);return window.formfield=a(this).closest(".edd_repeatable_upload_wrapper"),c?void c.open():(c=wp.media.frames.file_frame=wp.media({frame:"post",state:"insert",title:e.data("uploader-title"),button:{text:e.data("uploader-button-text")},multiple:"0"==a(this).data("multiple")?!1:!0}),c.on("menu:render:default",function(a){var b={};a.unset("library-separator"),a.unset("gallery"),a.unset("featured-image"),a.unset("embed"),a.set(b)}),c.on("insert",function(){var a=c.state().get("selection");a.each(function(a,c){if(a=a.toJSON(),0===c)window.formfield.find(".edd_repeatable_attachment_id_field").val(a.id),window.formfield.find(".edd_repeatable_upload_field").val(a.url),window.formfield.find(".edd_repeatable_name_field").val(a.title);else{var d=window.formfield,e=b.clone_repeatable(d);e.find(".edd_repeatable_attachment_id_field").val(a.id),e.find(".edd_repeatable_upload_field").val(a.url),a.title.length>0?e.find(".edd_repeatable_name_field").val(a.title):e.find(".edd_repeatable_name_field").val(a.filename),e.insertAfter(d)}})}),void c.open())});var c;window.formfield=""}},updatePrices:function(){a("#edd_price_fields").on("keyup",".edd_variable_prices_name",function(){var b=a(this).parents("tr").data("key"),c=a(this).val(),d=a(".edd_repeatable_condition_field option[value="+b+"]");d.length>0?d.text(c):a(".edd_repeatable_condition_field").append(a("<option></option>").attr("value",b).text(c))})}};b.init();var c=a(".edd_datepicker");if(c.length>0){var d="mm/dd/yy";c.datepicker({dateFormat:d})}var e={init:function(){this.edit_address(),this.remove_download(),this.add_download(),this.new_customer(),this.recalculate_total(),this.variable_prices_check(),this.add_note(),this.remove_note(),this.resend_receipt(),this.copy_download_link()},edit_address:function(){a('select[name="edd-payment-address[0][country]"]').change(function(){var b=a(this);return data={action:"edd_get_shop_states",country:b.val(),field_name:"edd-payment-address[0][state]"},a.post(ajaxurl,data,function(b){var c=a("#edd-order-address-state-wrap select, #edd-order-address-state-wrap input");"nostates"==b?c.replaceWith('<input type="text" name="edd-payment-address[0][state]" value="" class="edd-edit-toggles medium-text"/>'):c.replaceWith(b)}),!1})},remove_download:function(){a("#edd-purchased-files").on("click",".edd-order-remove-download",function(){var b=a(document.body).find("#edd-purchased-files > .row").length;if(1===b)return alert(edd_vars.one_download_min),!1;if(confirm(edd_vars.delete_payment_download)){var c=a(this).data("key"),e=(a(".edd-payment-id").val(),a('input[name="edd-payment-details-downloads['+c+'][id]"]').val()),f=a('input[name="edd-payment-details-downloads['+c+'][price_id]"]').val(),g=a('input[name="edd-payment-details-downloads['+c+'][quantity]"]').val(),h=a('input[name="edd-payment-details-downloads['+c+'][amount]"]').val(),i=a('input[name="edd-payment-removed"]').val();i=a.parseJSON(i),i.length<1&&(i={});var j=[{id:e,price_id:f,quantity:g,amount:h,cart_index:c}];i[c]=j,a('input[name="edd-payment-removed"]').val(JSON.stringify(i)),a(this).parent().parent().parent().remove(),a("#edd-payment-downloads-changed").val(1),a(".edd-order-payment-recalc-totals").show()}return!1})},new_customer:function(){a("#edd-customer-details").on("click",".edd-payment-new-customer, .edd-payment-new-customer-cancel",function(b){b.preventDefault(),a(".customer-info").toggle(),a(".new-customer").toggle();var c=a("#edd-new-customer");a(".new-customer").is(":visible")?c.val(1):c.val(0)})},add_download:function(){a("#edd-purchased-files").on("click","#edd-order-add-download",function(b){b.preventDefault();var c=a("#edd_order_download_select"),d=a("#edd-order-download-quantity"),e=a("#edd-order-download-amount"),f=a(".edd_price_options_select option:selected"),g=c.val(),h=c.find(":selected").text(),i=d.val(),j=e.val(),k=f.val(),l=f.text();if(1>g)return!1;if(j||(j=0),j=parseFloat(j),isNaN(j))return alert(edd_vars.numeric_item_price),!1;var m=j;if("1"===edd_vars.quantities_enabled){if(isNaN(parseInt(i)))return alert(edd_vars.numeric_quantity),!1;j*=i}j=j.toFixed(edd_vars.currency_decimals);var n=j+edd_vars.currency_sign;"before"===edd_vars.currency_pos&&(n=edd_vars.currency_sign+j),l&&(h=h+" - "+l);var o=a("#edd-purchased-files div.row").length,p=a("#edd-purchased-files div.row:last").clone();p.find(".download span").html('<a href="post.php?post='+g+'&action=edit"></a>'),p.find(".download span a").text(h),p.find(".price-text").text(n),p.find(".item-quantity").text(i),p.find(".item-price").text(edd_vars.currency_sign+(j/i).toFixed(edd_vars.currency_decimals)),p.find("input.edd-payment-details-download-id").val(g),p.find("input.edd-payment-details-download-price-id").val(k),p.find("input.edd-payment-details-download-item-price").val(m),p.find("input.edd-payment-details-download-amount").val(j),p.find("input.edd-payment-details-download-quantity").val(i),p.find("input.edd-payment-details-download-has-log").val(0),p.find("input").each(function(){var b=a(this).attr("name");b=b.replace(/\[(\d+)\]/,"["+parseInt(o)+"]"),a(this).attr("name",b).attr("id",b)}),a("#edd-payment-downloads-changed").val(1),a(p).insertAfter("#edd-purchased-files div.row:last"),a(".edd-order-payment-recalc-totals").show()})},recalculate_total:function(){a("#edd-order-recalc-total").on("click",function(b){b.preventDefault();var c=0,d=a("#edd-purchased-files .row .edd-payment-details-download-amount");d.length&&d.each(function(){c+=parseFloat(a(this).val())}),a(".edd-payment-fees").length&&a(".edd-payment-fees span.fee-amount").each(function(){c+=parseFloat(a(this).data("fee"))}),a("input[name=edd-payment-total]").val(c.toFixed(edd_vars.currency_decimals))})},variable_prices_check:function(){a("#edd-purchased-files").on("change","select#edd_order_download_select",function(){var b=a(this),c=b.val();if(parseInt(c)>0){var d={action:"edd_check_for_download_price_variations",download_id:c};a.ajax({type:"POST",data:d,url:ajaxurl,success:function(c){a(".edd_price_options_select").remove(),a(c).insertAfter(b.next())}}).fail(function(a){window.console&&window.console.log&&console.log(a)})}})},add_note:function(){a("#edd-add-payment-note").on("click",function(b){b.preventDefault();var c={action:"edd_insert_payment_note",payment_id:a(this).data("payment-id"),note:a("#edd-payment-note").val()};if(c.note)a.ajax({type:"POST",data:c,url:ajaxurl,success:function(b){a("#edd-payment-notes-inner").append(b),a(".edd-no-payment-notes").hide(),a("#edd-payment-note").val("")}}).fail(function(a){window.console&&window.console.log&&console.log(a)});else{var d=a("#edd-payment-note").css("border-color");a("#edd-payment-note").css("border-color","red"),setTimeout(function(){a("#edd-payment-note").css("border-color",d)},500)}})},remove_note:function(){a(document.body).on("click",".edd-delete-payment-note",function(b){if(b.preventDefault(),confirm(edd_vars.delete_payment_note)){var c={action:"edd_delete_payment_note",payment_id:a(this).data("payment-id"),note_id:a(this).data("note-id")};return a.ajax({type:"POST",data:c,url:ajaxurl,success:function(b){return a("#edd-payment-note-"+c.note_id).remove(),a(".edd-payment-note").length||a(".edd-no-payment-notes").show(),!1}}).fail(function(a){window.console&&window.console.log&&console.log(a)}),!0}})},resend_receipt:function(){a(document.body).on("click","#edd-resend-receipt",function(a){return confirm(edd_vars.resend_receipt)})},copy_download_link:function(){a(document.body).on("click",".edd-copy-download-link",function(b){b.preventDefault();var c=a(this),d={action:"edd_get_file_download_link",payment_id:a('input[name="edd_payment_id"]').val(),download_id:c.data("download-id"),price_id:c.data("price-id")};a.ajax({type:"POST",data:d,url:ajaxurl,success:function(b){return a("#edd-download-link").dialog({width:400}).html('<textarea rows="10" cols="40" id="edd-download-link-textarea">'+b+"</textarea>"),a("#edd-download-link-textarea").focus().select(),!1}}).fail(function(a){window.console&&window.console.log&&console.log(a)})})}};e.init();var f={init:function(){this.type_select(),this.product_requirements()},type_select:function(){a("#edd-edit-discount #edd-type, #edd-add-discount #edd-type").change(function(){a(".edd-amount-description").toggle()})},product_requirements:function(){a("#products").change(function(){var b=a("#edd-discount-product-conditions");a(this).val()?b.show():b.hide()})}};f.init();var g={init:function(){this.date_options(),this.customers_export()},date_options:function(){a("#edd-graphs-date-options").change(function(){var b=a(this),c=a("#edd-date-range-options");"other"===b.val()?c.show():c.hide()})},customers_export:function(){a("#edd_customer_export_download").change(function(){var b=a(this),c=a("option:selected",b).val(),d=a("#edd_customer_export_option");if("0"===b.val()?d.show():d.hide(),0!=parseInt(c)){var e={action:"edd_check_for_download_price_variations",download_id:c,all_prices:!0},f=a(".edd_price_options_select");a.post(ajaxurl,e,function(b){f.remove(),a("#edd_customer_export_download_chosen").after(b)})}else f.remove()})}};g.init();var h={init:function(){this.general(),this.taxes(),this.emails(),this.misc()},general:function(){var b=a(".edd-color-picker");if(b.length&&b.wpColorPicker(),"undefined"==typeof wp||"1"!==edd_vars.new_media_ui){var c=a(".edd_settings_upload_button");c.length>0&&(window.formfield="",a(document.body).on("click",c,function(b){b.preventDefault(),window.formfield=a(this).parent().prev(),window.tbframe_interval=setInterval(function(){jQuery("#TB_iframeContent").contents().find(".savesend .button").val(edd_vars.use_this_file).end().find("#insert-gallery, .wp-post-thumbnail").hide()},2e3),tb_show(edd_vars.add_new_download,"media-upload.php?TB_iframe=true")}),window.edd_send_to_editor=window.send_to_editor,window.send_to_editor=function(b){window.formfield?(imgurl=a("a","<div>"+b+"</div>").attr("href"),window.formfield.val(imgurl),window.clearInterval(window.tbframe_interval),tb_remove()):window.edd_send_to_editor(b),window.send_to_editor=window.edd_send_to_editor,window.formfield="",window.imagefield=!1})}else{var d;window.formfield="",a(document.body).on("click",".edd_settings_upload_button",function(b){b.preventDefault();var c=a(this);return window.formfield=a(this).parent().prev(),d?void d.open():(d=wp.media.frames.file_frame=wp.media({frame:"post",state:"insert",title:c.data("uploader_title"),button:{text:c.data("uploader_button_text")},multiple:!1}),d.on("menu:render:default",function(a){var b={};a.unset("library-separator"),a.unset("gallery"),a.unset("featured-image"),a.unset("embed"),a.set(b)}),d.on("insert",function(){var a=d.state().get("selection");a.each(function(a,b){a=a.toJSON(),window.formfield.val(a.url)})}),void d.open())});var d;window.formfield=""}},taxes:function(){var b=a("select.edd-no-states");b.length&&b.closest("tr").hide(),a('select[name="edd_settings[base_country]"]').change(function(){var b=a(this),c=b.closest("tr");return data={action:"edd_get_shop_states",country:a(this).val(),field_name:"edd_settings[base_state]"},a.post(ajaxurl,data,function(a){"nostates"==a?c.next().hide():(c.next().show(),c.next().find("select").replaceWith(a))}),!1}),a(document.body).on("change","#edd_tax_rates select.edd-tax-country",function(){var b=a(this);return data={action:"edd_get_shop_states",country:a(this).val(),field_name:b.attr("name").replace("country","state")},a.post(ajaxurl,data,function(a){if("nostates"==a){var c='<input type="text" name="'+data.field_name+'" value=""/>';b.parent().next().find("select").replaceWith(c)}else b.parent().next().find("input,select").show(),b.parent().next().find("input,select").replaceWith(a)}),!1}),a("#edd_add_tax_rate").on("click",function(){var b=a("#edd_tax_rates tr:last"),c=b.clone(),d=b.parent().find("tr").length;return c.find("td input").not(":input[type=checkbox]").val(""),c.find('td [type="checkbox"]').attr("checked",!1),c.find("input, select").each(function(){var b=a(this).attr("name");b=b.replace(/\[(\d+)\]/,"["+parseInt(d)+"]"),a(this).attr("name",b).attr("id",b)}),c.find("label").each(function(){var b=a(this).attr("for");b=b.replace(/\[(\d+)\]/,"["+parseInt(d)+"]"),a(this).attr("for",b)}),c.insertAfter(b),!1}),a(document.body).on("click","#edd_tax_rates .edd_remove_tax_rate",function(){if(confirm(edd_vars.delete_tax_rate)){var b=a("#edd_tax_rates tr:visible"),c=b.length;2===c?(a("#edd_tax_rates select").val(""),a('#edd_tax_rates input[type="text"]').val(""),a('#edd_tax_rates input[type="number"]').val(""),a('#edd_tax_rates input[type="checkbox"]').attr("checked",!1)):a(this).closest("tr").remove(),a("#edd_tax_rates tr").each(function(b){a(this).children().find("input, select").each(function(){var c=a(this).attr("name");c=c.replace(/\[(\d+)\]/,"["+(b-1)+"]"),a(this).attr("name",c).attr("id",c)})})}return!1})},emails:function(){var b=a("#email-preview-wrap");if(b.length){var c=a("#email-preview");b.colorbox({inline:!0,href:c,width:"80%",height:"auto"})}},misc:function(){var b=a('select[name="edd_settings[download_method]"]'),c=b.parent().parent().next();"direct"==b.val()&&(c.hide(),c.find("input").prop("checked",!1)),b.on("change",function(){"direct"==a(this).val()?(c.hide(),c.find("input").prop("checked",!1)):c.show()})}};h.init(),a(".download_page_edd-payment-history .row-actions .delete a, a.edd-delete-payment").on("click",function(){return confirm(edd_vars.delete_payment)?!0:!1}),a("#the-list").on("click",".editinline",function(){var b=a(this).closest("tr").attr("id");b=b.replace("post-","");var c=a("#post-"+b),d=c.find(".column-price .downloadprice-"+b).val();d!=a("#post-"+b+".column-price .downloadprice-"+b).val()?a(".regprice","#edd-download-data").val(d).attr("disabled",!1):a(".regprice","#edd-download-data").val(edd_vars.quick_edit_warning).attr("disabled","disabled")}),a(document.body).on("click","#bulk_edit",function(){var b=a("#bulk-edit"),c=new Array;b.find("#bulk-titles").children().each(function(){c.push(a(this).attr("id").replace(/^(ttle)/i,""))});var d=a('#edd-download-data input[name="_edd_regprice"]').val(),e={action:"edd_save_bulk_edit",edd_bulk_nonce:c,post_ids:c,price:d};a.post(ajaxurl,e)}),a(".edd-select-chosen").chosen({inherit_select_classes:!0,placeholder_text_single:edd_vars.one_option,placeholder_text_multiple:edd_vars.one_or_more_option}),a(".edd-select-chosen .chosen-search input").attr("placeholder",edd_vars.search_placeholder),a(".chosen-choices").on("click",function(){a(this).children("li").children("input").attr("placeholder",edd_vars.type_to_search)});var i,j=342;a(document.body).on("keyup",".edd-select.chosen-container .chosen-search input, .edd-select.chosen-container .search-field input",function(b){var c=a(this).val(),d=a(this).closest(".edd-select-chosen"),e=d.attr("id").replace("_chosen",""),f=d.hasClass("no-bundles"),g=b.which,h="edd_download_search";d.prev().data("search-type")&&(h="edd_"+d.prev().data("search-type")+"_search"),c.length<=3&&"edd_download_search"==h||16==g||13==g||91==g||17==g||37==g||38==g||39==g||40==g||(clearTimeout(i),i=setTimeout(function(){a.ajax({type:"GET",url:ajaxurl,data:{action:h,s:c,no_bundles:f},dataType:"json",beforeSend:function(){a("ul.chosen-results").empty()},success:function(b){a("#"+e+" option:not(:selected)").remove(),a.each(b,function(b,c){a("#"+e+' option[value="'+c.id+'"]').length||a("#"+e).prepend('<option value="'+c.id+'">'+c.name+"</option>")}),a(".edd-select-chosen").trigger("chosen:updated"),a("#"+e).next().find("input").val(c)}}).fail(function(a){window.console&&window.console.log&&console.log(a)}).done(function(a){})},j))}),a("#post").on("click",".edd-thickbox",function(){a(".edd-select-chosen","#choose-download").css("width","100%")});var k={init:function(){this.revoke_api_key(),this.regenerate_api_key(),this.create_api_key(),this.recount_stats()},revoke_api_key:function(){a(document.body).on("click",".edd-revoke-api-key",function(a){return confirm(edd_vars.revoke_api_key)})},regenerate_api_key:function(){a(document.body).on("click",".edd-regenerate-api-key",function(a){return confirm(edd_vars.regenerate_api_key)})},create_api_key:function(){a(document.body).on("submit","#api-key-generate-form",function(b){var c=a('input[type="text"][name="user_id"]');c.css("border-color","#ddd");var d=c.val();return d.length<1||0==d?(c.css("border-color","#ff0000"),!1):void 0})},recount_stats:function(){a("body").on("change","#recount-stats-type",function(){var b=a("#edd-tools-recount-form"),c=a("option:selected",this).data("type"),d=a("#recount-stats-submit"),e=a("#tools-product-dropdown");if(b.find(".notice-wrap").remove(),d.removeClass("button-disabled").attr("disabled",!1),e.hide(),a(".edd-recount-stats-descriptions span").hide(),"recount-download"===c)e.show(),e.find(".edd-select-chosen").css("width","auto");else if("reset-stats"===c){b.append('<div class="notice-wrap"></div>');var f=b.find(".notice-wrap");f.html('<div class="notice notice-warning"><p><input type="checkbox" id="confirm-reset" name="confirm_reset_store" value="1" /> <label for="confirm-reset">'+edd_vars.reset_stats_warn+"</label></p></div>"),a("#recount-stats-submit").addClass("button-disabled").attr("disabled","disabled")}else e.hide(),e.val(0);a("#"+c).show()}),a("body").on("change","#confirm-reset",function(){var b=a(this).is(":checked");b?a("#recount-stats-submit").removeClass("button-disabled").removeAttr("disabled"):a("#recount-stats-submit").addClass("button-disabled").attr("disabled","disabled")}),a("#edd-tools-recount-form").submit(function(b){var c=a("#recount-stats-type").val(),d=a(this),e=a("option:selected",this).data("type");if("reset-stats"===e){var f=a("#confirm-reset").is(":checked");if(f)return!0;h=!0}d.find(".notice-wrap").remove(),d.append('<div class="notice-wrap"></div>');var g=d.find(".notice-wrap"),h=!1;if((null===c||0===c)&&(g.html('<div class="updated error"><p>'+edd_vars.batch_export_no_class+"</p></div>"),h=!0),"recount-download"===e){var i=a('select[name="download_id"]').val();0==i&&(g.html('<div class="updated error"><p>'+edd_vars.batch_export_no_reqs+"</p></div>"),h=!0)}return h?(d.find(".button-disabled").removeClass("button-disabled"),!1):void 0})}};k.init();var l={init:function(){this.submit(),this.dismiss_message()},submit:function(){var b=this;a(document.body).on("submit",".edd-export-form",function(c){c.preventDefault();var d=a(this).find('input[type="submit"]');if(!d.hasClass("button-disabled")){var e=a(this).serialize();d.addClass("button-disabled"),a(this).find(".notice-wrap").remove(),a(this).append('<div class="notice-wrap"><span class="spinner is-active"></span><div class="edd-progress"><div></div></div></div>'),b.process_step(1,e,b)}})},process_step:function(b,c,d){a.ajax({type:"POST",url:ajaxurl,data:{form:c,action:"edd_do_ajax_export",step:b},dataType:"json",success:function(b){if("done"==b.step||b.error||b.success){var e=a(".edd-export-form").find(".edd-progress").parent().parent(),f=e.find(".notice-wrap");if(e.find(".button-disabled").removeClass("button-disabled"),b.error){var g=b.message;f.html('<div class="updated error"><p>'+g+"</p></div>")}else if(b.success){var h=b.message;f.html('<div id="edd-batch-success" class="updated notice is-dismissible"><p>'+h+'<span class="notice-dismiss"></span></p></div>')}else f.remove(),window.location=b.url}else a(".edd-progress div").animate({width:b.percentage+"%"},50,function(){}),d.process_step(parseInt(b.step),c,d)}}).fail(function(a){window.console&&window.console.log&&console.log(a)})},dismiss_message:function(){a("body").on("click","#edd-batch-success .notice-dismiss",function(){a("#edd-batch-success").parent().slideUp("fast")})}};l.init();var m={init:function(){this.submit()},submit:function(){var b=this;a(".edd-import-form").ajaxForm({beforeSubmit:b.before_submit,success:b.success,complete:b.complete,dataType:"json",error:b.error})},before_submit:function(b,c,d){if(c.find(".notice-wrap").remove(),c.append('<div class="notice-wrap"><span class="spinner is-active"></span><div class="edd-progress"><div></div></div></div>'),!(window.File&&window.FileReader&&window.FileList&&window.Blob)){var e=a(".edd-import-form").find(".edd-progress").parent().parent(),f=e.find(".notice-wrap");return e.find(".button-disabled").removeClass("button-disabled"),f.html('<div class="update error"><p>'+edd_vars.unsupported_browser+"</p></div>"),!1}},success:function(a,b,c,d){},complete:function(b){var c=jQuery.parseJSON(b.responseText);if(c.success){var d=a(".edd-import-form .notice-wrap").parent();d.find(".edd-import-file-wrap,.notice-wrap").remove(),d.find(".edd-import-options").slideDown();var e=d.find("select.edd-import-csv-column"),g=(e.parent().parent(),"");a.each(c.data.columns,function(a,b){g+='<option value="'+b+'">'+b+"</option>"}),e.append(g),e.on("change",function(){var b=a(this).val();b&&0!=c.data.first_row[b]?a(this).parent().next().html(c.data.first_row[b]):a(this).parent().next().html("")}),a("body").on("click",".edd-import-proceed",function(a){a.preventDefault(),d.append('<div class="notice-wrap"><span class="spinner is-active"></span><div class="edd-progress"><div></div></div></div>'),c.data.mapping=d.serialize(),m.process_step(1,c.data,self)})}else m.error(b)},error:function(b){var c=jQuery.parseJSON(b.responseText),d=a(".edd-import-form").find(".edd-progress").parent().parent(),e=d.find(".notice-wrap");d.find(".button-disabled").removeClass("button-disabled"),c.data.error?e.html('<div class="update error"><p>'+c.data.error+"</p></div>"):e.remove()},process_step:function(b,c,d){a.ajax({type:"POST",url:ajaxurl,data:{form:c.form,nonce:c.nonce,"class":c["class"],upload:c.upload,mapping:c.mapping,action:"edd_do_ajax_import",step:b},dataType:"json",success:function(b){if("done"==b.data.step||b.data.error){var e=a(".edd-import-form").find(".edd-progress").parent().parent(),f=e.find(".notice-wrap");e.find(".button-disabled").removeClass("button-disabled"),b.data.error?f.html('<div class="update error"><p>'+b.data.error+"</p></div>"):(e.find(".edd-import-options").hide(),a("html, body").animate({scrollTop:e.parent().offset().top},500),f.html('<div class="updated"><p>'+b.data.message+"</p></div>"))}else a(".edd-progress div").animate({width:b.data.percentage+"%"},50,function(){}),m.process_step(parseInt(b.data.step),c,d)}}).fail(function(a){window.console&&window.console.log&&console.log(a)})}};m.init();var n={vars:{customer_card_wrap_editable:a(".edd-customer-card-wrapper .editable"),customer_card_wrap_edit_item:a(".edd-customer-card-wrapper .edit-item"),user_id:a('input[name="customerinfo[user_id]"]'),state_input:a(':input[name="customerinfo[state]"]'),note:a("#customer-note")},init:function(){this.edit_customer(),this.add_email(),this.user_search(),this.remove_user(),this.cancel_edit(),this.change_country(),this.add_note(),this.delete_checked()},edit_customer:function(){a(document.body).on("click","#edit-customer",function(a){a.preventDefault(),n.vars.customer_card_wrap_editable.hide(),n.vars.customer_card_wrap_edit_item.fadeIn().css("display","block")})},add_email:function(){a(document.body).on("click","#add-customer-email",function(b){b.preventDefault();var c=a(this),d=c.parent();d.parent().find(".notice-wrap").remove(),d.find(".spinner").css("visibility","visible"),c.attr("disabled",!0);var e=d.find('input[name="customer-id"]').val(),f=d.find('input[name="additional-email"]').val(),g=d.find('input[name="make-additional-primary"]').is(":checked"),h=d.find('input[name="add_email_nonce"]').val(),i={edd_action:"customer-add-email",customer_id:e,email:f,primary:g,_wpnonce:h};a.post(ajaxurl,i,function(a){!0===a.success?window.location.href=a.redirect:(c.attr("disabled",!1),d.after('<div class="notice-wrap"><div class="notice notice-error inline"><p>'+a.message+"</p></div></div>"),d.find(".spinner").css("visibility","hidden"))},"json")})},user_search:function(){a(document.body).on("click.eddSelectUser",".edd_user_search_results a",function(b){b.preventDefault();var c=a(this).data("userid");n.vars.user_id.val(c)})},remove_user:function(){a(document.body).on("click","#disconnect-customer",function(b){b.preventDefault();var c=a('input[name="customerinfo[id]"]').val(),d={edd_action:"disconnect-userid",customer_id:c,_wpnonce:a("#edit-customer-info #_wpnonce").val()};a.post(ajaxurl,d,function(a){window.location.href=window.location.href},"json")})},cancel_edit:function(){a(document.body).on("click","#edd-edit-customer-cancel",function(b){b.preventDefault(),n.vars.customer_card_wrap_edit_item.hide(),n.vars.customer_card_wrap_editable.show(),a(".edd_user_search_results").html("")})},change_country:function(){a('select[name="customerinfo[country]"]').change(function(){var b=a(this);return data={action:"edd_get_shop_states",country:b.val(),field_name:"customerinfo[state]"},a.post(ajaxurl,data,function(a){"nostates"==a?n.vars.state_input.replaceWith('<input type="text" name="'+data.field_name+'" value="" class="edd-edit-toggles medium-text"/>'):n.vars.state_input.replaceWith(a)}),!1})},add_note:function(){a(document.body).on("click","#add-customer-note",function(b){b.preventDefault();var c={edd_action:"add-customer-note",customer_id:a("#customer-id").val(),customer_note:n.vars.note.val(),add_customer_note_nonce:a("#add_customer_note_nonce").val()};if(c.customer_note)a.ajax({type:"POST",data:c,url:ajaxurl,success:function(b){a("#edd-customer-notes").prepend(b),a(".edd-no-customer-notes").hide(),n.vars.note.val("")}}).fail(function(a){window.console&&window.console.log&&console.log(a)});else{var d=n.vars.note.css("border-color");n.vars.note.css("border-color","red"),setTimeout(function(){n.vars.note.css("border-color",d)},500)}})},delete_checked:function(){a("#edd-customer-delete-confirm").change(function(){var b=a("#edd-customer-delete-records"),c=a("#edd-delete-customer");a(this).prop("checked")?(b.attr("disabled",!1),c.attr("disabled",!1)):(b.attr("disabled",!0),b.prop("checked",!1),c.attr("disabled",!0))})}};n.init(),a(".edd-ajax-user-search").keyup(function(){var b=a(this).val(),c="";a(this).data("exclude")&&(c=a(this).data("exclude")),a(".edd-ajax").show(),data={action:"edd_search_users",user_name:b,exclude:c},document.body.style.cursor="wait",a.ajax({type:"POST",data:data,dataType:"json",url:ajaxurl,success:function(b){a(".edd-ajax").hide(),a(".edd_user_search_results").removeClass("hidden"),a(".edd_user_search_results span").html(""),a(b.results).appendTo(".edd_user_search_results span"),document.body.style.cursor="default"}})}),a(document.body).on("click.eddSelectUser",".edd_user_search_results span a",function(b){b.preventDefault();var c=a(this).data("login");a(".edd-ajax-user-search").val(c),a(".edd_user_search_results").addClass("hidden"),a(".edd_user_search_results span").html("")}),a(document.body).on("click.eddCancelUserSearch",".edd_user_search_results a.edd-ajax-user-cancel",function(b){b.preventDefault(),a(".edd-ajax-user-search").val(""),a(".edd_user_search_results").addClass("hidden"),a(".edd_user_search_results span").html("")}),a("#edd_dashboard_sales").length&&a.ajax({type:"GET",data:{action:"edd_load_dashboard_widget"},url:ajaxurl,success:function(b){a("#edd_dashboard_sales .inside").html(b)}}),a(document).on("keydown",".customer-note-input",function(b){13==b.keyCode&&(b.metaKey||b.ctrlKey)&&a("#add-customer-note").click()})});var eddFormatCurrency=function(a){var b=parseFloat(a),c=edd_vars.currency,d=edd_vars.currency_decimals;return b.toLocaleString(c,{style:"currency",
|
2 |
+
currency:c,minimumFractionDigits:d,maximumFractionDigits:d})},eddFormatNumber=function(a){var b=parseFloat(a),c=edd_vars.currency;edd_vars.currency_decimals;return b.toLocaleString(c,{style:"decimal",minimumFractionDigits:0,maximumFractionDigits:0})},eddLabelFormatter=function(a,b){return'<div style="font-size:12px; text-align:center; padding:2px">'+a+"</div>"},eddLegendFormatterSales=function(a,b){var c=a.toLowerCase().replace(/\s/g,"-"),d='<div class="edd-legend-color" style="background-color: '+b.color+'"></div>',e='<div class="edd-pie-legend-item">'+a+": "+Math.round(b.percent)+"% ("+eddFormatNumber(b.data[0][1])+")</div>",f='<div id="'+b.edd_vars.id+c+'" class="edd-legend-item-wrapper">'+d+e+"</div>";return jQuery("#edd-pie-legend-"+b.edd_vars.id).append(f),f},eddLegendFormatterEarnings=function(a,b){var c=a.toLowerCase().replace(/\s/g,"-"),d='<div class="edd-legend-color" style="background-color: '+b.color+'"></div>',e='<div class="edd-pie-legend-item">'+a+": "+Math.round(b.percent)+"% ("+eddFormatCurrency(b.data[0][1])+")</div>",f='<div id="'+b.edd_vars.id+c+'" class="edd-legend-item-wrapper">'+d+e+"</div>";return jQuery("#edd-pie-legend-"+b.edd_vars.id).append(f),f};
|
assets/js/edd-ajax.js
CHANGED
@@ -348,6 +348,8 @@ jQuery(document).ready(function ($) {
|
|
348 |
|
349 |
$(this).val(edd_global_vars.purchase_loading);
|
350 |
|
|
|
|
|
351 |
$(this).after('<span class="edd-cart-ajax"><i class="edd-icon-spinner edd-icon-spin"></i></span>');
|
352 |
|
353 |
$.post(edd_global_vars.ajaxurl, $('#edd_purchase_form').serialize() + '&action=edd_process_checkout&edd_ajax=true', function(data) {
|
@@ -361,11 +363,75 @@ jQuery(document).ready(function ($) {
|
|
361 |
$('.edd_errors').remove();
|
362 |
$('.edd-error').hide();
|
363 |
$('#edd_purchase_submit').before(data);
|
|
|
364 |
}
|
365 |
});
|
366 |
|
367 |
});
|
368 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
369 |
});
|
370 |
|
371 |
function edd_load_gateway( payment_mode ) {
|
@@ -388,7 +454,9 @@ function edd_load_gateway( payment_mode ) {
|
|
388 |
function(response){
|
389 |
jQuery('#edd_purchase_form_wrap').html(response);
|
390 |
jQuery('.edd-no-js').hide();
|
|
|
391 |
}
|
392 |
);
|
393 |
|
394 |
}
|
|
348 |
|
349 |
$(this).val(edd_global_vars.purchase_loading);
|
350 |
|
351 |
+
$(this).prop( 'disabled', true );
|
352 |
+
|
353 |
$(this).after('<span class="edd-cart-ajax"><i class="edd-icon-spinner edd-icon-spin"></i></span>');
|
354 |
|
355 |
$.post(edd_global_vars.ajaxurl, $('#edd_purchase_form').serialize() + '&action=edd_process_checkout&edd_ajax=true', function(data) {
|
363 |
$('.edd_errors').remove();
|
364 |
$('.edd-error').hide();
|
365 |
$('#edd_purchase_submit').before(data);
|
366 |
+
$('#edd-purchase-button').prop( 'disabled', false );
|
367 |
}
|
368 |
});
|
369 |
|
370 |
});
|
371 |
|
372 |
+
$('body').on('change', '#edd_cc_address input.card_state, #edd_cc_address select, #edd_address_country', update_state_field);
|
373 |
+
|
374 |
+
function update_state_field() {
|
375 |
+
|
376 |
+
var $this = $(this);
|
377 |
+
var $form;
|
378 |
+
var is_checkout = typeof edd_global_vars !== 'undefined';
|
379 |
+
|
380 |
+
if( 'card_state' != $this.attr('id') ) {
|
381 |
+
|
382 |
+
// If the country field has changed, we need to update the state/province field
|
383 |
+
var postData = {
|
384 |
+
action: 'edd_get_shop_states',
|
385 |
+
country: $this.val(),
|
386 |
+
field_name: 'card_state'
|
387 |
+
};
|
388 |
+
|
389 |
+
$.ajax({
|
390 |
+
type: "POST",
|
391 |
+
data: postData,
|
392 |
+
url: edd_scripts.ajaxurl,
|
393 |
+
xhrFields: {
|
394 |
+
withCredentials: true
|
395 |
+
},
|
396 |
+
success: function (response) {
|
397 |
+
console.log( response); console.log(is_checkout);
|
398 |
+
if ( is_checkout ) {
|
399 |
+
$form = $("#edd_purchase_form");
|
400 |
+
} else {
|
401 |
+
$form = $this.closest("form");
|
402 |
+
}
|
403 |
+
|
404 |
+
var state_inputs = 'input[name="card_state"], select[name="card_state"], input[name="edd_address_state"], select[name="edd_address_state"]';
|
405 |
+
|
406 |
+
if( 'nostates' == $.trim(response) ) {
|
407 |
+
var text_field = '<input type="text" name="card_state" class="cart-state edd-input required" value=""/>';
|
408 |
+
$form.find(state_inputs).replaceWith( text_field );
|
409 |
+
} else {
|
410 |
+
$form.find(state_inputs).replaceWith( response );
|
411 |
+
}
|
412 |
+
|
413 |
+
if ( is_checkout ) {
|
414 |
+
$('body').trigger('edd_cart_billing_address_updated', [ response ]);
|
415 |
+
}
|
416 |
+
|
417 |
+
}
|
418 |
+
}).fail(function (data) {
|
419 |
+
if ( window.console && window.console.log ) {
|
420 |
+
console.log( data );
|
421 |
+
}
|
422 |
+
}).done(function (data) {
|
423 |
+
if ( is_checkout ) {
|
424 |
+
recalculate_taxes();
|
425 |
+
}
|
426 |
+
});
|
427 |
+
} else {
|
428 |
+
if ( is_checkout ) {
|
429 |
+
recalculate_taxes();
|
430 |
+
}
|
431 |
+
}
|
432 |
+
|
433 |
+
return false;
|
434 |
+
}
|
435 |
});
|
436 |
|
437 |
function edd_load_gateway( payment_mode ) {
|
454 |
function(response){
|
455 |
jQuery('#edd_purchase_form_wrap').html(response);
|
456 |
jQuery('.edd-no-js').hide();
|
457 |
+
jQuery('body').trigger('edd_gateway_loaded', [ payment_mode ]);
|
458 |
}
|
459 |
);
|
460 |
|
461 |
}
|
462 |
+
|
assets/js/edd-ajax.min.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
function edd_load_gateway(
|
1 |
+
function edd_load_gateway(a){jQuery(".edd-cart-ajax").show(),jQuery("#edd_purchase_form_wrap").html('<img src="'+edd_scripts.ajax_loader+'"/>');var b=edd_scripts.ajaxurl;b+=b.indexOf("?")>0?"&":"?",b=b+"payment-mode="+a,jQuery.post(b,{action:"edd_load_gateway",edd_payment_mode:a},function(b){jQuery("#edd_purchase_form_wrap").html(b),jQuery(".edd-no-js").hide(),jQuery("body").trigger("edd_gateway_loaded",[a])})}var edd_scripts;jQuery(document).ready(function(a){function b(){var c,b=a(this),d="undefined"!=typeof edd_global_vars;if("card_state"!=b.attr("id")){var e={action:"edd_get_shop_states",country:b.val(),field_name:"card_state"};a.ajax({type:"POST",data:e,url:edd_scripts.ajaxurl,xhrFields:{withCredentials:!0},success:function(e){console.log(e),console.log(d),c=d?a("#edd_purchase_form"):b.closest("form");var f='input[name="card_state"], select[name="card_state"], input[name="edd_address_state"], select[name="edd_address_state"]';if("nostates"==a.trim(e)){var g='<input type="text" name="card_state" class="cart-state edd-input required" value=""/>';c.find(f).replaceWith(g)}else c.find(f).replaceWith(e);d&&a("body").trigger("edd_cart_billing_address_updated",[e])}}).fail(function(a){window.console&&window.console.log&&console.log(a)}).done(function(a){d&&recalculate_taxes()})}else d&&recalculate_taxes();return!1}a(".edd-no-js").hide(),a("a.edd-add-to-cart").addClass("edd-has-js"),a("body").on("click.eddRemoveFromCart",".edd-remove-from-cart",function(b){var c=a(this),d=c.data("cart-item"),e=c.data("action"),f=c.data("download-id"),g={action:e,cart_item:d};return a.ajax({type:"POST",data:g,dataType:"json",url:edd_scripts.ajaxurl,xhrFields:{withCredentials:!0},success:function(b){if(b.removed){if(parseInt(edd_scripts.position_in_cart,10)===parseInt(d,10))return window.location=window.location,!1;a(".edd-cart").find("[data-cart-item='"+d+"']").parent().remove();var c=0;a(".edd-cart").find("[data-cart-item]").each(function(){a(this).attr("data-cart-item",c),c+=1}),a("[id^=edd_purchase_"+f+"]").length&&(a("[id^=edd_purchase_"+f+"] .edd_go_to_checkout").hide(),a("[id^=edd_purchase_"+f+"] a.edd-add-to-cart").show().removeAttr("data-edd-loading"),"1"==edd_scripts.quantities_enabled&&a("[id^=edd_purchase_"+f+"] .edd_download_quantity_wrapper").show()),a("span.edd-cart-quantity").text(b.cart_quantity),a("body").trigger("edd_quantity_updated",[b.cart_quantity]),edd_scripts.taxes_enabled&&(a(".cart_item.edd_subtotal span").html(b.subtotal),a(".cart_item.edd_cart_tax span").html(b.tax)),a(".cart_item.edd_total span").html(b.total),0==b.cart_quantity&&(a(".cart_item.edd_subtotal,.edd-cart-number-of-items,.cart_item.edd_checkout,.cart_item.edd_cart_tax,.cart_item.edd_total").hide(),a(".edd-cart").append('<li class="cart_item empty">'+edd_scripts.empty_cart_message+"</li>")),a("body").trigger("edd_cart_item_removed",[b])}}}).fail(function(a){window.console&&window.console.log&&console.log(a)}).done(function(a){}),!1}),a("body").on("click.eddAddToCart",".edd-add-to-cart",function(b){b.preventDefault();var c=a(this),d=c.closest("form");c.prop("disabled",!0);var e=c.find(".edd-loading"),f=c.closest("div"),g=e.width(),h=e.height();c.attr("data-edd-loading",""),e.css({"margin-left":g/-2,"margin-top":h/-2});var d=c.parents("form").last(),i=c.data("download-id"),j=c.data("variable-price"),k=c.data("price-mode"),l=[],m=!0;if("yes"==j)if(d.find(".edd_price_option_"+i).is("input:hidden"))l[0]=a(".edd_price_option_"+i,d).val(),d.find(".edd-submit").data("price")&&d.find(".edd-submit").data("price")>0&&(m=!1);else{if(!d.find(".edd_price_option_"+i+":checked",d).length)return c.removeAttr("data-edd-loading"),void alert(edd_scripts.select_option);d.find(".edd_price_option_"+i+":checked",d).each(function(b){if(l[b]=a(this).val(),!0===m){var c=a(this).data("price");c&&c>0&&(m=!1)}})}else l[0]=i,c.data("price")&&c.data("price")>0&&(m=!1);if(m&&d.find(".edd_action_input").val("add_to_cart"),"straight_to_gateway"==d.find(".edd_action_input").val())return d.submit(),!0;var n=c.data("action"),o={action:n,download_id:i,price_ids:l,post_data:a(d).serialize()};return a.ajax({type:"POST",data:o,dataType:"json",url:edd_scripts.ajaxurl,xhrFields:{withCredentials:!0},success:function(b){if("1"==edd_scripts.redirect_to_checkout&&"1"==d.find("#edd_redirect_to_checkout").val())window.location=edd_scripts.checkout_page;else{"1"===edd_scripts.taxes_enabled&&(a(".cart_item.edd_subtotal").show(),a(".cart_item.edd_cart_tax").show()),a(".cart_item.edd_total").show(),a(".cart_item.edd_checkout").show(),a(".cart_item.empty").length?(a(b.cart_item).insertBefore(".edd-cart-meta:first"),a(".cart_item.empty").hide()):a(b.cart_item).insertBefore(".edd-cart-meta:first"),"1"===edd_scripts.taxes_enabled&&(a(".edd-cart-meta.edd_subtotal span").html(b.subtotal),a(".edd-cart-meta.edd_cart_tax span").html(b.tax)),a(".edd-cart-meta.edd_total span").html(b.total);a(".edd-cart-item-title",b.cart_item).length;if(a("span.edd-cart-quantity").each(function(){a(this).text(b.cart_quantity),a("body").trigger("edd_quantity_updated",[b.cart_quantity])}),"none"==a(".edd-cart-number-of-items").css("display")&&a(".edd-cart-number-of-items").show("slow"),("no"==j||"multi"!=k)&&(a("a.edd-add-to-cart",f).toggle(),a(".edd_go_to_checkout",f).css("display","inline-block")),"multi"==k&&c.removeAttr("data-edd-loading"),a(".edd_download_purchase_form").length&&("no"==j||!d.find(".edd_price_option_"+i).is("input:hidden"))){var g=a('.edd_download_purchase_form *[data-download-id="'+i+'"]').parents("form");a("a.edd-add-to-cart",g).hide(),"multi"!=k&&g.find(".edd_download_quantity_wrapper").slideUp(),a(".edd_go_to_checkout",g).show().removeAttr("data-edd-loading")}"incart"!=b&&(a(".edd-cart-added-alert",f).fadeIn(),setTimeout(function(){a(".edd-cart-added-alert",f).fadeOut()},3e3)),c.prop("disabled",!1),a("body").trigger("edd_cart_item_added",[b])}}}).fail(function(a){window.console&&window.console.log&&console.log(a)}).done(function(a){}),!1}),a("#edd_checkout_form_wrap").on("click",".edd_checkout_register_login",function(){var b=a(this),c={action:b.data("action")};return a(".edd-cart-ajax").show(),a.post(edd_scripts.ajaxurl,c,function(b){a("#edd_checkout_login_register").html(edd_scripts.loading),a("#edd_checkout_login_register").html(b),a(".edd-cart-ajax").hide()}),!1}),a(document).on("click","#edd_purchase_form #edd_login_fields input[type=submit]",function(b){b.preventDefault();var c=a(this).val();a(this).val(edd_global_vars.purchase_loading),a(this).after('<span class="edd-cart-ajax"><i class="edd-icon-spinner edd-icon-spin"></i></span>');var d={action:"edd_process_checkout_login",edd_ajax:1,edd_user_login:a("#edd_login_fields #edd_user_login").val(),edd_user_pass:a("#edd_login_fields #edd_user_pass").val()};a.post(edd_global_vars.ajaxurl,d,function(b){"success"==a.trim(b)?(a(".edd_errors").remove(),window.location=edd_scripts.checkout_page):(a("#edd_login_fields input[type=submit]").val(c),a(".edd-cart-ajax").remove(),a(".edd_errors").remove(),a("#edd-user-login-submit").before(b))})}),a("select#edd-gateway, input.edd-gateway").change(function(b){var c=a("#edd-gateway option:selected, input.edd-gateway:checked").val();return"0"==c?!1:(edd_load_gateway(c),!1)}),"1"==edd_scripts.is_checkout&&a("select#edd-gateway, input.edd-gateway").length&&setTimeout(function(){edd_load_gateway(edd_scripts.default_gateway)},200),a(document).on("click","#edd_purchase_form #edd_purchase_submit input[type=submit]",function(b){var c=document.getElementById("edd_purchase_form");if("function"!=typeof c.checkValidity||!1!==c.checkValidity()){b.preventDefault();var d=a(this).val();a(this).val(edd_global_vars.purchase_loading),a(this).prop("disabled",!0),a(this).after('<span class="edd-cart-ajax"><i class="edd-icon-spinner edd-icon-spin"></i></span>'),a.post(edd_global_vars.ajaxurl,a("#edd_purchase_form").serialize()+"&action=edd_process_checkout&edd_ajax=true",function(b){"success"==a.trim(b)?(a(".edd_errors").remove(),a(".edd-error").hide(),a(c).submit()):(a("#edd-purchase-button").val(d),a(".edd-cart-ajax").remove(),a(".edd_errors").remove(),a(".edd-error").hide(),a("#edd_purchase_submit").before(b),a("#edd-purchase-button").prop("disabled",!1))})}}),a("body").on("change","#edd_cc_address input.card_state, #edd_cc_address select, #edd_address_country",b)});
|
assets/js/edd-checkout-global.js
CHANGED
@@ -14,9 +14,6 @@ window.EDD_Checkout = (function($) {
|
|
14 |
before_discount = $edd_cart_amount.text();
|
15 |
$checkout_form_wrap = $('#edd_checkout_form_wrap');
|
16 |
|
17 |
-
// Update state/province field on checkout page
|
18 |
-
$body.on('change', '#edd_cc_address input.card_state, #edd_cc_address select', update_state_field);
|
19 |
-
|
20 |
$body.on('keyup change', '.edd-do-validate .card-number', function() {
|
21 |
edd_validate_card( $(this) );
|
22 |
});
|
@@ -78,91 +75,6 @@ window.EDD_Checkout = (function($) {
|
|
78 |
|
79 |
}
|
80 |
|
81 |
-
function update_state_field() {
|
82 |
-
|
83 |
-
var $this = $(this);
|
84 |
-
if( 'card_state' != $this.attr('id') ) {
|
85 |
-
|
86 |
-
// If the country field has changed, we need to update the state/province field
|
87 |
-
var postData = {
|
88 |
-
action: 'edd_get_shop_states',
|
89 |
-
country: $this.val(),
|
90 |
-
field_name: 'card_state'
|
91 |
-
};
|
92 |
-
|
93 |
-
$.ajax({
|
94 |
-
type: "POST",
|
95 |
-
data: postData,
|
96 |
-
url: edd_global_vars.ajaxurl,
|
97 |
-
xhrFields: {
|
98 |
-
withCredentials: true
|
99 |
-
},
|
100 |
-
success: function (response) {
|
101 |
-
if( 'nostates' == $.trim(response) ) {
|
102 |
-
var text_field = '<input type="text" name="card_state" class="cart-state edd-input required" value=""/>';
|
103 |
-
$form.find('input[name="card_state"], select[name="card_state"]').replaceWith( text_field );
|
104 |
-
} else {
|
105 |
-
$form.find('input[name="card_state"], select[name="card_state"]').replaceWith( response );
|
106 |
-
}
|
107 |
-
|
108 |
-
$body.trigger('edd_cart_billing_address_updated', [ response ]);
|
109 |
-
|
110 |
-
}
|
111 |
-
}).fail(function (data) {
|
112 |
-
if ( window.console && window.console.log ) {
|
113 |
-
console.log( data );
|
114 |
-
}
|
115 |
-
}).done(function (data) {
|
116 |
-
recalculate_taxes();
|
117 |
-
});
|
118 |
-
} else {
|
119 |
-
recalculate_taxes();
|
120 |
-
}
|
121 |
-
|
122 |
-
return false;
|
123 |
-
}
|
124 |
-
|
125 |
-
function recalculate_taxes(state) {
|
126 |
-
|
127 |
-
if( '1' != edd_global_vars.taxes_enabled )
|
128 |
-
return; // Taxes not enabled
|
129 |
-
|
130 |
-
var $edd_cc_address = $('#edd_cc_address');
|
131 |
-
|
132 |
-
if( ! state ) {
|
133 |
-
state = $edd_cc_address.find('#card_state').val();
|
134 |
-
}
|
135 |
-
|
136 |
-
var postData = {
|
137 |
-
action: 'edd_recalculate_taxes',
|
138 |
-
billing_country: $edd_cc_address.find('#billing_country').val(),
|
139 |
-
state: state
|
140 |
-
};
|
141 |
-
|
142 |
-
$.ajax({
|
143 |
-
type: "POST",
|
144 |
-
data: postData,
|
145 |
-
dataType: "json",
|
146 |
-
url: edd_global_vars.ajaxurl,
|
147 |
-
xhrFields: {
|
148 |
-
withCredentials: true
|
149 |
-
},
|
150 |
-
success: function (tax_response) {
|
151 |
-
$('#edd_checkout_cart_form').replaceWith(tax_response.html);
|
152 |
-
$('.edd_cart_amount').html(tax_response.total);
|
153 |
-
var tax_data = new Object();
|
154 |
-
tax_data.postdata = postData;
|
155 |
-
tax_data.response = tax_response;
|
156 |
-
$body.trigger('edd_taxes_recalculated', [ tax_data ]);
|
157 |
-
}
|
158 |
-
}).fail(function (data) {
|
159 |
-
if ( window.console && window.console.log ) {
|
160 |
-
console.log( data );
|
161 |
-
$body.trigger('edd_taxes_recalculated', [ tax_data ]);
|
162 |
-
}
|
163 |
-
});
|
164 |
-
}
|
165 |
-
|
166 |
function edd_validate_card(field) {
|
167 |
var card_field = field;
|
168 |
card_field.validateCreditCard(function(result) {
|
@@ -376,3 +288,44 @@ window.EDD_Checkout = (function($) {
|
|
376 |
|
377 |
// init on document.ready
|
378 |
window.jQuery(document).ready(EDD_Checkout.init);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
14 |
before_discount = $edd_cart_amount.text();
|
15 |
$checkout_form_wrap = $('#edd_checkout_form_wrap');
|
16 |
|
|
|
|
|
|
|
17 |
$body.on('keyup change', '.edd-do-validate .card-number', function() {
|
18 |
edd_validate_card( $(this) );
|
19 |
});
|
75 |
|
76 |
}
|
77 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
78 |
function edd_validate_card(field) {
|
79 |
var card_field = field;
|
80 |
card_field.validateCreditCard(function(result) {
|
288 |
|
289 |
// init on document.ready
|
290 |
window.jQuery(document).ready(EDD_Checkout.init);
|
291 |
+
|
292 |
+
function recalculate_taxes(state) {
|
293 |
+
|
294 |
+
if( '1' != edd_global_vars.taxes_enabled )
|
295 |
+
return; // Taxes not enabled
|
296 |
+
|
297 |
+
var $edd_cc_address = jQuery('#edd_cc_address');
|
298 |
+
|
299 |
+
if( ! state ) {
|
300 |
+
state = $edd_cc_address.find('#card_state').val();
|
301 |
+
}
|
302 |
+
|
303 |
+
var postData = {
|
304 |
+
action: 'edd_recalculate_taxes',
|
305 |
+
billing_country: $edd_cc_address.find('#billing_country').val(),
|
306 |
+
state: state
|
307 |
+
};
|
308 |
+
|
309 |
+
jQuery.ajax({
|
310 |
+
type: "POST",
|
311 |
+
data: postData,
|
312 |
+
dataType: "json",
|
313 |
+
url: edd_global_vars.ajaxurl,
|
314 |
+
xhrFields: {
|
315 |
+
withCredentials: true
|
316 |
+
},
|
317 |
+
success: function (tax_response) {
|
318 |
+
jQuery('#edd_checkout_cart_form').replaceWith(tax_response.html);
|
319 |
+
jQuery('.edd_cart_amount').html(tax_response.total);
|
320 |
+
var tax_data = new Object();
|
321 |
+
tax_data.postdata = postData;
|
322 |
+
tax_data.response = tax_response;
|
323 |
+
jQuery('body').trigger('edd_taxes_recalculated', [ tax_data ]);
|
324 |
+
}
|
325 |
+
}).fail(function (data) {
|
326 |
+
if ( window.console && window.console.log ) {
|
327 |
+
console.log( data );
|
328 |
+
jQuery('body').trigger('edd_taxes_recalculated', [ tax_data ]);
|
329 |
+
}
|
330 |
+
});
|
331 |
+
}
|
assets/js/edd-checkout-global.min.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
window.EDD_Checkout=function(
|
1 |
+
function recalculate_taxes(a){if("1"==edd_global_vars.taxes_enabled){var b=jQuery("#edd_cc_address");a||(a=b.find("#card_state").val());var c={action:"edd_recalculate_taxes",billing_country:b.find("#billing_country").val(),state:a};jQuery.ajax({type:"POST",data:c,dataType:"json",url:edd_global_vars.ajaxurl,xhrFields:{withCredentials:!0},success:function(a){jQuery("#edd_checkout_cart_form").replaceWith(a.html),jQuery(".edd_cart_amount").html(a.total);var b=new Object;b.postdata=c,b.response=a,jQuery("body").trigger("edd_taxes_recalculated",[b])}}).fail(function(a){window.console&&window.console.log&&(console.log(a),jQuery("body").trigger("edd_taxes_recalculated",[tax_data]))})}}window.EDD_Checkout=function(a){"use strict";function g(){b=a(document.body),c=a("#edd_purchase_form"),d=a(".edd_cart_amount"),e=d.text(),f=a("#edd_checkout_form_wrap"),b.on("keyup change",".edd-do-validate .card-number",function(){h(a(this))}),b.on("submit","#edd_payment_mode",function(){var b=a("#edd-gateway option:selected").val();return 0==b?(alert(edd_global_vars.no_gateway),!1):void 0}),b.on("click","#edd_payment_mode_select input",function(){a("#edd_payment_mode_select label.edd-gateway-option-selected").removeClass("edd-gateway-option-selected"),a("#edd_payment_mode_select input:checked").parent().addClass("edd-gateway-option-selected")}),f.on("click",".edd-apply-discount",i),f.on("keypress","#edd-discount",function(a){return"13"==a.keyCode?!1:void 0}),f.on("keyup","#edd-discount",function(a){"13"==a.keyCode&&f.find(".edd-apply-discount").trigger("click")}),b.on("click",".edd_discount_remove",j),b.on("click",".edd_discount_link",function(b){b.preventDefault(),a(".edd_discount_link").parent().hide(),a("#edd-discount-code-wrap").show().find("#edd-discount").focus()}),b.find("#edd-discount-code-wrap").hide(),b.find("#edd_show_discount").show(),b.on("change",".edd-item-quantity",k),b.on("click",".edd-amazon-logout #Logout",function(a){a.preventDefault(),amazon.Login.logout(),window.location=edd_amazon.checkoutUri})}function h(b){var c=b;c.validateCreditCard(function(b){var d=a(".card-type");null==b.card_type?(d.removeClass().addClass("off card-type"),c.removeClass("valid"),c.addClass("error")):(d.removeClass("off"),d.addClass(b.card_type.name),b.length_valid&&b.luhn_valid?(c.addClass("valid"),c.removeClass("error")):(c.removeClass("valid"),c.addClass("error")))})}function i(c){c.preventDefault();var e=(a(this),a("#edd-discount").val()),g=a("#edd-discount-loader");if(""==e||e==edd_global_vars.enter_discount)return!1;var h={action:"edd_apply_discount",code:e,form:a("#edd_purchase_form").serialize()};return a("#edd-discount-error-wrap").html("").hide(),g.show(),a.ajax({type:"POST",data:h,dataType:"json",url:edd_global_vars.ajaxurl,xhrFields:{withCredentials:!0},success:function(c){if(c)if("valid"==c.msg){a(".edd_cart_discount").html(c.html),a(".edd_cart_discount_row").show(),a(".edd_cart_amount").each(function(){a(this).text(c.total)}),a("#edd-discount",f).val(""),recalculate_taxes();var d=a("#edd_cc_fields .edd-input, #edd_cc_fields .edd-select,#edd_cc_address .edd-input, #edd_cc_address .edd-select,#edd_payment_mode_select .edd-input, #edd_payment_mode_select .edd-select");"0.00"==c.total_plain?(a("#edd_cc_fields,#edd_cc_address,#edd_payment_mode_select").slideUp(),d.removeAttr("required"),a('input[name="edd-gateway"]').val("manual")):(d.attr("required","required"),a("#edd_cc_fields,#edd_cc_address").slideDown()),b.trigger("edd_discount_applied",[c])}else a("#edd-discount-error-wrap").html('<span class="edd_error">'+c.msg+"</span>"),a("#edd-discount-error-wrap").show(),b.trigger("edd_discount_invalid",[c]);else window.console&&window.console.log&&console.log(c),b.trigger("edd_discount_failed",[c]);g.hide()}}).fail(function(a){window.console&&window.console.log&&console.log(a)}),!1}function j(c){var d=a(this),e={action:"edd_remove_discount",code:d.data("code")};return a.ajax({type:"POST",data:e,dataType:"json",url:edd_global_vars.ajaxurl,xhrFields:{withCredentials:!0},success:function(c){var d="0"+edd_global_vars.decimal_separator+"00";a(".edd_cart_amount").each(function(){(edd_global_vars.currency_sign+d==a(this).text()||d+edd_global_vars.currency_sign==a(this).text())&&window.location.reload(),a(this).text(c.total)}),a(".edd_cart_discount").html(c.html),c.discounts||a(".edd_cart_discount_row").hide(),recalculate_taxes(),a("#edd_cc_fields,#edd_cc_address").slideDown(),b.trigger("edd_discount_removed",[c])}}).fail(function(a){window.console&&window.console.log&&console.log(a)}),!1}function k(c){var d=a(this),e=d.val(),f=d.data("key"),g=d.closest(".edd_cart_item").data("download-id"),h=d.parent().find('input[name="edd-cart-download-'+f+'-options"]').val(),i={action:"edd_update_quantity",quantity:e,download_id:g,options:h};return a.ajax({type:"POST",data:i,dataType:"json",url:edd_global_vars.ajaxurl,xhrFields:{withCredentials:!0},success:function(c){a(".edd_cart_subtotal_amount").each(function(){a(this).text(c.subtotal)}),a(".edd_cart_tax_amount").each(function(){a(this).text(c.taxes)}),a(".edd_cart_amount").each(function(){a(this).text(c.total),b.trigger("edd_quantity_updated",[c])})}}).fail(function(a){window.console&&window.console.log&&console.log(a)}),!1}var b,c,d,e,f;return{init:g,recalculate_taxes:recalculate_taxes}}(window.jQuery),window.jQuery(document).ready(EDD_Checkout.init);
|
easy-digital-downloads.php
CHANGED
@@ -5,7 +5,7 @@
|
|
5 |
* Description: The easiest way to sell digital products with WordPress.
|
6 |
* Author: Pippin Williamson and Company
|
7 |
* Author URI: https://easydigitaldownloads.com
|
8 |
-
* Version: 2.
|
9 |
* Text Domain: easy-digital-downloads
|
10 |
* Domain Path: languages
|
11 |
*
|
@@ -25,7 +25,7 @@
|
|
25 |
* @package EDD
|
26 |
* @category Core
|
27 |
* @author Pippin Williamson
|
28 |
-
* @version 2.
|
29 |
*/
|
30 |
|
31 |
// Exit if accessed directly.
|
@@ -113,6 +113,14 @@ final class Easy_Digital_Downloads {
|
|
113 |
*/
|
114 |
public $customers;
|
115 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
116 |
/**
|
117 |
* Main Easy_Digital_Downloads Instance.
|
118 |
*
|
@@ -136,14 +144,15 @@ final class Easy_Digital_Downloads {
|
|
136 |
add_action( 'plugins_loaded', array( self::$instance, 'load_textdomain' ) );
|
137 |
|
138 |
self::$instance->includes();
|
139 |
-
self::$instance->roles
|
140 |
-
self::$instance->fees
|
141 |
-
self::$instance->api
|
142 |
-
self::$instance->session
|
143 |
-
self::$instance->html
|
144 |
-
self::$instance->emails
|
145 |
-
self::$instance->email_tags
|
146 |
-
self::$instance->customers
|
|
|
147 |
}
|
148 |
return self::$instance;
|
149 |
}
|
@@ -186,7 +195,7 @@ final class Easy_Digital_Downloads {
|
|
186 |
|
187 |
// Plugin version.
|
188 |
if ( ! defined( 'EDD_VERSION' ) ) {
|
189 |
-
define( 'EDD_VERSION', '2.
|
190 |
}
|
191 |
|
192 |
// Plugin Folder Path.
|
@@ -237,6 +246,7 @@ final class Easy_Digital_Downloads {
|
|
237 |
require_once EDD_PLUGIN_DIR . 'includes/cart/actions.php';
|
238 |
require_once EDD_PLUGIN_DIR . 'includes/class-edd-db.php';
|
239 |
require_once EDD_PLUGIN_DIR . 'includes/class-edd-db-customers.php';
|
|
|
240 |
require_once EDD_PLUGIN_DIR . 'includes/class-edd-customer.php';
|
241 |
require_once EDD_PLUGIN_DIR . 'includes/class-edd-download.php';
|
242 |
require_once EDD_PLUGIN_DIR . 'includes/class-edd-cache-helper.php';
|
@@ -305,6 +315,8 @@ final class Easy_Digital_Downloads {
|
|
305 |
require_once EDD_PLUGIN_DIR . 'includes/admin/discounts/contextual-help.php';
|
306 |
require_once EDD_PLUGIN_DIR . 'includes/admin/discounts/discount-actions.php';
|
307 |
require_once EDD_PLUGIN_DIR . 'includes/admin/discounts/discount-codes.php';
|
|
|
|
|
308 |
require_once EDD_PLUGIN_DIR . 'includes/admin/payments/actions.php';
|
309 |
require_once EDD_PLUGIN_DIR . 'includes/admin/payments/payments-history.php';
|
310 |
require_once EDD_PLUGIN_DIR . 'includes/admin/payments/contextual-help.php';
|
5 |
* Description: The easiest way to sell digital products with WordPress.
|
6 |
* Author: Pippin Williamson and Company
|
7 |
* Author URI: https://easydigitaldownloads.com
|
8 |
+
* Version: 2.6
|
9 |
* Text Domain: easy-digital-downloads
|
10 |
* Domain Path: languages
|
11 |
*
|
25 |
* @package EDD
|
26 |
* @category Core
|
27 |
* @author Pippin Williamson
|
28 |
+
* @version 2.6
|
29 |
*/
|
30 |
|
31 |
// Exit if accessed directly.
|
113 |
*/
|
114 |
public $customers;
|
115 |
|
116 |
+
/**
|
117 |
+
* EDD Customer meta DB Object.
|
118 |
+
*
|
119 |
+
* @var object|EDD_DB_Customer_Meta
|
120 |
+
* @since 2.6
|
121 |
+
*/
|
122 |
+
public $customer_meta;
|
123 |
+
|
124 |
/**
|
125 |
* Main Easy_Digital_Downloads Instance.
|
126 |
*
|
144 |
add_action( 'plugins_loaded', array( self::$instance, 'load_textdomain' ) );
|
145 |
|
146 |
self::$instance->includes();
|
147 |
+
self::$instance->roles = new EDD_Roles();
|
148 |
+
self::$instance->fees = new EDD_Fees();
|
149 |
+
self::$instance->api = new EDD_API();
|
150 |
+
self::$instance->session = new EDD_Session();
|
151 |
+
self::$instance->html = new EDD_HTML_Elements();
|
152 |
+
self::$instance->emails = new EDD_Emails();
|
153 |
+
self::$instance->email_tags = new EDD_Email_Template_Tags();
|
154 |
+
self::$instance->customers = new EDD_DB_Customers();
|
155 |
+
self::$instance->customer_meta = new EDD_DB_Customer_Meta();
|
156 |
}
|
157 |
return self::$instance;
|
158 |
}
|
195 |
|
196 |
// Plugin version.
|
197 |
if ( ! defined( 'EDD_VERSION' ) ) {
|
198 |
+
define( 'EDD_VERSION', '2.6' );
|
199 |
}
|
200 |
|
201 |
// Plugin Folder Path.
|
246 |
require_once EDD_PLUGIN_DIR . 'includes/cart/actions.php';
|
247 |
require_once EDD_PLUGIN_DIR . 'includes/class-edd-db.php';
|
248 |
require_once EDD_PLUGIN_DIR . 'includes/class-edd-db-customers.php';
|
249 |
+
require_once EDD_PLUGIN_DIR . 'includes/class-edd-db-customer-meta.php';
|
250 |
require_once EDD_PLUGIN_DIR . 'includes/class-edd-customer.php';
|
251 |
require_once EDD_PLUGIN_DIR . 'includes/class-edd-download.php';
|
252 |
require_once EDD_PLUGIN_DIR . 'includes/class-edd-cache-helper.php';
|
315 |
require_once EDD_PLUGIN_DIR . 'includes/admin/discounts/contextual-help.php';
|
316 |
require_once EDD_PLUGIN_DIR . 'includes/admin/discounts/discount-actions.php';
|
317 |
require_once EDD_PLUGIN_DIR . 'includes/admin/discounts/discount-codes.php';
|
318 |
+
require_once EDD_PLUGIN_DIR . 'includes/admin/import/import-actions.php';
|
319 |
+
require_once EDD_PLUGIN_DIR . 'includes/admin/import/import-functions.php';
|
320 |
require_once EDD_PLUGIN_DIR . 'includes/admin/payments/actions.php';
|
321 |
require_once EDD_PLUGIN_DIR . 'includes/admin/payments/payments-history.php';
|
322 |
require_once EDD_PLUGIN_DIR . 'includes/admin/payments/contextual-help.php';
|
includes/EDD_SL_Plugin_Updater.php
CHANGED
@@ -294,8 +294,6 @@ class EDD_SL_Plugin_Updater {
|
|
294 |
*/
|
295 |
private function api_request( $_action, $_data ) {
|
296 |
|
297 |
-
global $wp_version;
|
298 |
-
|
299 |
$data = array_merge( $this->api_data, $_data );
|
300 |
|
301 |
if ( $data['slug'] != $this->slug ) {
|
294 |
*/
|
295 |
private function api_request( $_action, $_data ) {
|
296 |
|
|
|
|
|
297 |
$data = array_merge( $this->api_data, $_data );
|
298 |
|
299 |
if ( $data['slug'] != $this->slug ) {
|
includes/admin/add-ons.php
CHANGED
@@ -29,7 +29,7 @@ function edd_add_ons_page() {
|
|
29 |
<h1>
|
30 |
<?php _e( 'Extensions for Easy Digital Downloads', 'easy-digital-downloads' ); ?>
|
31 |
<span>
|
32 |
-
<a href="
|
33 |
</span>
|
34 |
</h1>
|
35 |
<p><?php _e( 'These extensions <em><strong>add functionality</strong></em> to your Easy Digital Downloads powered store.', 'easy-digital-downloads' ); ?></p>
|
@@ -44,7 +44,7 @@ function edd_add_ons_page() {
|
|
44 |
|
45 |
$active = $active_tab == $tab_id ? ' nav-tab-active' : '';
|
46 |
|
47 |
-
echo '<a href="' . esc_url( $tab_url ) . '"
|
48 |
echo esc_html( $tab_name );
|
49 |
echo '</a>';
|
50 |
}
|
@@ -55,7 +55,7 @@ function edd_add_ons_page() {
|
|
55 |
<?php echo edd_add_ons_get_feed( $active_tab ); ?>
|
56 |
<div class="clear"></div>
|
57 |
<div class="edd-add-ons-footer">
|
58 |
-
<a href="
|
59 |
</div>
|
60 |
</div><!-- #tab_container-->
|
61 |
</div>
|
29 |
<h1>
|
30 |
<?php _e( 'Extensions for Easy Digital Downloads', 'easy-digital-downloads' ); ?>
|
31 |
<span>
|
32 |
+
<a href="http://easydigitaldownloads.com/extensions/?utm_source=plugin-addons-page&utm_medium=plugin&utm_campaign=EDD%20Addons%20Page&utm_content=All%20Extensions" class="button-primary" target="_blank"><?php _e( 'Browse All Extensions', 'easy-digital-downloads' ); ?></a>
|
33 |
</span>
|
34 |
</h1>
|
35 |
<p><?php _e( 'These extensions <em><strong>add functionality</strong></em> to your Easy Digital Downloads powered store.', 'easy-digital-downloads' ); ?></p>
|
44 |
|
45 |
$active = $active_tab == $tab_id ? ' nav-tab-active' : '';
|
46 |
|
47 |
+
echo '<a href="' . esc_url( $tab_url ) . '" class="nav-tab' . $active . '">';
|
48 |
echo esc_html( $tab_name );
|
49 |
echo '</a>';
|
50 |
}
|
55 |
<?php echo edd_add_ons_get_feed( $active_tab ); ?>
|
56 |
<div class="clear"></div>
|
57 |
<div class="edd-add-ons-footer">
|
58 |
+
<a href="http://easydigitaldownloads.com/extensions/?utm_source=plugin-addons-page&utm_medium=plugin&utm_campaign=EDD%20Addons%20Page&utm_content=All%20Extensions" class="button-primary" target="_blank"><?php _e( 'Browse All Extensions', 'easy-digital-downloads' ); ?></a>
|
59 |
</div>
|
60 |
</div><!-- #tab_container-->
|
61 |
</div>
|
includes/admin/class-edd-notices.php
CHANGED
@@ -189,6 +189,21 @@ class EDD_Notices {
|
|
189 |
case 'user-verified' :
|
190 |
$notices['updated']['edd-user-verified'] = __( 'User successfully verified', 'easy-digital-downloads' );
|
191 |
break;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
192 |
}
|
193 |
}
|
194 |
|
189 |
case 'user-verified' :
|
190 |
$notices['updated']['edd-user-verified'] = __( 'User successfully verified', 'easy-digital-downloads' );
|
191 |
break;
|
192 |
+
case 'email-added' :
|
193 |
+
$notices['updated']['edd-customer-email-added'] = __( 'Customer email added', 'easy-digital-downloads' );
|
194 |
+
break;
|
195 |
+
case 'email-removed' :
|
196 |
+
$notices['updated']['edd-customer-email-removed'] = __( 'Customer email removed', 'easy-digital-downloads');
|
197 |
+
break;
|
198 |
+
case 'email-remove-failed' :
|
199 |
+
$notices['error']['edd-customer-email-remove-failed'] = __( 'Failed to remove customer email', 'easy-digital-downloads');
|
200 |
+
break;
|
201 |
+
case 'primary-email-updated' :
|
202 |
+
$notices['updated']['edd-customer-primary-email-updated'] = __( 'Primary email updated for customer', 'easy-digital-downloads');
|
203 |
+
break;
|
204 |
+
case 'primary-email-failed' :
|
205 |
+
$notices['error']['edd-customer-primary-email-failed'] = __( 'Failed to set primary email', 'easy-digital-downloads');
|
206 |
+
break;
|
207 |
}
|
208 |
}
|
209 |
|
includes/admin/customers/class-customer-table.php
CHANGED
@@ -50,6 +50,14 @@ class EDD_Customer_Reports_Table extends WP_List_Table {
|
|
50 |
*/
|
51 |
public $total = 0;
|
52 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
53 |
/**
|
54 |
* Get things started
|
55 |
*
|
@@ -169,7 +177,7 @@ class EDD_Customer_Reports_Table extends WP_List_Table {
|
|
169 |
public function get_columns() {
|
170 |
$columns = array(
|
171 |
'name' => __( 'Name', 'easy-digital-downloads' ),
|
172 |
-
'email' => __( 'Email', 'easy-digital-downloads' ),
|
173 |
'num_purchases' => __( 'Purchases', 'easy-digital-downloads' ),
|
174 |
'amount_spent' => __( 'Total Spent', 'easy-digital-downloads' ),
|
175 |
'date_created' => __( 'Date Created', 'easy-digital-downloads' ),
|
@@ -264,7 +272,8 @@ class EDD_Customer_Reports_Table extends WP_List_Table {
|
|
264 |
$args['name'] = $search;
|
265 |
}
|
266 |
|
267 |
-
$
|
|
|
268 |
|
269 |
if ( $customers ) {
|
270 |
|
@@ -308,7 +317,7 @@ class EDD_Customer_Reports_Table extends WP_List_Table {
|
|
308 |
|
309 |
$this->items = $this->reports_data();
|
310 |
|
311 |
-
$this->total = edd_count_total_customers();
|
312 |
|
313 |
$this->set_pagination_args( array(
|
314 |
'total_items' => $this->total,
|
50 |
*/
|
51 |
public $total = 0;
|
52 |
|
53 |
+
/**
|
54 |
+
* The arguments for the data set
|
55 |
+
*
|
56 |
+
* @var array
|
57 |
+
* @since 2.6
|
58 |
+
*/
|
59 |
+
public $args = array();
|
60 |
+
|
61 |
/**
|
62 |
* Get things started
|
63 |
*
|
177 |
public function get_columns() {
|
178 |
$columns = array(
|
179 |
'name' => __( 'Name', 'easy-digital-downloads' ),
|
180 |
+
'email' => __( 'Primary Email', 'easy-digital-downloads' ),
|
181 |
'num_purchases' => __( 'Purchases', 'easy-digital-downloads' ),
|
182 |
'amount_spent' => __( 'Total Spent', 'easy-digital-downloads' ),
|
183 |
'date_created' => __( 'Date Created', 'easy-digital-downloads' ),
|
272 |
$args['name'] = $search;
|
273 |
}
|
274 |
|
275 |
+
$this->args = $args;
|
276 |
+
$customers = EDD()->customers->get_customers( $args );
|
277 |
|
278 |
if ( $customers ) {
|
279 |
|
317 |
|
318 |
$this->items = $this->reports_data();
|
319 |
|
320 |
+
$this->total = edd_count_total_customers( $this->args );
|
321 |
|
322 |
$this->set_pagination_args( array(
|
323 |
'total_items' => $this->total,
|
includes/admin/customers/customer-actions.php
CHANGED
@@ -154,6 +154,199 @@ function edd_edit_customer( $args ) {
|
|
154 |
}
|
155 |
add_action( 'edd_edit-customer', 'edd_edit_customer', 10, 1 );
|
156 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
157 |
/**
|
158 |
* Save a customer note being added
|
159 |
*
|
154 |
}
|
155 |
add_action( 'edd_edit-customer', 'edd_edit_customer', 10, 1 );
|
156 |
|
157 |
+
|
158 |
+
/**
|
159 |
+
* Add an email address to the customer from within the admin and log a customer note
|
160 |
+
*
|
161 |
+
* @since 2.6
|
162 |
+
* @param array $args Array of arguments: nonce, customer id, and email address
|
163 |
+
* @return mixed If DOING_AJAX echos out JSON, otherwise returns array of success (bool) and message (string)
|
164 |
+
*/
|
165 |
+
function edd_add_customer_email( $args ) {
|
166 |
+
$customer_edit_role = apply_filters( 'edd_edit_customers_role', 'edit_shop_payments' );
|
167 |
+
|
168 |
+
if ( ! is_admin() || ! current_user_can( $customer_edit_role ) ) {
|
169 |
+
wp_die( __( 'You do not have permission to edit this customer.', 'easy-digital-downloads' ) );
|
170 |
+
}
|
171 |
+
|
172 |
+
$output = array();
|
173 |
+
|
174 |
+
if ( empty( $args ) || empty( $args['email'] ) || empty( $args['customer_id'] ) ) {
|
175 |
+
|
176 |
+
$output['success'] = false;
|
177 |
+
|
178 |
+
if ( empty( $args['email'] ) ) {
|
179 |
+
$output['message'] = __( 'Email address is required.', 'easy-digital-downloads' );
|
180 |
+
} else if ( empty( $args['customer_id'] ) ) {
|
181 |
+
$output['message'] = __( 'Customer ID is required.', 'easy-digital-downloads' );
|
182 |
+
} else {
|
183 |
+
$output['message'] = __( 'An error has occured. Please try again.', 'easy-digital-downloads' );
|
184 |
+
}
|
185 |
+
|
186 |
+
} else if ( ! wp_verify_nonce( $args['_wpnonce'], 'edd-add-customer-email' ) ) {
|
187 |
+
|
188 |
+
$output = array(
|
189 |
+
'success' => false,
|
190 |
+
'message' => __( 'Nonce verification failed.', 'easy-digital-downloads' ),
|
191 |
+
);
|
192 |
+
|
193 |
+
} else if ( ! is_email( $args['email'] ) ) {
|
194 |
+
|
195 |
+
$output = array(
|
196 |
+
'success' => false,
|
197 |
+
'message' => __( 'Invalid email address.', 'easy-digital-downloads' ),
|
198 |
+
);
|
199 |
+
|
200 |
+
} else {
|
201 |
+
|
202 |
+
$email = sanitize_email($args['email'] );
|
203 |
+
$customer_id = (int) $args['customer_id'];
|
204 |
+
$primary = 'true' === $args['primary'] ? true : false;
|
205 |
+
$customer = new EDD_Customer( $customer_id );
|
206 |
+
|
207 |
+
if ( false === $customer->add_email( $email, $primary ) ) {
|
208 |
+
|
209 |
+
if ( in_array( $email, $customer->emails ) ) {
|
210 |
+
|
211 |
+
$output = array(
|
212 |
+
'success' => false,
|
213 |
+
'message' => __( 'Email already assocaited with this customer.', 'easy-digital-downloads' ),
|
214 |
+
);
|
215 |
+
|
216 |
+
} else {
|
217 |
+
|
218 |
+
$output = array(
|
219 |
+
'success' => false,
|
220 |
+
'message' => __( 'Email address is already associated with another customer.', 'easy-digital-downloads' ),
|
221 |
+
);
|
222 |
+
|
223 |
+
}
|
224 |
+
|
225 |
+
} else {
|
226 |
+
|
227 |
+
$redirect = admin_url( 'edit.php?post_type=download&page=edd-customers&view=overview&id=' . $customer_id . '&edd-message=email-added' );
|
228 |
+
$output = array(
|
229 |
+
'success' => true,
|
230 |
+
'message' => __( 'Email successfully added to customer.', 'easy-digital-downloads' ),
|
231 |
+
'redirect' => $redirect,
|
232 |
+
);
|
233 |
+
|
234 |
+
$user = wp_get_current_user();
|
235 |
+
$user_login = ! empty( $user->user_login ) ? $user->user_login : 'EDDBot';
|
236 |
+
$customer_note = __( sprintf( 'Email address %s added by %s', $email, $user_login ), 'easy-digital-downloads' );
|
237 |
+
$customer->add_note( $customer_note );
|
238 |
+
|
239 |
+
if ( $primary ) {
|
240 |
+
$customer_note = __( sprintf( 'Email address %s set as primary by %s', $email, $user_login ), 'easy-digital-downloads' );
|
241 |
+
$customer->add_note( $customer_note );
|
242 |
+
}
|
243 |
+
|
244 |
+
|
245 |
+
}
|
246 |
+
|
247 |
+
}
|
248 |
+
|
249 |
+
do_action( 'edd_post_add_customer_email', $customer_id, $args );
|
250 |
+
|
251 |
+
if ( defined( 'DOING_AJAX' ) && DOING_AJAX ) {
|
252 |
+
header( 'Content-Type: application/json' );
|
253 |
+
echo json_encode( $output );
|
254 |
+
wp_die();
|
255 |
+
}
|
256 |
+
|
257 |
+
return $output;
|
258 |
+
|
259 |
+
}
|
260 |
+
add_action( 'edd_customer-add-email', 'edd_add_customer_email', 10, 1 );
|
261 |
+
|
262 |
+
/**
|
263 |
+
* Remove an email address to the customer from within the admin and log a customer note
|
264 |
+
* and redirect back to the customer interface for feedback
|
265 |
+
*
|
266 |
+
* @since 2.6
|
267 |
+
* @return void
|
268 |
+
*/
|
269 |
+
function edd_remove_customer_email() {
|
270 |
+
if ( empty( $_GET['id'] ) || ! is_numeric( $_GET['id'] ) ) {
|
271 |
+
return false;
|
272 |
+
}
|
273 |
+
|
274 |
+
if ( empty( $_GET['email'] ) || ! is_email( $_GET['email'] ) ) {
|
275 |
+
return false;
|
276 |
+
}
|
277 |
+
|
278 |
+
if ( empty( $_GET['_wpnonce'] ) ) {
|
279 |
+
return false;
|
280 |
+
}
|
281 |
+
|
282 |
+
$nonce = $_GET['_wpnonce'];
|
283 |
+
if ( ! wp_verify_nonce( $nonce, 'edd-remove-customer-email' ) ) {
|
284 |
+
wp_die( __( 'Nonce verification failed', 'easy-digital-downloads' ), __( 'Error', 'easy-digital-downloads' ), array( 'response' => 403 ) );
|
285 |
+
}
|
286 |
+
|
287 |
+
$customer = new EDD_Customer( $_GET['id'] );
|
288 |
+
if ( $customer->remove_email( $_GET['email'] ) ) {
|
289 |
+
|
290 |
+
$url = add_query_arg( 'edd-message', 'email-removed', admin_url( 'edit.php?post_type=download&page=edd-customers&view=overview&id=' . $customer->id ) );
|
291 |
+
|
292 |
+
$user = wp_get_current_user();
|
293 |
+
$user_login = ! empty( $user->user_login ) ? $user->user_login : 'EDDBot';
|
294 |
+
$customer_note = __( sprintf( 'Email address %s removed by %s', $_GET['email'], $user_login ), 'easy-digital-downloads' );
|
295 |
+
$customer->add_note( $customer_note );
|
296 |
+
|
297 |
+
} else {
|
298 |
+
$url = add_query_arg( 'edd-message', 'email-remove-failed', admin_url( 'edit.php?post_type=download&page=edd-customers&view=overview&id=' . $customer->id ) );
|
299 |
+
}
|
300 |
+
|
301 |
+
wp_safe_redirect( $url );
|
302 |
+
exit;
|
303 |
+
}
|
304 |
+
add_action( 'edd_customer-remove-email', 'edd_remove_customer_email', 10 );
|
305 |
+
|
306 |
+
/**
|
307 |
+
* Set an email address as the primary for a customer from within the admin and log a customer note
|
308 |
+
* and redirect back to the customer interface for feedback
|
309 |
+
*
|
310 |
+
* @since 2.6
|
311 |
+
* @return void
|
312 |
+
*/
|
313 |
+
function edd_set_customer_primary_email() {
|
314 |
+
if ( empty( $_GET['id'] ) || ! is_numeric( $_GET['id'] ) ) {
|
315 |
+
return false;
|
316 |
+
}
|
317 |
+
|
318 |
+
if ( empty( $_GET['email'] ) || ! is_email( $_GET['email'] ) ) {
|
319 |
+
return false;
|
320 |
+
}
|
321 |
+
|
322 |
+
if ( empty( $_GET['_wpnonce'] ) ) {
|
323 |
+
return false;
|
324 |
+
}
|
325 |
+
|
326 |
+
$nonce = $_GET['_wpnonce'];
|
327 |
+
if ( ! wp_verify_nonce( $nonce, 'edd-set-customer-primary-email' ) ) {
|
328 |
+
wp_die( __( 'Nonce verification failed', 'easy-digital-downloads' ), __( 'Error', 'easy-digital-downloads' ), array( 'response' => 403 ) );
|
329 |
+
}
|
330 |
+
|
331 |
+
$customer = new EDD_Customer( $_GET['id'] );
|
332 |
+
if ( $customer->set_primary_email( $_GET['email'] ) ) {
|
333 |
+
|
334 |
+
$url = add_query_arg( 'edd-message', 'primary-email-updated', admin_url( 'edit.php?post_type=download&page=edd-customers&view=overview&id=' . $customer->id ) );
|
335 |
+
|
336 |
+
$user = wp_get_current_user();
|
337 |
+
$user_login = ! empty( $user->user_login ) ? $user->user_login : 'EDDBot';
|
338 |
+
$customer_note = __( sprintf( 'Email address %s set as primary by %s', $_GET['email'], $user_login ), 'easy-digital-downloads' );
|
339 |
+
$customer->add_note( $customer_note );
|
340 |
+
|
341 |
+
} else {
|
342 |
+
$url = add_query_arg( 'edd-message', 'primary-email-failed', admin_url( 'edit.php?post_type=download&page=edd-customers&view=overview&id=' . $customer->id ) );
|
343 |
+
}
|
344 |
+
|
345 |
+
wp_safe_redirect( $url );
|
346 |
+
exit;
|
347 |
+
}
|
348 |
+
add_action( 'edd_customer-primary-email', 'edd_set_customer_primary_email', 10 );
|
349 |
+
|
350 |
/**
|
351 |
* Save a customer note being added
|
352 |
*
|
includes/admin/customers/customers.php
CHANGED
@@ -127,15 +127,16 @@ function edd_render_customer_view( $view, $callbacks ) {
|
|
127 |
<?php $active = $key === $view ? true : false; ?>
|
128 |
<?php $class = $active ? 'active' : 'inactive'; ?>
|
129 |
|
|
|
130 |
<?php if ( ! $active ) : ?>
|
131 |
-
|
132 |
<?php endif; ?>
|
133 |
-
|
134 |
-
|
135 |
-
|
136 |
<?php if ( ! $active ) : ?>
|
137 |
-
|
138 |
<?php endif; ?>
|
|
|
139 |
|
140 |
<?php endforeach; ?>
|
141 |
</ul>
|
@@ -177,7 +178,7 @@ function edd_customers_view( $customer ) {
|
|
177 |
<div class="avatar-wrap left" id="customer-avatar">
|
178 |
<?php echo get_avatar( $customer->email ); ?><br />
|
179 |
<?php if ( current_user_can( $customer_edit_role ) ): ?>
|
180 |
-
<span class="info-item editable customer-edit-link"><a
|
181 |
<?php endif; ?>
|
182 |
</div>
|
183 |
|
@@ -289,7 +290,7 @@ function edd_customers_view( $customer ) {
|
|
289 |
<span data-key="user_id"><?php _e( 'none', 'easy-digital-downloads' ); ?></span>
|
290 |
<?php endif; ?>
|
291 |
<?php if ( current_user_can( $customer_edit_role ) && intval( $customer->user_id ) > 0 ) : ?>
|
292 |
-
<span class="disconnect-user"> - <a id="disconnect-customer" href="#disconnect"
|
293 |
<?php endif; ?>
|
294 |
</span>
|
295 |
|
@@ -313,7 +314,7 @@ function edd_customers_view( $customer ) {
|
|
313 |
<div id="edd-item-stats-wrapper" class="customer-stats-wrapper customer-section">
|
314 |
<ul>
|
315 |
<li>
|
316 |
-
<a
|
317 |
<span class="dashicons dashicons-cart"></span>
|
318 |
<?php printf( _n( '%d Completed Sale', '%d Completed Sales', $customer->purchase_count, 'easy-digital-downloads' ), $customer->purchase_count ); ?>
|
319 |
</a>
|
@@ -332,6 +333,73 @@ function edd_customers_view( $customer ) {
|
|
332 |
|
333 |
<?php do_action( 'edd_customer_before_tables', $customer ); ?>
|
334 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
335 |
<h3><?php _e( 'Recent Payments', 'easy-digital-downloads' ); ?></h3>
|
336 |
<?php
|
337 |
$payment_ids = explode( ',', $customer->payment_ids );
|
@@ -357,7 +425,7 @@ function edd_customers_view( $customer ) {
|
|
357 |
<td><?php echo date_i18n( get_option( 'date_format' ), strtotime( $payment->post_date ) ); ?></td>
|
358 |
<td><?php echo edd_get_payment_status( $payment, true ); ?></td>
|
359 |
<td>
|
360 |
-
<a
|
361 |
<?php _e( 'View Details', 'easy-digital-downloads' ); ?>
|
362 |
</a>
|
363 |
<?php do_action( 'edd_customer_recent_purchases_actions', $customer, $payment ); ?>
|
@@ -387,7 +455,7 @@ function edd_customers_view( $customer ) {
|
|
387 |
<tr>
|
388 |
<td><?php echo $download->post_title; ?></td>
|
389 |
<td>
|
390 |
-
<a
|
391 |
<?php printf( __( 'View %s', 'easy-digital-downloads' ), edd_get_label_singular() ); ?>
|
392 |
</a>
|
393 |
</td>
|
@@ -585,7 +653,7 @@ function edd_verify_customer_notice( $customer ) {
|
|
585 |
echo '<div class="update error"><p>';
|
586 |
_e( 'This customer\'s user account is pending verification.', 'easy-digital-downloads' );
|
587 |
echo ' ';
|
588 |
-
echo '<a href="' . $url . '"
|
589 |
echo "\n\n";
|
590 |
|
591 |
echo '</p></div>';
|
127 |
<?php $active = $key === $view ? true : false; ?>
|
128 |
<?php $class = $active ? 'active' : 'inactive'; ?>
|
129 |
|
130 |
+
<li class="<?php echo sanitize_html_class( $class ); ?>">
|
131 |
<?php if ( ! $active ) : ?>
|
132 |
+
<a href="<?php echo esc_url( admin_url( 'edit.php?post_type=download&page=edd-customers&view=' . $key . '&id=' . $customer->id . '#wpbody-content' ) ); ?>">
|
133 |
<?php endif; ?>
|
134 |
+
<span class="dashicons <?php echo sanitize_html_class( $tab['dashicon'] ); ?>" aria-hidden="true"></span>
|
135 |
+
<span class="screen-reader-text"><?php echo esc_attr( $tab['title'] ); ?></span>
|
|
|
136 |
<?php if ( ! $active ) : ?>
|
137 |
+
</a>
|
138 |
<?php endif; ?>
|
139 |
+
</li>
|
140 |
|
141 |
<?php endforeach; ?>
|
142 |
</ul>
|
178 |
<div class="avatar-wrap left" id="customer-avatar">
|
179 |
<?php echo get_avatar( $customer->email ); ?><br />
|
180 |
<?php if ( current_user_can( $customer_edit_role ) ): ?>
|
181 |
+
<span class="info-item editable customer-edit-link"><a href="#" id="edit-customer"><?php _e( 'Edit Customer', 'easy-digital-downloads' ); ?></a></span>
|
182 |
<?php endif; ?>
|
183 |
</div>
|
184 |
|
290 |
<span data-key="user_id"><?php _e( 'none', 'easy-digital-downloads' ); ?></span>
|
291 |
<?php endif; ?>
|
292 |
<?php if ( current_user_can( $customer_edit_role ) && intval( $customer->user_id ) > 0 ) : ?>
|
293 |
+
<span class="disconnect-user"> - <a id="disconnect-customer" href="#disconnect"><?php _e( 'Disconnect User', 'easy-digital-downloads' ); ?></a></span>
|
294 |
<?php endif; ?>
|
295 |
</span>
|
296 |
|
314 |
<div id="edd-item-stats-wrapper" class="customer-stats-wrapper customer-section">
|
315 |
<ul>
|
316 |
<li>
|
317 |
+
<a href="<?php echo admin_url( 'edit.php?post_type=download&page=edd-payment-history&customer=' . $customer->id ); ?>">
|
318 |
<span class="dashicons dashicons-cart"></span>
|
319 |
<?php printf( _n( '%d Completed Sale', '%d Completed Sales', $customer->purchase_count, 'easy-digital-downloads' ), $customer->purchase_count ); ?>
|
320 |
</a>
|
333 |
|
334 |
<?php do_action( 'edd_customer_before_tables', $customer ); ?>
|
335 |
|
336 |
+
<h3>
|
337 |
+
<?php _e( 'Customer Emails', 'easy-digital-downloads' ); ?>
|
338 |
+
<span alt="f223" class="edd-help-tip dashicons dashicons-editor-help" title="<?php _e( 'This customer can use any of the emails listed here when making new purchases.', 'easy-digital-downloads' ); ?>"></span>
|
339 |
+
</h3>
|
340 |
+
<?php
|
341 |
+
$primary_email = $customer->email;
|
342 |
+
$additional_emails = $customer->emails;
|
343 |
+
|
344 |
+
$all_emails = array( 'primary' => $primary_email );
|
345 |
+
foreach ( $additional_emails as $key => $email ) {
|
346 |
+
if ( $primary_email === $email ) {
|
347 |
+
continue;
|
348 |
+
}
|
349 |
+
|
350 |
+
$all_emails[ $key ] = $email;
|
351 |
+
}
|
352 |
+
?>
|
353 |
+
<table class="wp-list-table widefat striped emails">
|
354 |
+
<thead>
|
355 |
+
<tr>
|
356 |
+
<th><?php _e( 'Email', 'easy-digital-downloads' ); ?></th>
|
357 |
+
<th><?php _e( 'Actions', 'easy-digital-downloads' ); ?></th>
|
358 |
+
</tr>
|
359 |
+
</thead>
|
360 |
+
<tbody>
|
361 |
+
<?php if ( ! empty( $all_emails ) ) : ?>
|
362 |
+
<?php foreach ( $all_emails as $key => $email ) : ?>
|
363 |
+
<tr data-key="<?php echo $key; ?>">
|
364 |
+
<td>
|
365 |
+
<?php echo $email; ?>
|
366 |
+
<?php if ( 'primary' === $key ) : ?>
|
367 |
+
<span class="dashicons dashicons-star-filled primary-email-icon"></span>
|
368 |
+
<?php endif; ?>
|
369 |
+
</td>
|
370 |
+
<td>
|
371 |
+
<?php if ( 'primary' !== $key ) : ?>
|
372 |
+
<?php
|
373 |
+
$base_url = admin_url( 'edit.php?post_type=download&page=edd-customers&view=overview&id=' . $customer->id );
|
374 |
+
$promote_url = wp_nonce_url( add_query_arg( array( 'email' => rawurlencode( $email ), 'edd_action' => 'customer-primary-email'), $base_url ), 'edd-set-customer-primary-email' );
|
375 |
+
$remove_url = wp_nonce_url( add_query_arg( array( 'email' => rawurlencode( $email ), 'edd_action' => 'customer-remove-email'), $base_url ), 'edd-remove-customer-email' );
|
376 |
+
?>
|
377 |
+
<a href="<?php echo $promote_url; ?>"><?php _e( 'Make Primary', 'easy-digital-downloads' ); ?></a>
|
378 |
+
|
|
379 |
+
<a href="<?php echo $remove_url; ?>" class="delete"><?php _e( 'Remove', 'easy-digital-downloads' ); ?></a>
|
380 |
+
<?php endif; ?>
|
381 |
+
</td>
|
382 |
+
</tr>
|
383 |
+
<?php endforeach; ?>
|
384 |
+
<tr class="add-customer-email-row">
|
385 |
+
<td colspan="2" class="add-customer-email-td">
|
386 |
+
<div class="add-customer-email-wrapper">
|
387 |
+
<input type="hidden" name="customer-id" value="<?php echo $customer->id; ?>" />
|
388 |
+
<?php wp_nonce_field( 'edd-add-customer-email', 'add_email_nonce', false, true ); ?>
|
389 |
+
<input type="email" name="additional-email" value="" placeholder="<?php _e( 'Email Address', 'easy-digital-downloads' ); ?>" />
|
390 |
+
<input type="checkbox" name="make-additional-primary" value="1" id="make-additional-primary" /> <label for="make-additional-primary"><?php _e( 'Make Primary', 'easy-digital-downloads' ); ?></label>
|
391 |
+
<button class="button-secondary edd-add-customer-email" id="add-customer-email" style="margin: 6px 0;"><?php _e( 'Add Email', 'easy-digital-downloads' ); ?></button>
|
392 |
+
<span class="spinner"></span>
|
393 |
+
</div>
|
394 |
+
<div class="notice-wrap"></div>
|
395 |
+
</td>
|
396 |
+
</tr>
|
397 |
+
<?php else: ?>
|
398 |
+
<tr><td colspan="2"><?php _e( 'No Emails Found', 'easy-digital-downloads' ); ?></td></tr>
|
399 |
+
<?php endif; ?>
|
400 |
+
</tbody>
|
401 |
+
</table>
|
402 |
+
|
403 |
<h3><?php _e( 'Recent Payments', 'easy-digital-downloads' ); ?></h3>
|
404 |
<?php
|
405 |
$payment_ids = explode( ',', $customer->payment_ids );
|
425 |
<td><?php echo date_i18n( get_option( 'date_format' ), strtotime( $payment->post_date ) ); ?></td>
|
426 |
<td><?php echo edd_get_payment_status( $payment, true ); ?></td>
|
427 |
<td>
|
428 |
+
<a href="<?php echo admin_url( 'edit.php?post_type=download&page=edd-payment-history&view=view-order-details&id=' . $payment->ID ); ?>">
|
429 |
<?php _e( 'View Details', 'easy-digital-downloads' ); ?>
|
430 |
</a>
|
431 |
<?php do_action( 'edd_customer_recent_purchases_actions', $customer, $payment ); ?>
|
455 |
<tr>
|
456 |
<td><?php echo $download->post_title; ?></td>
|
457 |
<td>
|
458 |
+
<a href="<?php echo esc_url( admin_url( 'post.php?action=edit&post=' . $download->ID ) ); ?>">
|
459 |
<?php printf( __( 'View %s', 'easy-digital-downloads' ), edd_get_label_singular() ); ?>
|
460 |
</a>
|
461 |
</td>
|
653 |
echo '<div class="update error"><p>';
|
654 |
_e( 'This customer\'s user account is pending verification.', 'easy-digital-downloads' );
|
655 |
echo ' ';
|
656 |
+
echo '<a href="' . $url . '">' . __( 'Verify account.', 'easy-digital-downloads' ) . '</a>';
|
657 |
echo "\n\n";
|
658 |
|
659 |
echo '</p></div>';
|
includes/admin/dashboard-widgets.php
CHANGED
@@ -171,7 +171,7 @@ function edd_load_dashboard_sales_widget( ) {
|
|
171 |
foreach ( $payments as $payment ) { ?>
|
172 |
<tr>
|
173 |
<td class="edd_order_label">
|
174 |
-
<a href="<?php echo add_query_arg( 'id', $payment->ID, admin_url( 'edit.php?post_type=download&page=edd-payment-history&view=view-order-details' ) ); ?>"
|
175 |
<?php echo get_the_title( $payment->ID ) ?>
|
176 |
— <?php echo $payment->user_info['email'] ?>
|
177 |
</a>
|
@@ -183,7 +183,7 @@ function edd_load_dashboard_sales_widget( ) {
|
|
183 |
} ?>
|
184 |
</td>
|
185 |
<td class="edd_order_price">
|
186 |
-
<a href="<?php echo add_query_arg( 'id', $payment->ID, admin_url( 'edit.php?post_type=download&page=edd-payment-history&view=view-order-details' ) ); ?>"
|
187 |
<span class="edd_price_label"><?php echo edd_currency_filter( edd_format_amount( $payment->total ), edd_get_payment_currency_code( $payment->ID ) ); ?></span>
|
188 |
</a>
|
189 |
</td>
|
171 |
foreach ( $payments as $payment ) { ?>
|
172 |
<tr>
|
173 |
<td class="edd_order_label">
|
174 |
+
<a href="<?php echo add_query_arg( 'id', $payment->ID, admin_url( 'edit.php?post_type=download&page=edd-payment-history&view=view-order-details' ) ); ?>">
|
175 |
<?php echo get_the_title( $payment->ID ) ?>
|
176 |
— <?php echo $payment->user_info['email'] ?>
|
177 |
</a>
|
183 |
} ?>
|
184 |
</td>
|
185 |
<td class="edd_order_price">
|
186 |
+
<a href="<?php echo add_query_arg( 'id', $payment->ID, admin_url( 'edit.php?post_type=download&page=edd-payment-history&view=view-order-details' ) ); ?>">
|
187 |
<span class="edd_price_label"><?php echo edd_currency_filter( edd_format_amount( $payment->total ), edd_get_payment_currency_code( $payment->ID ) ); ?></span>
|
188 |
</a>
|
189 |
</td>
|
includes/admin/discounts/add-discount.php
CHANGED
@@ -94,7 +94,7 @@ if ( ! defined( 'ABSPATH' ) ) exit;
|
|
94 |
</label>
|
95 |
</p>
|
96 |
</div>
|
97 |
-
<p class="description"><?php printf( __( 'Select %s relevant to this discount.', 'easy-digital-downloads' ), edd_get_label_plural() ); ?></p>
|
98 |
</td>
|
99 |
</tr>
|
100 |
<?php do_action( 'edd_add_discount_form_before_excluded_products' ); ?>
|
94 |
</label>
|
95 |
</p>
|
96 |
</div>
|
97 |
+
<p class="description"><?php printf( __( 'Select %s relevant to this discount. If left blank, this discount can be used on any product.', 'easy-digital-downloads' ), edd_get_label_plural() ); ?></p>
|
98 |
</td>
|
99 |
</tr>
|
100 |
<?php do_action( 'edd_add_discount_form_before_excluded_products' ); ?>
|
includes/admin/discounts/edit-discount.php
CHANGED
@@ -109,7 +109,7 @@ $condition_display = empty( $product_reqs ) ? ' style="display:none;"' : '';
|
|
109 |
</label>
|
110 |
</p>
|
111 |
</div>
|
112 |
-
<p class="description"><?php printf( __( 'Select %s relevant to this discount.', 'easy-digital-downloads' ), edd_get_label_plural() ); ?></p>
|
113 |
</td>
|
114 |
</tr>
|
115 |
<?php do_action( 'edd_edit_discount_form_before_excluded_products', $discount_id, $discount ); ?>
|
109 |
</label>
|
110 |
</p>
|
111 |
</div>
|
112 |
+
<p class="description"><?php printf( __( 'Select %s relevant to this discount. If left blank, this discount can be used on any product.', 'easy-digital-downloads' ), edd_get_label_plural() ); ?></p>
|
113 |
</td>
|
114 |
</tr>
|
115 |
<?php do_action( 'edd_edit_discount_form_before_excluded_products', $discount_id, $discount ); ?>
|
includes/admin/downloads/metabox.php
CHANGED
@@ -372,7 +372,7 @@ function edd_render_price_field( $post_id ) {
|
|
372 |
|
373 |
<tr>
|
374 |
<td class="submit" colspan="4" style="float: none; clear:both; background:#fff;">
|
375 |
-
<
|
376 |
</td>
|
377 |
</tr>
|
378 |
</tbody>
|
@@ -452,7 +452,7 @@ function edd_render_price_row( $key, $args = array(), $post_id, $index ) {
|
|
452 |
<?php do_action( 'edd_download_price_table_row', $post_id, $key, $args ); ?>
|
453 |
|
454 |
<td>
|
455 |
-
<
|
456 |
</td>
|
457 |
<?php
|
458 |
}
|
@@ -483,6 +483,7 @@ function edd_render_product_type_field( $post_id = 0 ) {
|
|
483 |
'show_option_none' => false
|
484 |
) ); ?>
|
485 |
<label for="edd_product_type"><?php _e( 'Select a product type', 'easy-digital-downloads' ); ?></label>
|
|
|
486 |
</p>
|
487 |
<?php
|
488 |
}
|
@@ -532,7 +533,7 @@ function edd_render_products_field( $post_id ) {
|
|
532 |
?>
|
533 |
</td>
|
534 |
<td>
|
535 |
-
<
|
536 |
</td>
|
537 |
<?php do_action( 'edd_download_products_table_row', $post_id ); ?>
|
538 |
</tr>
|
@@ -556,14 +557,14 @@ function edd_render_products_field( $post_id ) {
|
|
556 |
?>
|
557 |
</td>
|
558 |
<td>
|
559 |
-
<
|
560 |
</td>
|
561 |
<?php do_action( 'edd_download_products_table_row', $post_id ); ?>
|
562 |
</tr>
|
563 |
<?php endif; ?>
|
564 |
<tr>
|
565 |
<td class="submit" colspan="3" style="float: none; clear:both; background: #fff;">
|
566 |
-
<
|
567 |
</td>
|
568 |
</tr>
|
569 |
</tbody>
|
@@ -607,7 +608,10 @@ function edd_render_files_field( $post_id = 0 ) {
|
|
607 |
<th style="width: 20px"></th>
|
608 |
<th style="width: 20%"><?php _e( 'File Name', 'easy-digital-downloads' ); ?></th>
|
609 |
<th><?php _e( 'File URL', 'easy-digital-downloads' ); ?></th>
|
610 |
-
<th class="pricing" style="width: 20%; <?php echo $variable_display; ?>"
|
|
|
|
|
|
|
611 |
<th style="width: 15px"><?php _e( 'ID', 'easy-digital-downloads' ); ?></th>
|
612 |
<?php do_action( 'edd_download_file_table_head', $post_id ); ?>
|
613 |
<th style="width: 2%"></th>
|
@@ -638,7 +642,7 @@ function edd_render_files_field( $post_id = 0 ) {
|
|
638 |
<?php endif; ?>
|
639 |
<tr>
|
640 |
<td class="submit" colspan="4" style="float: none; clear:both; background: #fff;">
|
641 |
-
<
|
642 |
</td>
|
643 |
</tr>
|
644 |
</tbody>
|
@@ -734,7 +738,7 @@ function edd_render_file_row( $key = '', $args = array(), $post_id, $index ) {
|
|
734 |
<?php do_action( 'edd_download_file_table_row', $post_id, $key, $args ); ?>
|
735 |
|
736 |
<td>
|
737 |
-
<
|
738 |
</td>
|
739 |
<?php
|
740 |
}
|
@@ -792,6 +796,7 @@ function edd_render_download_limit_row( $post_id ) {
|
|
792 |
) ); ?>
|
793 |
<?php _e( 'Leave blank for global setting or 0 for unlimited', 'easy-digital-downloads' ); ?>
|
794 |
</label>
|
|
|
795 |
</div>
|
796 |
<?php
|
797 |
}
|
@@ -845,7 +850,10 @@ function edd_render_meta_box_shortcode() {
|
|
845 |
$color = ( $color == 'inherit' ) ? '' : $color;
|
846 |
$shortcode = '[purchase_link id="' . absint( $post->ID ) . '" text="' . esc_html( $purchase_text ) . '" style="' . $style . '" color="' . esc_attr( $color ) . '"]';
|
847 |
?>
|
848 |
-
<p
|
|
|
|
|
|
|
849 |
<input type="text" id="edd-purchase-shortcode" class="widefat" readonly="readonly" value="<?php echo htmlentities( $shortcode ); ?>">
|
850 |
<?php
|
851 |
}
|
@@ -900,6 +908,7 @@ function edd_render_disable_button( $post_id ) {
|
|
900 |
'current' => $hide_button
|
901 |
) ); ?>
|
902 |
<?php _e( 'Disable the automatic output of the purchase button', 'easy-digital-downloads' ); ?>
|
|
|
903 |
</label>
|
904 |
</p>
|
905 |
<?php if( edd_shop_supports_buy_now() ) : ?>
|
@@ -916,6 +925,7 @@ function edd_render_disable_button( $post_id ) {
|
|
916 |
'selected' => $behavior
|
917 |
) ); ?>
|
918 |
<?php _e( 'Purchase button behavior', 'easy-digital-downloads' ); ?>
|
|
|
919 |
</label>
|
920 |
</p>
|
921 |
<?php
|
372 |
|
373 |
<tr>
|
374 |
<td class="submit" colspan="4" style="float: none; clear:both; background:#fff;">
|
375 |
+
<button class="button-secondary edd_add_repeatable" style="margin: 6px 0;"><?php _e( 'Add New Price', 'easy-digital-downloads' ); ?></button>
|
376 |
</td>
|
377 |
</tr>
|
378 |
</tbody>
|
452 |
<?php do_action( 'edd_download_price_table_row', $post_id, $key, $args ); ?>
|
453 |
|
454 |
<td>
|
455 |
+
<button class="edd_remove_repeatable" data-type="price" style="background: url(<?php echo admin_url('/images/xit.gif'); ?>) no-repeat;"><span class="screen-reader-text"><?php printf( __( 'Remove price option %s', 'easy-digital-downloads' ), $key ); ?></span><span aria-hidden="true">×</span></button>
|
456 |
</td>
|
457 |
<?php
|
458 |
}
|
483 |
'show_option_none' => false
|
484 |
) ); ?>
|
485 |
<label for="edd_product_type"><?php _e( 'Select a product type', 'easy-digital-downloads' ); ?></label>
|
486 |
+
<span alt="f223" class="edd-help-tip dashicons dashicons-editor-help" title="<?php _e( '<strong>Product Type</strong>: Sell this item as a single product, or use the Bundle type to sell a collection of products.', 'easy-digital-downloads' ); ?>"></span>
|
487 |
</p>
|
488 |
<?php
|
489 |
}
|
533 |
?>
|
534 |
</td>
|
535 |
<td>
|
536 |
+
<button class="edd_remove_repeatable" data-type="file" style="background: url(<?php echo admin_url('/images/xit.gif'); ?>) no-repeat;"><span class="screen-reader-text"><?php printf( __( 'Remove bundle option %s', 'easy-digital-downloads' ), $key ); ?></span><span aria-hidden="true">×</span></button>
|
537 |
</td>
|
538 |
<?php do_action( 'edd_download_products_table_row', $post_id ); ?>
|
539 |
</tr>
|
557 |
?>
|
558 |
</td>
|
559 |
<td>
|
560 |
+
<button class="edd_remove_repeatable" data-type="file" style="background: url(<?php echo admin_url('/images/xit.gif'); ?>) no-repeat;"><span class="screen-reader-text"><?php echo __( 'Remove bundle option', 'easy-digital-downloads' ); ?></span><span aria-hidden="true">×</span></button>
|
561 |
</td>
|
562 |
<?php do_action( 'edd_download_products_table_row', $post_id ); ?>
|
563 |
</tr>
|
564 |
<?php endif; ?>
|
565 |
<tr>
|
566 |
<td class="submit" colspan="3" style="float: none; clear:both; background: #fff;">
|
567 |
+
<button class="button-secondary edd_add_repeatable" style="margin: 6px 0 10px;"><?php _e( 'Add New File', 'easy-digital-downloads' ); ?></button>
|
568 |
</td>
|
569 |
</tr>
|
570 |
</tbody>
|
608 |
<th style="width: 20px"></th>
|
609 |
<th style="width: 20%"><?php _e( 'File Name', 'easy-digital-downloads' ); ?></th>
|
610 |
<th><?php _e( 'File URL', 'easy-digital-downloads' ); ?></th>
|
611 |
+
<th class="pricing" style="width: 20%; <?php echo $variable_display; ?>">
|
612 |
+
<?php _e( 'Price Assignment', 'easy-digital-downloads' ); ?>
|
613 |
+
<span alt="f223" class="edd-help-tip dashicons dashicons-editor-help" title="<?php _e( '<strong>Price Assignment</strong>: With variable pricing enabled, you can choose to allow certain price variations access to specific files, or allow all price variations to access a file.', 'easy-digital-downloads' ); ?>"></span>
|
614 |
+
</th>
|
615 |
<th style="width: 15px"><?php _e( 'ID', 'easy-digital-downloads' ); ?></th>
|
616 |
<?php do_action( 'edd_download_file_table_head', $post_id ); ?>
|
617 |
<th style="width: 2%"></th>
|
642 |
<?php endif; ?>
|
643 |
<tr>
|
644 |
<td class="submit" colspan="4" style="float: none; clear:both; background: #fff;">
|
645 |
+
<button class="button-secondary edd_add_repeatable" style="margin: 6px 0 10px;"><?php _e( 'Add New File', 'easy-digital-downloads' ); ?></button>
|
646 |
</td>
|
647 |
</tr>
|
648 |
</tbody>
|
738 |
<?php do_action( 'edd_download_file_table_row', $post_id, $key, $args ); ?>
|
739 |
|
740 |
<td>
|
741 |
+
<button class="edd_remove_repeatable" data-type="file" style="background: url(<?php echo admin_url('/images/xit.gif'); ?>) no-repeat;"><span class="screen-reader-text"><?php printf( __( 'Remove file option %s', 'easy-digital-downloads' ), $key ); ?></span><span aria-hidden="true">×</span></button>
|
742 |
</td>
|
743 |
<?php
|
744 |
}
|
796 |
) ); ?>
|
797 |
<?php _e( 'Leave blank for global setting or 0 for unlimited', 'easy-digital-downloads' ); ?>
|
798 |
</label>
|
799 |
+
<span alt="f223" class="edd-help-tip dashicons dashicons-editor-help" title="<?php _e( '<strong>File Download Limit</strong>: Limit the number of times a customer who purchased this product can access their download links.', 'easy-digital-downloads' ); ?>"></span>
|
800 |
</div>
|
801 |
<?php
|
802 |
}
|
850 |
$color = ( $color == 'inherit' ) ? '' : $color;
|
851 |
$shortcode = '[purchase_link id="' . absint( $post->ID ) . '" text="' . esc_html( $purchase_text ) . '" style="' . $style . '" color="' . esc_attr( $color ) . '"]';
|
852 |
?>
|
853 |
+
<p>
|
854 |
+
<strong><?php _e( 'Purchase Shortcode:', 'easy-digital-downloads' ); ?></strong>
|
855 |
+
<span alt="f223" class="edd-help-tip dashicons dashicons-editor-help" title="<?php _e( '<strong>Purchse Shortcode</strong>: Use this shortcode to output a purchase link for this product in the location of your choosing.', 'easy-digital-downloads' ); ?>"></span>
|
856 |
+
</p>
|
857 |
<input type="text" id="edd-purchase-shortcode" class="widefat" readonly="readonly" value="<?php echo htmlentities( $shortcode ); ?>">
|
858 |
<?php
|
859 |
}
|
908 |
'current' => $hide_button
|
909 |
) ); ?>
|
910 |
<?php _e( 'Disable the automatic output of the purchase button', 'easy-digital-downloads' ); ?>
|
911 |
+
<span alt="f223" class="edd-help-tip dashicons dashicons-editor-help" title="<?php _e( '<strong>Automatic Output</strong>: By default, the purchase buttons will be displayed at the bottom of the download, when disabled you will need to use the Purchase link shortcode below to output the ability to buy the product where you prefer.', 'easy-digital-downloads' ); ?>"></span>
|
912 |
</label>
|
913 |
</p>
|
914 |
<?php if( edd_shop_supports_buy_now() ) : ?>
|
925 |
'selected' => $behavior
|
926 |
) ); ?>
|
927 |
<?php _e( 'Purchase button behavior', 'easy-digital-downloads' ); ?>
|
928 |
+
<span alt="f223" class="edd-help-tip dashicons dashicons-editor-help" title="<?php _e( '<strong>Button Behavior</strong>: Add to Cart buttons follow a traditional eCommerce flow. A Buy Now button bypasses most of the process, taking the customer directly from button click to payment, greatly speeding up the process of getting the product.', 'easy-digital-downloads' ); ?>"></span>
|
929 |
</label>
|
930 |
</p>
|
931 |
<?php
|
includes/admin/import/class-batch-import-downloads.php
CHANGED
@@ -1,8 +1,8 @@
|
|
1 |
<?php
|
2 |
/**
|
3 |
-
*
|
4 |
*
|
5 |
-
* This class handles importing
|
6 |
*
|
7 |
* @package EDD
|
8 |
* @subpackage Admin/Import
|
@@ -21,7 +21,35 @@ if ( ! defined( 'ABSPATH' ) ) exit;
|
|
21 |
*/
|
22 |
class EDD_Batch_Downloads_Import extends EDD_Batch_Import {
|
23 |
|
24 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
25 |
|
26 |
/**
|
27 |
* Process a step
|
@@ -34,21 +62,29 @@ class EDD_Batch_Downloads_Import extends EDD_Batch_Import {
|
|
34 |
$more = false;
|
35 |
|
36 |
if ( ! $this->can_import() ) {
|
37 |
-
wp_die( __( 'You do not have permission to import data.', '
|
38 |
}
|
39 |
|
40 |
-
$
|
41 |
-
$
|
42 |
|
43 |
-
if( $
|
|
|
|
|
|
|
|
|
44 |
|
45 |
-
$i = 0;
|
46 |
$more = true;
|
47 |
|
48 |
-
foreach( $csv->data as $key => $row ) {
|
|
|
|
|
|
|
|
|
|
|
49 |
|
50 |
// Done with this batch
|
51 |
-
if( $i >=
|
52 |
break;
|
53 |
}
|
54 |
|
@@ -73,81 +109,86 @@ class EDD_Batch_Downloads_Import extends EDD_Batch_Import {
|
|
73 |
$download_id = wp_insert_post( $args );
|
74 |
|
75 |
// setup categories
|
76 |
-
if( ! empty( $row[ $this->field_mapping['categories'] ] ) ) {
|
77 |
|
78 |
$categories = $this->str_to_array( $row[ $this->field_mapping['categories'] ] );
|
79 |
|
80 |
-
|
81 |
-
|
82 |
-
wp_set_object_terms( $download_id, $terms, 'download_category' );
|
83 |
-
|
84 |
-
}
|
85 |
|
86 |
}
|
87 |
|
88 |
-
|
89 |
// setup tags
|
90 |
-
if( ! empty( $row[ $this->field_mapping['tags'] ] ) ) {
|
91 |
|
92 |
$tags = $this->str_to_array( $row[ $this->field_mapping['tags'] ] );
|
93 |
|
94 |
-
|
95 |
-
|
96 |
-
wp_set_object_terms( $download_id, $terms, 'download_tag' );
|
97 |
-
|
98 |
-
}
|
99 |
|
100 |
}
|
101 |
|
102 |
// setup price(s)
|
103 |
-
if( ! empty( $row[ $this->field_mapping['price'] ] ) ) {
|
104 |
|
105 |
$price = $row[ $this->field_mapping['price'] ];
|
106 |
|
107 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
108 |
|
109 |
-
|
110 |
-
|
111 |
-
} else {
|
112 |
|
113 |
-
|
114 |
|
115 |
-
|
|
|
116 |
|
117 |
-
|
118 |
-
foreach( $prices as $price ) {
|
119 |
|
120 |
-
|
121 |
-
if( false !== strpos( $price, ':' ) ) {
|
122 |
|
123 |
-
|
124 |
|
125 |
-
|
|
|
126 |
|
127 |
-
|
|
|
128 |
|
129 |
-
|
|
|
130 |
|
131 |
-
|
|
|
132 |
|
133 |
-
|
|
|
134 |
|
135 |
-
|
|
|
136 |
|
|
|
|
|
|
|
|
|
137 |
}
|
138 |
|
139 |
-
//
|
|
|
140 |
|
|
|
|
|
|
|
|
|
141 |
|
142 |
-
// setup other metadata
|
143 |
|
144 |
-
// Once download is imported, remove row
|
145 |
-
unset( $csv->data[ $key ] );
|
146 |
$i++;
|
147 |
}
|
148 |
|
149 |
-
$csv->save();
|
150 |
-
|
151 |
}
|
152 |
|
153 |
return $more;
|
@@ -161,10 +202,8 @@ class EDD_Batch_Downloads_Import extends EDD_Batch_Import {
|
|
161 |
*/
|
162 |
public function get_percentage_complete() {
|
163 |
|
164 |
-
$total
|
165 |
-
|
166 |
-
if( $total > 0 ) {
|
167 |
-
$percentage = ( $this->step / $total ) * 100;
|
168 |
}
|
169 |
|
170 |
if( $percentage > 100 ) {
|
@@ -174,32 +213,266 @@ class EDD_Batch_Downloads_Import extends EDD_Batch_Import {
|
|
174 |
return $percentage;
|
175 |
}
|
176 |
|
177 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
178 |
|
179 |
-
|
180 |
-
|
181 |
|
182 |
-
|
|
|
183 |
|
184 |
-
|
185 |
|
186 |
-
|
187 |
|
188 |
-
|
|
|
|
|
189 |
|
190 |
-
|
|
|
|
|
|
|
191 |
|
192 |
}
|
193 |
|
194 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
195 |
|
196 |
-
|
197 |
|
198 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
199 |
|
200 |
}
|
201 |
|
202 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
203 |
|
204 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
205 |
}
|
1 |
<?php
|
2 |
/**
|
3 |
+
* Download import class
|
4 |
*
|
5 |
+
* This class handles importing downloads with the batch processing API
|
6 |
*
|
7 |
* @package EDD
|
8 |
* @subpackage Admin/Import
|
21 |
*/
|
22 |
class EDD_Batch_Downloads_Import extends EDD_Batch_Import {
|
23 |
|
24 |
+
/**
|
25 |
+
* Set up our import config.
|
26 |
+
*
|
27 |
+
* @since 2.6
|
28 |
+
* @return void
|
29 |
+
*/
|
30 |
+
public function init() {
|
31 |
+
|
32 |
+
// Set up default field map values
|
33 |
+
$this->field_mapping = array(
|
34 |
+
'post_title' => '',
|
35 |
+
'post_name' => '',
|
36 |
+
'post_status' => 'draft',
|
37 |
+
'post_author' => '',
|
38 |
+
'post_date' => '',
|
39 |
+
'post_content' => '',
|
40 |
+
'post_excerpt' => '',
|
41 |
+
'price' => '',
|
42 |
+
'files' => '',
|
43 |
+
'categories' => '',
|
44 |
+
'tags' => '',
|
45 |
+
'sku' => '',
|
46 |
+
'earnings' => '',
|
47 |
+
'sales' => '',
|
48 |
+
'featured_image' => '',
|
49 |
+
'download_limit' => '',
|
50 |
+
'notes' => ''
|
51 |
+
);
|
52 |
+
}
|
53 |
|
54 |
/**
|
55 |
* Process a step
|
62 |
$more = false;
|
63 |
|
64 |
if ( ! $this->can_import() ) {
|
65 |
+
wp_die( __( 'You do not have permission to import data.', 'easy-digital-downloads' ), __( 'Error', 'easy-digital-downloads' ), array( 'response' => 403 ) );
|
66 |
}
|
67 |
|
68 |
+
$i = 1;
|
69 |
+
$offset = $this->step > 1 ? ( $this->per_step * ( $this->step - 1 ) ) : 0;
|
70 |
|
71 |
+
if( $offset > $this->total ) {
|
72 |
+
$this->done = true;
|
73 |
+
}
|
74 |
+
|
75 |
+
if( ! $this->done && $this->csv->data ) {
|
76 |
|
|
|
77 |
$more = true;
|
78 |
|
79 |
+
foreach( $this->csv->data as $key => $row ) {
|
80 |
+
|
81 |
+
// Skip all rows until we pass our offset
|
82 |
+
if( $key + 1 < $offset ) {
|
83 |
+
continue;
|
84 |
+
}
|
85 |
|
86 |
// Done with this batch
|
87 |
+
if( $i >= $this->per_step ) {
|
88 |
break;
|
89 |
}
|
90 |
|
109 |
$download_id = wp_insert_post( $args );
|
110 |
|
111 |
// setup categories
|
112 |
+
if( ! empty( $this->field_mapping['categories'] ) && ! empty( $row[ $this->field_mapping['categories'] ] ) ) {
|
113 |
|
114 |
$categories = $this->str_to_array( $row[ $this->field_mapping['categories'] ] );
|
115 |
|
116 |
+
$this->set_taxonomy_terms( $download_id, $categories, 'download_category' );
|
|
|
|
|
|
|
|
|
117 |
|
118 |
}
|
119 |
|
|
|
120 |
// setup tags
|
121 |
+
if( ! empty( $this->field_mapping['tags'] ) && ! empty( $row[ $this->field_mapping['tags'] ] ) ) {
|
122 |
|
123 |
$tags = $this->str_to_array( $row[ $this->field_mapping['tags'] ] );
|
124 |
|
125 |
+
$this->set_taxonomy_terms( $download_id, $tags, 'download_tag' );
|
|
|
|
|
|
|
|
|
126 |
|
127 |
}
|
128 |
|
129 |
// setup price(s)
|
130 |
+
if( ! empty( $this->field_mapping['price'] ) && ! empty( $row[ $this->field_mapping['price'] ] ) ) {
|
131 |
|
132 |
$price = $row[ $this->field_mapping['price'] ];
|
133 |
|
134 |
+
$this->set_price( $download_id, $price );
|
135 |
+
|
136 |
+
}
|
137 |
+
|
138 |
+
// setup files
|
139 |
+
if( ! empty( $this->field_mapping['files'] ) && ! empty( $row[ $this->field_mapping['files'] ] ) ) {
|
140 |
+
|
141 |
+
$files = $this->str_to_array( $row[ $this->field_mapping['files'] ] );
|
142 |
|
143 |
+
$this->set_files( $download_id, $files );
|
|
|
|
|
144 |
|
145 |
+
}
|
146 |
|
147 |
+
// Product Image
|
148 |
+
if( ! empty( $this->field_mapping['featured_image'] ) && ! empty( $row[ $this->field_mapping['featured_image'] ] ) ) {
|
149 |
|
150 |
+
$image = sanitize_text_field( $row[ $this->field_mapping['featured_image'] ] );
|
|
|
151 |
|
152 |
+
$this->set_image( $download_id, $image, $args['post_author'] );
|
|
|
153 |
|
154 |
+
}
|
155 |
|
156 |
+
// File download limit
|
157 |
+
if( ! empty( $this->field_mapping['download_limit'] ) && ! empty( $row[ $this->field_mapping['download_limit'] ] ) ) {
|
158 |
|
159 |
+
update_post_meta( $download_id, '_edd_download_limit', absint( $row[ $this->field_mapping['download_limit'] ] ) );
|
160 |
+
}
|
161 |
|
162 |
+
// Sale count
|
163 |
+
if( ! empty( $this->field_mapping['sales'] ) && ! empty( $row[ $this->field_mapping['sales'] ] ) ) {
|
164 |
|
165 |
+
update_post_meta( $download_id, '_edd_download_sales', absint( $row[ $this->field_mapping['sales'] ] ) );
|
166 |
+
}
|
167 |
|
168 |
+
// Earnings
|
169 |
+
if( ! empty( $this->field_mapping['earnings'] ) && ! empty( $row[ $this->field_mapping['earnings'] ] ) ) {
|
170 |
|
171 |
+
update_post_meta( $download_id, '_edd_download_earnings', edd_sanitize_amount( $row[ $this->field_mapping['earnings'] ] ) );
|
172 |
+
}
|
173 |
|
174 |
+
// Notes
|
175 |
+
if( ! empty( $this->field_mapping['notes'] ) && ! empty( $row[ $this->field_mapping['notes'] ] ) ) {
|
176 |
+
|
177 |
+
update_post_meta( $download_id, 'edd_product_notes', sanitize_text_field( $row[ $this->field_mapping['notes'] ] ) );
|
178 |
}
|
179 |
|
180 |
+
// SKU
|
181 |
+
if( ! empty( $this->field_mapping[ 'sku' ] ) && ! empty( $row[ $this->field_mapping[ 'sku' ] ] ) ) {
|
182 |
|
183 |
+
update_post_meta( $download_id, 'edd_sku', sanitize_text_field( $row[ $this->field_mapping['sku'] ] ) );
|
184 |
+
}
|
185 |
+
|
186 |
+
// Custom fields
|
187 |
|
|
|
188 |
|
|
|
|
|
189 |
$i++;
|
190 |
}
|
191 |
|
|
|
|
|
192 |
}
|
193 |
|
194 |
return $more;
|
202 |
*/
|
203 |
public function get_percentage_complete() {
|
204 |
|
205 |
+
if( $this->total > 0 ) {
|
206 |
+
$percentage = ( $this->step / $this->total ) * 100;
|
|
|
|
|
207 |
}
|
208 |
|
209 |
if( $percentage > 100 ) {
|
213 |
return $percentage;
|
214 |
}
|
215 |
|
216 |
+
/**
|
217 |
+
* Set up and store the price for the download
|
218 |
+
*
|
219 |
+
* @since 2.6
|
220 |
+
* @return void
|
221 |
+
*/
|
222 |
+
private function set_price( $download_id = 0, $price = '' ) {
|
223 |
+
|
224 |
+
if( is_numeric( $price ) ) {
|
225 |
+
|
226 |
+
update_post_meta( $download_id, 'edd_price', edd_sanitize_amount( $price ) );
|
227 |
+
|
228 |
+
} else {
|
229 |
+
|
230 |
+
$prices = $this->str_to_array( $price );
|
231 |
+
|
232 |
+
if( ! empty( $prices ) ) {
|
233 |
|
234 |
+
$variable_prices = array();
|
235 |
+
foreach( $prices as $price ) {
|
236 |
|
237 |
+
// See if this matches the EDD Download export for variable prices
|
238 |
+
if( false !== strpos( $price, ':' ) ) {
|
239 |
|
240 |
+
$price = array_map( 'trim', explode( ':', $price ) );
|
241 |
|
242 |
+
$variable_prices[] = array( 'name' => $price[0], 'amount' => $price[1] );
|
243 |
|
244 |
+
}
|
245 |
+
|
246 |
+
}
|
247 |
|
248 |
+
update_post_meta( $download_id, '_variable_pricing', 1 );
|
249 |
+
update_post_meta( $download_id, 'edd_variable_prices', $variable_prices );
|
250 |
+
|
251 |
+
}
|
252 |
|
253 |
}
|
254 |
|
255 |
+
}
|
256 |
+
|
257 |
+
/**
|
258 |
+
* Set up and store the file downloads
|
259 |
+
*
|
260 |
+
* @since 2.6
|
261 |
+
* @return void
|
262 |
+
*/
|
263 |
+
private function set_files( $download_id = 0, $files = array() ) {
|
264 |
|
265 |
+
if( ! empty( $files ) ) {
|
266 |
|
267 |
+
$download_files = array();
|
268 |
+
foreach( $files as $file ) {
|
269 |
+
|
270 |
+
$download_files[] = array( 'file' => $file, 'name' => basename( $file ) );
|
271 |
+
|
272 |
+
}
|
273 |
+
|
274 |
+
update_post_meta( $download_id, 'edd_download_files', $download_files );
|
275 |
|
276 |
}
|
277 |
|
278 |
+
}
|
279 |
+
|
280 |
+
/**
|
281 |
+
* Set up and store the Featured Image
|
282 |
+
*
|
283 |
+
* @since 2.6
|
284 |
+
* @return void
|
285 |
+
*/
|
286 |
+
private function set_image( $download_id = 0, $image = '', $post_author = 0 ) {
|
287 |
+
|
288 |
+
$is_url = false !== filter_var( $image, FILTER_VALIDATE_URL );
|
289 |
+
$is_local = $is_url && false !== strpos( $image, site_url() );
|
290 |
+
$ext = edd_get_file_extension( $image );
|
291 |
+
|
292 |
+
if( $is_url && $is_local ) {
|
293 |
+
|
294 |
+
// Image given by URL, see if we have an attachment already
|
295 |
+
$attachment_id = attachment_url_to_postid( $image );
|
296 |
+
|
297 |
+
} elseif( $is_url ) {
|
298 |
+
|
299 |
+
if( ! function_exists( 'media_sideload_image' ) ) {
|
300 |
+
|
301 |
+
require_once( ABSPATH . 'wp-admin/includes/file.php' );
|
302 |
+
|
303 |
+
}
|
304 |
+
|
305 |
+
// Image given by external URL
|
306 |
+
$url = media_sideload_image( $image, $download_id, '', 'src' );
|
307 |
+
|
308 |
+
if( ! is_wp_error( $url ) ) {
|
309 |
+
|
310 |
+
$attachment_id = attachment_url_to_postid( $url );
|
311 |
+
|
312 |
+
}
|
313 |
+
|
314 |
+
|
315 |
+
} elseif( false === strpos( $image, '/' ) && edd_get_file_extension( $image ) ) {
|
316 |
+
|
317 |
+
// Image given by name only
|
318 |
+
|
319 |
+
$upload_dir = wp_upload_dir();
|
320 |
+
|
321 |
+
if( file_exists( trailingslashit( $upload_dir['path'] ) . $image ) ) {
|
322 |
+
|
323 |
+
// Look in current upload directory first
|
324 |
+
$file = trailingslashit( $upload_dir['path'] ) . $image;
|
325 |
+
|
326 |
+
} else {
|
327 |
+
|
328 |
+
// Now look through year/month sub folders of upload directory for files with our image's same extension
|
329 |
+
$files = glob( $upload_dir['basedir'] . '/*/*/*{' . $ext . '}', GLOB_BRACE );
|
330 |
+
foreach( $files as $file ) {
|
331 |
+
|
332 |
+
if( basename( $file ) == $image ) {
|
333 |
+
|
334 |
+
// Found our file
|
335 |
+
break;
|
336 |
+
|
337 |
+
}
|
338 |
+
|
339 |
+
// Make sure $file is unset so our empty check below does not return a false positive
|
340 |
+
unset( $file );
|
341 |
+
|
342 |
+
}
|
343 |
+
|
344 |
+
}
|
345 |
+
|
346 |
+
if( ! empty( $file ) ) {
|
347 |
+
|
348 |
+
// We found the file, let's see if it already exists in the media library
|
349 |
+
|
350 |
+
$guid = str_replace( $upload_dir['basedir'], $upload_dir['baseurl'], $file );
|
351 |
+
$attachment_id = attachment_url_to_postid( $guid );
|
352 |
+
|
353 |
+
|
354 |
+
if( empty( $attachment_id ) ) {
|
355 |
+
|
356 |
+
// Doesn't exist in the media library, let's add it
|
357 |
+
|
358 |
+
$filetype = wp_check_filetype( basename( $file ), null );
|
359 |
+
|
360 |
+
// Prepare an array of post data for the attachment.
|
361 |
+
$attachment = array(
|
362 |
+
'guid' => $guid,
|
363 |
+
'post_mime_type' => $filetype['type'],
|
364 |
+
'post_title' => preg_replace( '/\.[^.]+$/', '', $image ),
|
365 |
+
'post_content' => '',
|
366 |
+
'post_status' => 'inherit',
|
367 |
+
'post_author' => $post_author
|
368 |
+
);
|
369 |
+
|
370 |
+
// Insert the attachment.
|
371 |
+
$attachment_id = wp_insert_attachment( $attachment, $file, $download_id );
|
372 |
+
|
373 |
+
// Make sure that this file is included, as wp_generate_attachment_metadata() depends on it.
|
374 |
+
require_once( ABSPATH . 'wp-admin/includes/image.php' );
|
375 |
+
|
376 |
+
// Generate the metadata for the attachment, and update the database record.
|
377 |
+
$attach_data = wp_generate_attachment_metadata( $attachment_id, $file );
|
378 |
+
wp_update_attachment_metadata( $attachment_id, $attach_data );
|
379 |
+
|
380 |
+
}
|
381 |
+
|
382 |
+
}
|
383 |
+
|
384 |
+
}
|
385 |
+
|
386 |
+
if( ! empty( $attachment_id ) ) {
|
387 |
+
|
388 |
+
return set_post_thumbnail( $download_id, $attachment_id );
|
389 |
+
|
390 |
+
}
|
391 |
+
|
392 |
+
return false;
|
393 |
|
394 |
}
|
395 |
+
|
396 |
+
/**
|
397 |
+
* Set up and taxonomy terms
|
398 |
+
*
|
399 |
+
* @since 2.6
|
400 |
+
* @return void
|
401 |
+
*/
|
402 |
+
private function set_taxonomy_terms( $download_id = 0, $terms = array(), $taxonomy = 'download_category' ) {
|
403 |
+
|
404 |
+
$terms = $this->maybe_create_terms( $terms, $taxonomy );
|
405 |
+
|
406 |
+
if( ! empty( $terms ) ) {
|
407 |
+
|
408 |
+
wp_set_object_terms( $download_id, $terms, $taxonomy );
|
409 |
+
|
410 |
+
}
|
411 |
+
|
412 |
+
}
|
413 |
+
|
414 |
+
/**
|
415 |
+
* Locate term IDs or create terms if none are found
|
416 |
+
*
|
417 |
+
* @since 2.6
|
418 |
+
* @return array
|
419 |
+
*/
|
420 |
+
private function maybe_create_terms( $terms = array(), $taxonomy = 'download_category' ) {
|
421 |
+
|
422 |
+
// Return of term IDs
|
423 |
+
$term_ids = array();
|
424 |
+
|
425 |
+
foreach( $terms as $term ) {
|
426 |
+
|
427 |
+
if( is_numeric( $term ) && 0 === (int) $term ) {
|
428 |
+
|
429 |
+
$term = get_term( $term, $taxonomy );
|
430 |
+
|
431 |
+
} else {
|
432 |
+
|
433 |
+
$term = get_term_by( 'name', $term, $taxonomy );
|
434 |
+
|
435 |
+
if( ! $term ) {
|
436 |
+
|
437 |
+
$term = get_term_by( 'slug', $term, $taxonomy );
|
438 |
+
|
439 |
+
}
|
440 |
+
|
441 |
+
}
|
442 |
+
|
443 |
+
if( ! empty( $term ) ) {
|
444 |
+
|
445 |
+
$term_ids[] = $term->term_id;
|
446 |
+
|
447 |
+
} else {
|
448 |
+
|
449 |
+
$term_ids[] = wp_insert_term( $term, $taxonomy );
|
450 |
+
|
451 |
+
}
|
452 |
+
|
453 |
+
}
|
454 |
+
|
455 |
+
return array_map( 'absint', $term_ids );
|
456 |
+
}
|
457 |
+
|
458 |
+
/**
|
459 |
+
* Retrieve URL to Downloads list table
|
460 |
+
*
|
461 |
+
* @since 2.6
|
462 |
+
* @return string
|
463 |
+
*/
|
464 |
+
public function get_list_table_url() {
|
465 |
+
return admin_url( 'edit.php?post_type=download' );
|
466 |
+
}
|
467 |
+
|
468 |
+
/**
|
469 |
+
* Retrieve Download label
|
470 |
+
*
|
471 |
+
* @since 2.6
|
472 |
+
* @return void
|
473 |
+
*/
|
474 |
+
public function get_import_type_label() {
|
475 |
+
return edd_get_label_plural( true );
|
476 |
+
}
|
477 |
+
|
478 |
}
|
includes/admin/import/class-batch-import-payments.php
ADDED
@@ -0,0 +1,582 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Payment Import Class
|
4 |
+
*
|
5 |
+
* This class handles importing payments with the batch processing API
|
6 |
+
*
|
7 |
+
* @package EDD
|
8 |
+
* @subpackage Admin/Import
|
9 |
+
* @copyright Copyright (c) 2015, Pippin Williamson
|
10 |
+
* @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
|
11 |
+
* @since 2.6
|
12 |
+
*/
|
13 |
+
|
14 |
+
// Exit if accessed directly
|
15 |
+
if ( ! defined( 'ABSPATH' ) ) exit;
|
16 |
+
|
17 |
+
/**
|
18 |
+
* EDD_Batch_Import Class
|
19 |
+
*
|
20 |
+
* @since 2.6
|
21 |
+
*/
|
22 |
+
class EDD_Batch_Payments_Import extends EDD_Batch_Import {
|
23 |
+
|
24 |
+
/**
|
25 |
+
* Set up our import config.
|
26 |
+
*
|
27 |
+
* @since 2.6
|
28 |
+
* @return void
|
29 |
+
*/
|
30 |
+
public function init() {
|
31 |
+
|
32 |
+
$this->per_step = 5;
|
33 |
+
|
34 |
+
// Set up default field map values
|
35 |
+
$this->field_mapping = array(
|
36 |
+
'total' => '',
|
37 |
+
'subtotal' => '',
|
38 |
+
'tax' => 'draft',
|
39 |
+
'number' => '',
|
40 |
+
'mode' => '',
|
41 |
+
'gateway' => '',
|
42 |
+
'date' => '',
|
43 |
+
'status' => '',
|
44 |
+
'email' => '',
|
45 |
+
'first_name' => '',
|
46 |
+
'last_name' => '',
|
47 |
+
'customer_id' => '',
|
48 |
+
'user_id' => '',
|
49 |
+
'discounts' => '',
|
50 |
+
'key' => '',
|
51 |
+
'transaction_id' => '',
|
52 |
+
'ip' => '',
|
53 |
+
'currency' => '',
|
54 |
+
'parent_payment_id' => '',
|
55 |
+
'downloads' => '',
|
56 |
+
'line1' => '',
|
57 |
+
'line2' => '',
|
58 |
+
'city' => '',
|
59 |
+
'state' => '',
|
60 |
+
'zip' => '',
|
61 |
+
'country' => '',
|
62 |
+
);
|
63 |
+
}
|
64 |
+
|
65 |
+
/**
|
66 |
+
* Process a step
|
67 |
+
*
|
68 |
+
* @since 2.6
|
69 |
+
* @return bool
|
70 |
+
*/
|
71 |
+
public function process_step() {
|
72 |
+
|
73 |
+
$more = false;
|
74 |
+
|
75 |
+
if ( ! $this->can_import() ) {
|
76 |
+
wp_die( __( 'You do not have permission to import data.', 'easy-digital-downloads' ), __( 'Error', 'easy-digital-downloads' ), array( 'response' => 403 ) );
|
77 |
+
}
|
78 |
+
|
79 |
+
// Remove certain actions to ensure they don't fire when creating the payments
|
80 |
+
remove_action( 'edd_complete_purchase', 'edd_trigger_purchase_receipt', 999 );
|
81 |
+
remove_action( 'edd_admin_sale_notice', 'edd_admin_email_notice', 10 );
|
82 |
+
|
83 |
+
$i = 1;
|
84 |
+
$offset = $this->step > 1 ? ( $this->per_step * ( $this->step - 1 ) ) : 0;
|
85 |
+
|
86 |
+
if( $offset > $this->total ) {
|
87 |
+
$this->done = true;
|
88 |
+
}
|
89 |
+
|
90 |
+
if( ! $this->done && $this->csv->data ) {
|
91 |
+
|
92 |
+
$more = true;
|
93 |
+
|
94 |
+
foreach( $this->csv->data as $key => $row ) {
|
95 |
+
|
96 |
+
// Skip all rows until we pass our offset
|
97 |
+
if( $key + 1 < $offset ) {
|
98 |
+
continue;
|
99 |
+
}
|
100 |
+
|
101 |
+
// Done with this batch
|
102 |
+
if( $i >= $this->per_step ) {
|
103 |
+
break;
|
104 |
+
}
|
105 |
+
|
106 |
+
// Import payment
|
107 |
+
$this->create_payment( $row );
|
108 |
+
|
109 |
+
$i++;
|
110 |
+
}
|
111 |
+
|
112 |
+
}
|
113 |
+
|
114 |
+
return $more;
|
115 |
+
}
|
116 |
+
|
117 |
+
/**
|
118 |
+
* Set up and store a payment record from a CSV row
|
119 |
+
*
|
120 |
+
* @since 2.6
|
121 |
+
* @return void
|
122 |
+
*/
|
123 |
+
public function create_payment( $row = array() ) {
|
124 |
+
|
125 |
+
$payment = new EDD_Payment;
|
126 |
+
$payment->status = 'pending';
|
127 |
+
|
128 |
+
if( ! empty( $this->field_mapping['number'] ) && ! empty( $row[ $this->field_mapping['number'] ] ) ) {
|
129 |
+
|
130 |
+
$payment->number = sanitize_text_field( $row[ $this->field_mapping['number'] ] );
|
131 |
+
|
132 |
+
}
|
133 |
+
|
134 |
+
if( ! empty( $this->field_mapping['mode'] ) && ! empty( $row[ $this->field_mapping['mode'] ] ) ) {
|
135 |
+
|
136 |
+
$mode = strtolower( sanitize_text_field( $row[ $this->field_mapping['mode'] ] ) );
|
137 |
+
$mode = 'test' != $mode && 'live' != $mode ? false : $mode;
|
138 |
+
if( ! $mode ) {
|
139 |
+
$mode = edd_is_test_mode() ? 'test' : 'live';
|
140 |
+
}
|
141 |
+
|
142 |
+
$payment->mode = $mode;
|
143 |
+
|
144 |
+
}
|
145 |
+
|
146 |
+
if( ! empty( $this->field_mapping['date'] ) && ! empty( $row[ $this->field_mapping['date'] ] ) ) {
|
147 |
+
|
148 |
+
$date = sanitize_text_field( $row[ $this->field_mapping['date'] ] );
|
149 |
+
|
150 |
+
if( ! strtotime( $date ) ) {
|
151 |
+
|
152 |
+
$date = date( 'Y-n-d H:i:s', current_time( 'timestamp' ) );
|
153 |
+
|
154 |
+
}
|
155 |
+
|
156 |
+
$payment->date = $date;
|
157 |
+
|
158 |
+
}
|
159 |
+
|
160 |
+
$payment->customer_id = $this->set_customer( $row );
|
161 |
+
|
162 |
+
if( ! empty( $this->field_mapping['email'] ) && ! empty( $row[ $this->field_mapping['email'] ] ) ) {
|
163 |
+
|
164 |
+
$payment->email = sanitize_text_field( $row[ $this->field_mapping['email'] ] );
|
165 |
+
|
166 |
+
}
|
167 |
+
|
168 |
+
if( ! empty( $this->field_mapping['first_name'] ) && ! empty( $row[ $this->field_mapping['first_name'] ] ) ) {
|
169 |
+
|
170 |
+
$payment->first_name = sanitize_text_field( $row[ $this->field_mapping['first_name'] ] );
|
171 |
+
|
172 |
+
}
|
173 |
+
|
174 |
+
if( ! empty( $this->field_mapping['last_name'] ) && ! empty( $row[ $this->field_mapping['last_name'] ] ) ) {
|
175 |
+
|
176 |
+
$payment->last_name = sanitize_text_field( $row[ $this->field_mapping['last_name'] ] );
|
177 |
+
|
178 |
+
}
|
179 |
+
|
180 |
+
if( ! empty( $this->field_mapping['user_id'] ) && ! empty( $row[ $this->field_mapping['user_id'] ] ) ) {
|
181 |
+
|
182 |
+
$user_id = sanitize_text_field( $row[ $this->field_mapping['user_id'] ] );
|
183 |
+
|
184 |
+
if( is_numeric( $user_id ) ) {
|
185 |
+
|
186 |
+
$user_id = absint( $row[ $this->field_mapping['user_id'] ] );
|
187 |
+
$user = get_userdata( $user_id );
|
188 |
+
|
189 |
+
} elseif( is_email( $user_id ) ) {
|
190 |
+
|
191 |
+
$user = get_user_by( 'email', $user_id );
|
192 |
+
|
193 |
+
} else {
|
194 |
+
|
195 |
+
$user = get_user_by( 'user_login', $user_id );
|
196 |
+
|
197 |
+
}
|
198 |
+
|
199 |
+
if( $user ) {
|
200 |
+
|
201 |
+
$payment->user_id = $user->ID;
|
202 |
+
|
203 |
+
}
|
204 |
+
|
205 |
+
}
|
206 |
+
|
207 |
+
if( ! empty( $this->field_mapping['discounts'] ) && ! empty( $row[ $this->field_mapping['discounts'] ] ) ) {
|
208 |
+
|
209 |
+
$payment->discounts = sanitize_text_field( $row[ $this->field_mapping['discounts'] ] );
|
210 |
+
|
211 |
+
}
|
212 |
+
|
213 |
+
if( ! empty( $this->field_mapping['transaction_id'] ) && ! empty( $row[ $this->field_mapping['transaction_id'] ] ) ) {
|
214 |
+
|
215 |
+
$payment->transaction_id = sanitize_text_field( $row[ $this->field_mapping['transaction_id'] ] );
|
216 |
+
|
217 |
+
}
|
218 |
+
|
219 |
+
if( ! empty( $this->field_mapping['ip'] ) && ! empty( $row[ $this->field_mapping['ip'] ] ) ) {
|
220 |
+
|
221 |
+
$payment->ip = sanitize_text_field( $row[ $this->field_mapping['ip'] ] );
|
222 |
+
|
223 |
+
}
|
224 |
+
|
225 |
+
if( ! empty( $this->field_mapping['gateway'] ) && ! empty( $row[ $this->field_mapping['gateway'] ] ) ) {
|
226 |
+
|
227 |
+
$gateways = edd_get_payment_gateways();
|
228 |
+
$gateway = strtolower( sanitize_text_field( $row[ $this->field_mapping['gateway'] ] ) );
|
229 |
+
|
230 |
+
if( ! array_key_exists( $gateway, $gateways ) ) {
|
231 |
+
|
232 |
+
foreach( $gateways as $key => $enabled_gateway ) {
|
233 |
+
|
234 |
+
if( $enabled_gateway['checkout_label'] == $gateway ) {
|
235 |
+
|
236 |
+
$gateway = $key;
|
237 |
+
break;
|
238 |
+
|
239 |
+
}
|
240 |
+
|
241 |
+
}
|
242 |
+
|
243 |
+
}
|
244 |
+
|
245 |
+
$payment->gateway = $gateway;
|
246 |
+
|
247 |
+
}
|
248 |
+
|
249 |
+
if( ! empty( $this->field_mapping['currency'] ) && ! empty( $row[ $this->field_mapping['currency'] ] ) ) {
|
250 |
+
|
251 |
+
$payment->currency = strtoupper( sanitize_text_field( $row[ $this->field_mapping['currency'] ] ) );
|
252 |
+
|
253 |
+
}
|
254 |
+
|
255 |
+
if( ! empty( $this->field_mapping['key'] ) && ! empty( $row[ $this->field_mapping['key'] ] ) ) {
|
256 |
+
|
257 |
+
$payment->key = sanitize_text_field( $row[ $this->field_mapping['key'] ] );
|
258 |
+
|
259 |
+
}
|
260 |
+
|
261 |
+
if( ! empty( $this->field_mapping['parent_payment_id'] ) && ! empty( $row[ $this->field_mapping['parent_payment_id'] ] ) ) {
|
262 |
+
|
263 |
+
$payment->parent_payment_id = absint( $row[ $this->field_mapping['parent_payment_id'] ] );
|
264 |
+
|
265 |
+
}
|
266 |
+
|
267 |
+
if( ! empty( $this->field_mapping['downloads'] ) && ! empty( $row[ $this->field_mapping['downloads'] ] ) ) {
|
268 |
+
|
269 |
+
if( __( 'Products (Raw)', 'easy-digital-downloads' ) == $this->field_mapping['downloads'] ) {
|
270 |
+
|
271 |
+
// This is an EDD export so we can extract prices
|
272 |
+
$downloads = $this->get_downloads_from_edd( $row[ $this->field_mapping['downloads'] ] );
|
273 |
+
|
274 |
+
} else {
|
275 |
+
|
276 |
+
$downloads = $this->str_to_array( $row[ $this->field_mapping['downloads'] ] );
|
277 |
+
|
278 |
+
}
|
279 |
+
|
280 |
+
if( is_array( $downloads ) ) {
|
281 |
+
|
282 |
+
$download_count = count( $downloads );
|
283 |
+
|
284 |
+
foreach( $downloads as $download ) {
|
285 |
+
|
286 |
+
if( is_array( $download ) ) {
|
287 |
+
$download_name = $download['download'];
|
288 |
+
$price = $download['price'];
|
289 |
+
$tax = $download['tax'];
|
290 |
+
} else {
|
291 |
+
$download_name = $download;
|
292 |
+
}
|
293 |
+
|
294 |
+
$download_id = $this->maybe_create_download( $download_name );
|
295 |
+
|
296 |
+
if( ! $download_id ) {
|
297 |
+
continue;
|
298 |
+
}
|
299 |
+
|
300 |
+
$item_price = ! isset( $price ) ? edd_get_download_price( $download_id ) : $price;
|
301 |
+
$item_tax = ! isset( $tax ) ? ( $download_count > 1 ? 0.00 : $payment->tax ) : $tax;
|
302 |
+
|
303 |
+
$payment->add_download( $download_id, array(
|
304 |
+
'item_price' => $item_price,
|
305 |
+
'tax' => $item_tax
|
306 |
+
) );
|
307 |
+
|
308 |
+
}
|
309 |
+
|
310 |
+
}
|
311 |
+
|
312 |
+
}
|
313 |
+
|
314 |
+
if( ! empty( $this->field_mapping['total'] ) && ! empty( $row[ $this->field_mapping['total'] ] ) ) {
|
315 |
+
|
316 |
+
$payment->total = edd_sanitize_amount( $row[ $this->field_mapping['total'] ] );
|
317 |
+
|
318 |
+
}
|
319 |
+
|
320 |
+
if( ! empty( $this->field_mapping['tax'] ) && ! empty( $row[ $this->field_mapping['tax'] ] ) ) {
|
321 |
+
|
322 |
+
$payment->tax = edd_sanitize_amount( $row[ $this->field_mapping['tax'] ] );
|
323 |
+
|
324 |
+
}
|
325 |
+
|
326 |
+
if( ! empty( $this->field_mapping['subtotal'] ) && ! empty( $row[ $this->field_mapping['subtotal'] ] ) ) {
|
327 |
+
|
328 |
+
$payment->subtotal = edd_sanitize_amount( $row[ $this->field_mapping['subtotal'] ] );
|
329 |
+
|
330 |
+
} else {
|
331 |
+
|
332 |
+
$payment->subtotal = $payment->total - $payment->tax;
|
333 |
+
|
334 |
+
}
|
335 |
+
|
336 |
+
$address = array( 'line1' => '', 'line2' => '', 'city' => '', 'state' => '', 'zip' => '', 'country' => '' );
|
337 |
+
|
338 |
+
foreach( $address as $key => $address_field ) {
|
339 |
+
|
340 |
+
if( ! empty( $this->field_mapping[ $key ] ) && ! empty( $row[ $this->field_mapping[ $key ] ] ) ) {
|
341 |
+
|
342 |
+
$address[ $key ] = sanitize_text_field( $row[ $this->field_mapping[ $key ] ] );
|
343 |
+
|
344 |
+
}
|
345 |
+
|
346 |
+
}
|
347 |
+
|
348 |
+
$payment->address = $address;
|
349 |
+
|
350 |
+
$payment->save();
|
351 |
+
|
352 |
+
|
353 |
+
// The status has to be set after payment is created to ensure status update properly
|
354 |
+
if( ! empty( $this->field_mapping['status'] ) && ! empty( $row[ $this->field_mapping['status'] ] ) ) {
|
355 |
+
|
356 |
+
$payment->status = strtolower( sanitize_text_field( $row[ $this->field_mapping['status'] ] ) );
|
357 |
+
|
358 |
+
} else {
|
359 |
+
|
360 |
+
$payment->status = 'complete';
|
361 |
+
|
362 |
+
}
|
363 |
+
|
364 |
+
// Save a second time to update stats
|
365 |
+
$payment->save();
|
366 |
+
|
367 |
+
}
|
368 |
+
|
369 |
+
private function set_customer( $row ) {
|
370 |
+
|
371 |
+
global $wpdb;
|
372 |
+
|
373 |
+
if( ! empty( $this->field_mapping['email'] ) && ! empty( $row[ $this->field_mapping['email'] ] ) ) {
|
374 |
+
|
375 |
+
$email = sanitize_text_field( $row[ $this->field_mapping['email'] ] );
|
376 |
+
|
377 |
+
}
|
378 |
+
|
379 |
+
// Look for a customer from the canonical source, if any
|
380 |
+
if( ! empty( $this->field_mapping['customer_id'] ) && ! empty( $row[ $this->field_mapping['customer_id'] ] ) ) {
|
381 |
+
|
382 |
+
$canonical_id = absint( $row[ $this->field_mapping['customer_id'] ] );
|
383 |
+
$mapped_id = $wpdb->get_var( $wpdb->prepare( "SELECT customer_id FROM $wpdb->customermeta WHERE meta_key = '_canonical_import_id' AND meta_value = %d LIMIT 1", $canonical_id ) );
|
384 |
+
|
385 |
+
}
|
386 |
+
|
387 |
+
if( ! empty( $mapped_id ) ) {
|
388 |
+
|
389 |
+
$customer = new EDD_Customer( $mapped_id );
|
390 |
+
|
391 |
+
}
|
392 |
+
|
393 |
+
if( empty( $mapped_id ) || ! $customer->id > 0 ) {
|
394 |
+
|
395 |
+
// Look for a customer based on provided ID, if any
|
396 |
+
|
397 |
+
if( ! empty( $this->field_mapping['customer_id'] ) && ! empty( $row[ $this->field_mapping['customer_id'] ] ) ) {
|
398 |
+
|
399 |
+
$customer_id = absint( $row[ $this->field_mapping['customer_id'] ] );
|
400 |
+
|
401 |
+
$customer_by_id = new EDD_Customer( $customer_id );
|
402 |
+
|
403 |
+
}
|
404 |
+
|
405 |
+
// Now look for a customer based on provided email
|
406 |
+
|
407 |
+
if( ! empty( $email ) ) {
|
408 |
+
|
409 |
+
$customer_by_email = new EDD_Customer( $email );
|
410 |
+
|
411 |
+
}
|
412 |
+
|
413 |
+
// Now compare customer records. If they don't match, customer_id will be stored in meta and we will use the customer that matches the email
|
414 |
+
|
415 |
+
if( ( empty( $customer_by_id ) || $customer_by_id->id !== $customer_by_email->id ) && ! empty( $customer_by_email ) ) {
|
416 |
+
|
417 |
+
$customer = $customer_by_email;
|
418 |
+
|
419 |
+
} else if ( ! empty( $customer_by_id ) ) {
|
420 |
+
|
421 |
+
$customer = $customer_by_id;
|
422 |
+
|
423 |
+
if( ! empty( $email ) ) {
|
424 |
+
$customer->add_email( $email );
|
425 |
+
}
|
426 |
+
|
427 |
+
}
|
428 |
+
|
429 |
+
// Make sure we found a customer. Create one if not.
|
430 |
+
if( empty( $customer->id ) ) {
|
431 |
+
|
432 |
+
if ( ! is_a( $customer, 'EDD_Customer' ) ) {
|
433 |
+
$customer = new EDD_Customer;
|
434 |
+
}
|
435 |
+
|
436 |
+
$first_name = '';
|
437 |
+
$last_name = '';
|
438 |
+
|
439 |
+
if( ! empty( $this->field_mapping['first_name'] ) && ! empty( $row[ $this->field_mapping['first_name'] ] ) ) {
|
440 |
+
|
441 |
+
$first_name = sanitize_text_field( $row[ $this->field_mapping['first_name'] ] );
|
442 |
+
|
443 |
+
}
|
444 |
+
|
445 |
+
if( ! empty( $this->field_mapping['last_name'] ) && ! empty( $row[ $this->field_mapping['last_name'] ] ) ) {
|
446 |
+
|
447 |
+
$last_name = sanitize_text_field( $row[ $this->field_mapping['last_name'] ] );
|
448 |
+
|
449 |
+
}
|
450 |
+
|
451 |
+
$customer->create( array(
|
452 |
+
'name' => $first_name . ' ' . $last_name,
|
453 |
+
'email' => $email
|
454 |
+
) );
|
455 |
+
|
456 |
+
if( ! empty( $canonical_id ) && (int) $canonical_id !== (int) $customer->id ) {
|
457 |
+
$customer->update_meta( '_canonical_import_id', $canonical_id );
|
458 |
+
}
|
459 |
+
|
460 |
+
}
|
461 |
+
|
462 |
+
|
463 |
+
}
|
464 |
+
|
465 |
+
if( $email && $email != $customer->email ) {
|
466 |
+
$customer->add_email( $email );
|
467 |
+
}
|
468 |
+
|
469 |
+
return $customer->id;
|
470 |
+
|
471 |
+
}
|
472 |
+
|
473 |
+
/**
|
474 |
+
* Look up Download by title and create one if none is found
|
475 |
+
*
|
476 |
+
* @since 2.6
|
477 |
+
* @return int Download ID
|
478 |
+
*/
|
479 |
+
private function maybe_create_download( $title = '' ) {
|
480 |
+
|
481 |
+
if( ! is_string( $title ) ) {
|
482 |
+
return false;
|
483 |
+
}
|
484 |
+
|
485 |
+
$download = get_page_by_title( $title, OBJECT, 'download' );
|
486 |
+
|
487 |
+
if( $download ) {
|
488 |
+
|
489 |
+
$download_id = $download->ID;
|
490 |
+
|
491 |
+
} else {
|
492 |
+
|
493 |
+
$args = array(
|
494 |
+
'post_type' => 'download',
|
495 |
+
'post_title' => $title,
|
496 |
+
'post_author' => get_current_user_id()
|
497 |
+
);
|
498 |
+
|
499 |
+
$download_id = wp_insert_post( $args );
|
500 |
+
|
501 |
+
}
|
502 |
+
|
503 |
+
return $download_id;
|
504 |
+
}
|
505 |
+
|
506 |
+
/**
|
507 |
+
* Return the calculated completion percentage
|
508 |
+
*
|
509 |
+
* @since 2.6
|
510 |
+
* @return int
|
511 |
+
*/
|
512 |
+
public function get_downloads_from_edd( $data_str ) {
|
513 |
+
|
514 |
+
// Break string into separate products
|
515 |
+
|
516 |
+
$d_array = array();
|
517 |
+
$downloads = (array) explode( '/', $data_str );
|
518 |
+
|
519 |
+
if( $downloads ) {
|
520 |
+
|
521 |
+
foreach( $downloads as $key => $download ) {
|
522 |
+
|
523 |
+
$d = (array) explode( '|', $download );
|
524 |
+
preg_match( '/\{(\d+(\.\d+|\d+))\}/', $d[1], $matches );
|
525 |
+
$price = substr( $d[1], 0, strpos( $d[1], '{' ) );
|
526 |
+
$tax = isset( $matches[1] ) ? $matches[1] : 0;
|
527 |
+
|
528 |
+
$d_array[] = array(
|
529 |
+
'download' => $d[0],
|
530 |
+
'price' => $price - $tax,
|
531 |
+
'tax' => $tax
|
532 |
+
);
|
533 |
+
|
534 |
+
}
|
535 |
+
|
536 |
+
}
|
537 |
+
|
538 |
+
return $d_array;
|
539 |
+
|
540 |
+
}
|
541 |
+
|
542 |
+
/**
|
543 |
+
* Return the calculated completion percentage
|
544 |
+
*
|
545 |
+
* @since 2.6
|
546 |
+
* @return int
|
547 |
+
*/
|
548 |
+
public function get_percentage_complete() {
|
549 |
+
|
550 |
+
$total = count( $this->csv->data );
|
551 |
+
|
552 |
+
if( $total > 0 ) {
|
553 |
+
$percentage = ( $this->step / $total ) * 100;
|
554 |
+
}
|
555 |
+
|
556 |
+
if( $percentage > 100 ) {
|
557 |
+
$percentage = 100;
|
558 |
+
}
|
559 |
+
|
560 |
+
return $percentage;
|
561 |
+
}
|
562 |
+
|
563 |
+
/**
|
564 |
+
* Retrieve the URL to the payments list table
|
565 |
+
*
|
566 |
+
* @since 2.6
|
567 |
+
* @return string
|
568 |
+
*/
|
569 |
+
public function get_list_table_url() {
|
570 |
+
return admin_url( 'edit.php?post_type=download&page=edd-payment-history' );
|
571 |
+
}
|
572 |
+
|
573 |
+
/**
|
574 |
+
* Retrieve the payments labels
|
575 |
+
*
|
576 |
+
* @since 2.6
|
577 |
+
* @return string
|
578 |
+
*/
|
579 |
+
public function get_import_type_label() {
|
580 |
+
return __( 'payments', 'easy-digital-downloads' );
|
581 |
+
}
|
582 |
+
}
|
includes/admin/import/class-batch-import.php
ADDED
@@ -0,0 +1,271 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Batch Import Class
|
4 |
+
*
|
5 |
+
* This is the base class for all batch import methods. Each data import type (customers, payments, etc) extend this class
|
6 |
+
*
|
7 |
+
* @package EDD
|
8 |
+
* @subpackage Admin/Import
|
9 |
+
* @copyright Copyright (c) 2015, Pippin Williamson
|
10 |
+
* @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
|
11 |
+
* @since 2.6
|
12 |
+
*/
|
13 |
+
|
14 |
+
// Exit if accessed directly
|
15 |
+
if ( ! defined( 'ABSPATH' ) ) exit;
|
16 |
+
|
17 |
+
/**
|
18 |
+
* EDD_Batch_Import Class
|
19 |
+
*
|
20 |
+
* @since 2.6
|
21 |
+
*/
|
22 |
+
class EDD_Batch_Import {
|
23 |
+
|
24 |
+
/**
|
25 |
+
* The file being imported
|
26 |
+
*
|
27 |
+
* @since 2.6
|
28 |
+
*/
|
29 |
+
public $file;
|
30 |
+
|
31 |
+
/**
|
32 |
+
* The parsed CSV file being imported
|
33 |
+
*
|
34 |
+
* @since 2.6
|
35 |
+
*/
|
36 |
+
public $csv;
|
37 |
+
|
38 |
+
/**
|
39 |
+
* Total rows in the CSV file
|
40 |
+
*
|
41 |
+
* @since 2.6
|
42 |
+
*/
|
43 |
+
public $total;
|
44 |
+
|
45 |
+
/**
|
46 |
+
* The current step being processed
|
47 |
+
*
|
48 |
+
* @since 2.6
|
49 |
+
*/
|
50 |
+
public $step;
|
51 |
+
|
52 |
+
/**
|
53 |
+
* The number of items to process per step
|
54 |
+
*
|
55 |
+
* @since 2.6
|
56 |
+
*/
|
57 |
+
public $per_step = 20;
|
58 |
+
|
59 |
+
/**
|
60 |
+
* The capability required to import data
|
61 |
+
*
|
62 |
+
* @since 2.6
|
63 |
+
*/
|
64 |
+
public $capability_type = 'manage_shop_settings';
|
65 |
+
|
66 |
+
/**
|
67 |
+
* Is the import file empty
|
68 |
+
*
|
69 |
+
* @since 2.6
|
70 |
+
*/
|
71 |
+
public $is_empty = false;
|
72 |
+
|
73 |
+
/**
|
74 |
+
* Map of CSV columns > database fields
|
75 |
+
*
|
76 |
+
* @since 2.6
|
77 |
+
*/
|
78 |
+
public $field_mapping = array();
|
79 |
+
|
80 |
+
/**
|
81 |
+
* Get things started
|
82 |
+
*
|
83 |
+
* @param $_step int The step to process
|
84 |
+
* @since 2.6
|
85 |
+
*/
|
86 |
+
public function __construct( $_file = '', $_step = 1 ) {
|
87 |
+
|
88 |
+
if( ! class_exists( 'parseCSV' ) ) {
|
89 |
+
require_once EDD_PLUGIN_DIR . 'includes/libraries/parsecsv.lib.php';
|
90 |
+
}
|
91 |
+
|
92 |
+
$this->step = $_step;
|
93 |
+
$this->file = $_file;
|
94 |
+
$this->done = false;
|
95 |
+
$this->csv = new parseCSV();
|
96 |
+
$this->csv->auto( $this->file );
|
97 |
+
$this->total = count( $this->csv->data );
|
98 |
+
$this->init();
|
99 |
+
|
100 |
+
}
|
101 |
+
|
102 |
+
/**
|
103 |
+
* Initialize the updater. Runs after import file is loaded but before any processing is done.
|
104 |
+
*
|
105 |
+
* @since 2.6
|
106 |
+
* @return void
|
107 |
+
*/
|
108 |
+
public function init() {}
|
109 |
+
|
110 |
+
/**
|
111 |
+
* Can we import?
|
112 |
+
*
|
113 |
+
* @access public
|
114 |
+
* @since 2.6
|
115 |
+
* @return bool Whether we can iport or not
|
116 |
+
*/
|
117 |
+
public function can_import() {
|
118 |
+
return (bool) apply_filters( 'edd_import_capability', current_user_can( $this->capability_type ) );
|
119 |
+
}
|
120 |
+
|
121 |
+
/**
|
122 |
+
* Get the CSV columns
|
123 |
+
*
|
124 |
+
* @access public
|
125 |
+
* @since 2.6
|
126 |
+
* @return array The columns in the CSV
|
127 |
+
*/
|
128 |
+
public function get_columns() {
|
129 |
+
|
130 |
+
return $this->csv->titles;
|
131 |
+
}
|
132 |
+
|
133 |
+
/**
|
134 |
+
* Get the first row of the CSV
|
135 |
+
*
|
136 |
+
* This is used for showing an example of what the import will look like
|
137 |
+
*
|
138 |
+
* @access public
|
139 |
+
* @since 2.6
|
140 |
+
* @return array The first row after the header of the CSV
|
141 |
+
*/
|
142 |
+
public function get_first_row() {
|
143 |
+
|
144 |
+
return array_map( array( $this, 'trim_preview' ), current( $this->csv->data ) );
|
145 |
+
|
146 |
+
}
|
147 |
+
|
148 |
+
/**
|
149 |
+
* Process a step
|
150 |
+
*
|
151 |
+
* @since 2.6
|
152 |
+
* @return bool
|
153 |
+
*/
|
154 |
+
public function process_step() {
|
155 |
+
|
156 |
+
$more = false;
|
157 |
+
|
158 |
+
if ( ! $this->can_import() ) {
|
159 |
+
wp_die( __( 'You do not have permission to import data.', 'easy-digital-downloads' ), __( 'Error', 'easy-digital-downloads' ), array( 'response' => 403 ) );
|
160 |
+
}
|
161 |
+
|
162 |
+
return $more;
|
163 |
+
}
|
164 |
+
|
165 |
+
/**
|
166 |
+
* Return the calculated completion percentage
|
167 |
+
*
|
168 |
+
* @since 2.6
|
169 |
+
* @return int
|
170 |
+
*/
|
171 |
+
public function get_percentage_complete() {
|
172 |
+
return 100;
|
173 |
+
}
|
174 |
+
|
175 |
+
/**
|
176 |
+
* Map CSV columns to import fields
|
177 |
+
*
|
178 |
+
* @since 2.6
|
179 |
+
* @return void
|
180 |
+
*/
|
181 |
+
public function map_fields( $import_fields = array() ) {
|
182 |
+
|
183 |
+
// Probably add some sanitization here later
|
184 |
+
|
185 |
+
$this->field_mapping = $import_fields;
|
186 |
+
}
|
187 |
+
|
188 |
+
/**
|
189 |
+
* Retrieve the URL to the list table for the import data type
|
190 |
+
*
|
191 |
+
* @since 2.6
|
192 |
+
* @return string
|
193 |
+
*/
|
194 |
+
public function get_list_table_url() {}
|
195 |
+
|
196 |
+
/**
|
197 |
+
* Retrieve the label for the import type. Example: Payments
|
198 |
+
*
|
199 |
+
* @since 2.6
|
200 |
+
* @return string
|
201 |
+
*/
|
202 |
+
public function get_import_type_label() {}
|
203 |
+
|
204 |
+
/**
|
205 |
+
* Convert a string containing delimiters to an array
|
206 |
+
*
|
207 |
+
* @since 2.6
|
208 |
+
* @param $str Input string to convert to an array
|
209 |
+
* @return array
|
210 |
+
*/
|
211 |
+
public function str_to_array( $str = '' ) {
|
212 |
+
|
213 |
+
$array = array();
|
214 |
+
|
215 |
+
if( is_array( $str ) ) {
|
216 |
+
return array_map( 'trim', $str );
|
217 |
+
}
|
218 |
+
|
219 |
+
// Look for standard delimiters
|
220 |
+
if( false !== strpos( $str, '|' ) ) {
|
221 |
+
|
222 |
+
$delimiter = '|';
|
223 |
+
|
224 |
+
} elseif( false !== strpos( $str, ',' ) ) {
|
225 |
+
|
226 |
+
$delimiter = ',';
|
227 |
+
|
228 |
+
} elseif( false !== strpos( $str, ';' ) ) {
|
229 |
+
|
230 |
+
$delimiter = ';';
|
231 |
+
|
232 |
+
} elseif( false !== strpos( $str, '/' ) ) {
|
233 |
+
|
234 |
+
$delimiter = '/';
|
235 |
+
|
236 |
+
}
|
237 |
+
|
238 |
+
if( ! empty( $delimiter ) ) {
|
239 |
+
|
240 |
+
$array = (array) explode( $delimiter, $str );
|
241 |
+
|
242 |
+
} else {
|
243 |
+
|
244 |
+
$array[] = $str;
|
245 |
+
}
|
246 |
+
|
247 |
+
return array_map( 'trim', $array );
|
248 |
+
|
249 |
+
}
|
250 |
+
|
251 |
+
/**
|
252 |
+
* Trims a column value for preview
|
253 |
+
*
|
254 |
+
* @since 2.6
|
255 |
+
* @param $str Input string to trim down
|
256 |
+
* @return string
|
257 |
+
*/
|
258 |
+
public function trim_preview( $str = '' ) {
|
259 |
+
|
260 |
+
if( ! is_numeric( $str ) ) {
|
261 |
+
|
262 |
+
$long = strlen( $str ) >= 30;
|
263 |
+
$str = substr( $str, 0, 30 );
|
264 |
+
$str = $long ? $str . '...' : $str;
|
265 |
+
|
266 |
+
}
|
267 |
+
|
268 |
+
return $str;
|
269 |
+
|
270 |
+
}
|
271 |
+
}
|
includes/admin/import/import-actions.php
ADDED
@@ -0,0 +1,75 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Import Actions
|
4 |
+
*
|
5 |
+
* These are actions related to import data from Easy Digital Downloads.
|
6 |
+
*
|
7 |
+
* @package EDD
|
8 |
+
* @subpackage Admin/Import
|
9 |
+
* @copyright Copyright (c) 2015, Pippin Williamson
|
10 |
+
* @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
|
11 |
+
*/
|
12 |
+
if ( ! defined( 'ABSPATH' ) ) { exit; }
|
13 |
+
|
14 |
+
/**
|
15 |
+
* Add a hook allowing extensions to register a hook on the batch export process
|
16 |
+
*
|
17 |
+
* @since 2.6
|
18 |
+
* @return void
|
19 |
+
*/
|
20 |
+
function edd_register_batch_importers() {
|
21 |
+
if ( is_admin() ) {
|
22 |
+
do_action( 'edd_register_batch_importer' );
|
23 |
+
}
|
24 |
+
}
|
25 |
+
add_action( 'plugins_loaded', 'edd_register_batch_importers' );
|
26 |
+
|
27 |
+
/**
|
28 |
+
* Register the payments batch importer
|
29 |
+
*
|
30 |
+
* @since 2.6
|
31 |
+
*/
|
32 |
+
function edd_register_payments_batch_import() {
|
33 |
+
add_action( 'edd_batch_import_class_include', 'edd_include_payments_batch_import_processer', 10 );
|
34 |
+
}
|
35 |
+
add_action( 'edd_register_batch_importer', 'edd_register_payments_batch_import', 10 );
|
36 |
+
|
37 |
+
/**
|
38 |
+
* Loads the payments batch process if needed
|
39 |
+
*
|
40 |
+
* @since 2.6
|
41 |
+
* @param string $class The class being requested to run for the batch import
|
42 |
+
* @return void
|
43 |
+
*/
|
44 |
+
function edd_include_payments_batch_import_processer( $class ) {
|
45 |
+
|
46 |
+
if ( 'EDD_Batch_Payments_Import' === $class ) {
|
47 |
+
require_once EDD_PLUGIN_DIR . 'includes/admin/import/class-batch-import-payments.php';
|
48 |
+
}
|
49 |
+
|
50 |
+
}
|
51 |
+
|
52 |
+
/**
|
53 |
+
* Register the downloads batch importer
|
54 |
+
*
|
55 |
+
* @since 2.6
|
56 |
+
*/
|
57 |
+
function edd_register_downloads_batch_import() {
|
58 |
+
add_action( 'edd_batch_import_class_include', 'edd_include_downloads_batch_import_processer', 10 );
|
59 |
+
}
|
60 |
+
add_action( 'edd_register_batch_importer', 'edd_register_downloads_batch_import', 10 );
|
61 |
+
|
62 |
+
/**
|
63 |
+
* Loads the downloads batch process if needed
|
64 |
+
*
|
65 |
+
* @since 2.6
|
66 |
+
* @param string $class The class being requested to run for the batch import
|
67 |
+
* @return void
|
68 |
+
*/
|
69 |
+
function edd_include_downloads_batch_import_processer( $class ) {
|
70 |
+
|
71 |
+
if ( 'EDD_Batch_Downloads_Import' === $class ) {
|
72 |
+
require_once EDD_PLUGIN_DIR . 'includes/admin/import/class-batch-import-downloads.php';
|
73 |
+
}
|
74 |
+
|
75 |
+
}
|
includes/admin/import/import-functions.php
ADDED
@@ -0,0 +1,159 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Import Functions
|
4 |
+
*
|
5 |
+
* These are functions are used for import data into Easy Digital Downloads.
|
6 |
+
*
|
7 |
+
* @package EDD
|
8 |
+
* @subpackage Admin/Import
|
9 |
+
* @copyright Copyright (c) 2015, Pippin Williamson
|
10 |
+
* @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
|
11 |
+
*/
|
12 |
+
|
13 |
+
// Exit if accessed directly
|
14 |
+
if ( ! defined( 'ABSPATH' ) ) exit;
|
15 |
+
|
16 |
+
/**
|
17 |
+
* Upload an import file with ajax
|
18 |
+
*
|
19 |
+
* @since 2.6
|
20 |
+
* @return void
|
21 |
+
*/
|
22 |
+
function edd_do_ajax_import_file_upload() {
|
23 |
+
|
24 |
+
if ( ! function_exists( 'wp_handle_upload' ) ) {
|
25 |
+
require_once( ABSPATH . 'wp-admin/includes/file.php' );
|
26 |
+
}
|
27 |
+
|
28 |
+
require_once EDD_PLUGIN_DIR . 'includes/admin/import/class-batch-import.php';
|
29 |
+
|
30 |
+
if( ! wp_verify_nonce( $_REQUEST['edd_ajax_import'], 'edd_ajax_import' ) ) {
|
31 |
+
wp_send_json_error( array( 'error' => __( 'Nonce verification failed', 'easy-digital-downloads' ) ) );
|
32 |
+
}
|
33 |
+
|
34 |
+
if( empty( $_POST['edd-import-class'] ) ) {
|
35 |
+
wp_send_json_error( array( 'error' => __( 'Missing import parameters. Import class must be specified.', 'easy-digital-downloads' ), 'request' => $_REQUEST ) );
|
36 |
+
}
|
37 |
+
|
38 |
+
if( empty( $_FILES['edd-import-file'] ) ) {
|
39 |
+
wp_send_json_error( array( 'error' => __( 'Missing import file. Please provide an import file.', 'easy-digital-downloads' ), 'request' => $_REQUEST ) );
|
40 |
+
}
|
41 |
+
|
42 |
+
if( empty( $_FILES['edd-import-file']['type'] ) || 'text/csv' !== $_FILES['edd-import-file']['type'] ) {
|
43 |
+
wp_send_json_error( array( 'error' => __( 'The file you uploaded does not appear to be a CSV file.', 'easy-digital-downloads' ), 'request' => $_REQUEST ) );
|
44 |
+
}
|
45 |
+
|
46 |
+
if( ! file_exists( $_FILES['edd-import-file']['tmp_name'] ) ) {
|
47 |
+
wp_send_json_error( array( 'error' => __( 'Something went wrong during the upload process, please try again.', 'easy-digital-downloads' ), 'request' => $_REQUEST ) );
|
48 |
+
}
|
49 |
+
|
50 |
+
// Let WordPress import the file. We will remove it after import is complete
|
51 |
+
$import_file = wp_handle_upload( $_FILES['edd-import-file'], array( 'test_form' => false ) );
|
52 |
+
|
53 |
+
if ( $import_file && empty( $import_file['error'] ) ) {
|
54 |
+
|
55 |
+
do_action( 'edd_batch_import_class_include', $_POST['edd-import-class'] );
|
56 |
+
|
57 |
+
$import = new $_POST['edd-import-class']( $import_file['file'] );
|
58 |
+
|
59 |
+
if( ! $import->can_import() ) {
|
60 |
+
wp_send_json_error( array( 'error' => __( 'You do not have permission to import data', 'easy-digital-downloads' ) ) );
|
61 |
+
}
|
62 |
+
|
63 |
+
wp_send_json_success( array(
|
64 |
+
'form' => $_POST,
|
65 |
+
'class' => $_POST['edd-import-class'],
|
66 |
+
'upload' => $import_file,
|
67 |
+
'first_row' => $import->get_first_row(),
|
68 |
+
'columns' => $import->get_columns(),
|
69 |
+
'nonce' => wp_create_nonce( 'edd_ajax_import', 'edd_ajax_import' )
|
70 |
+
) );
|
71 |
+
|
72 |
+
} else {
|
73 |
+
|
74 |
+
/**
|
75 |
+
* Error generated by _wp_handle_upload()
|
76 |
+
* @see _wp_handle_upload() in wp-admin/includes/file.php
|
77 |
+
*/
|
78 |
+
|
79 |
+
wp_send_json_error( array( 'error' => $import_file['error'] ) );
|
80 |
+
}
|
81 |
+
|
82 |
+
exit;
|
83 |
+
|
84 |
+
}
|
85 |
+
add_action( 'edd_upload_import_file', 'edd_do_ajax_import_file_upload' );
|
86 |
+
|
87 |
+
/**
|
88 |
+
* Process batch imports via ajax
|
89 |
+
*
|
90 |
+
* @since 2.6
|
91 |
+
* @return void
|
92 |
+
*/
|
93 |
+
function edd_do_ajax_import() {
|
94 |
+
|
95 |
+
require_once EDD_PLUGIN_DIR . 'includes/admin/import/class-batch-import.php';
|
96 |
+
|
97 |
+
if( ! wp_verify_nonce( $_REQUEST['nonce'], 'edd_ajax_import' ) ) {
|
98 |
+
wp_send_json_error( array( 'error' => __( 'Nonce verification failed', 'easy-digital-downloads' ), 'request' => $_REQUEST ) );
|
99 |
+
}
|
100 |
+
|
101 |
+
if( empty( $_REQUEST['class'] ) ) {
|
102 |
+
wp_send_json_error( array( 'error' => __( 'Missing import parameters. Import class must be specified.', 'easy-digital-downloads' ), 'request' => $_REQUEST ) );
|
103 |
+
}
|
104 |
+
|
105 |
+
if( ! file_exists( $_REQUEST['upload']['file'] ) ) {
|
106 |
+
wp_send_json_error( array( 'error' => __( 'Something went wrong during the upload process, please try again.', 'easy-digital-downloads' ), 'request' => $_REQUEST ) );
|
107 |
+
}
|
108 |
+
|
109 |
+
do_action( 'edd_batch_import_class_include', $_REQUEST['class'] );
|
110 |
+
|
111 |
+
$step = absint( $_REQUEST['step'] );
|
112 |
+
$class = $_REQUEST['class'];
|
113 |
+
$import = new $class( $_REQUEST['upload']['file'], $step );
|
114 |
+
|
115 |
+
if( ! $import->can_import() ) {
|
116 |
+
|
117 |
+
wp_send_json_error( array( 'error' => __( 'You do not have permission to import data', 'easy-digital-downloads' ) ) );
|
118 |
+
|
119 |
+
}
|
120 |
+
|
121 |
+
parse_str( $_REQUEST['mapping'], $map );
|
122 |
+
|
123 |
+
$import->map_fields( $map['edd-import-field'] );
|
124 |
+
|
125 |
+
$ret = $import->process_step( $step );
|
126 |
+
|
127 |
+
$percentage = $import->get_percentage_complete();
|
128 |
+
|
129 |
+
if( $ret ) {
|
130 |
+
|
131 |
+
$step += 1;
|
132 |
+
wp_send_json_success( array(
|
133 |
+
'step' => $step,
|
134 |
+
'percentage' => $percentage,
|
135 |
+
'columns' => $import->get_columns(),
|
136 |
+
'mapping' => $import->field_mapping,
|
137 |
+
'total' => $import->total
|
138 |
+
) );
|
139 |
+
|
140 |
+
} elseif ( true === $import->is_empty ) {
|
141 |
+
|
142 |
+
wp_send_json_error( array(
|
143 |
+
'error' => __( 'No data found for import parameters', 'easy-digital-downloads' )
|
144 |
+
) );
|
145 |
+
|
146 |
+
} else {
|
147 |
+
|
148 |
+
wp_send_json_success( array(
|
149 |
+
'step' => 'done',
|
150 |
+
'message' => sprintf(
|
151 |
+
__( 'Import complete! <a href="%s">View imported %s</a>.', 'easy-digital-downloads' ),
|
152 |
+
$import->get_list_table_url(),
|
153 |
+
$import->get_import_type_label()
|
154 |
+
)
|
155 |
+
) );
|
156 |
+
|
157 |
+
}
|
158 |
+
}
|
159 |
+
add_action( 'wp_ajax_edd_do_ajax_import', 'edd_do_ajax_import' );
|
includes/admin/payments/class-payments-table.php
CHANGED
@@ -315,7 +315,7 @@ class EDD_Payment_History_Table extends WP_List_Table {
|
|
315 |
if ( ! empty( $search_terms ) ) {
|
316 |
$this->base_url = add_query_arg( 's', $search_terms, $this->base_url );
|
317 |
}
|
318 |
-
|
319 |
if ( edd_is_payment_complete( $payment->ID ) && ! empty( $email ) ) {
|
320 |
$row_actions['email_links'] = '<a href="' . add_query_arg( array( 'edd-action' => 'email_links', 'purchase_id' => $payment->ID ), $this->base_url ) . '">' . __( 'Resend Purchase Receipt', 'easy-digital-downloads' ) . '</a>';
|
321 |
}
|
@@ -487,9 +487,12 @@ class EDD_Payment_History_Table extends WP_List_Table {
|
|
487 |
|
488 |
if( isset( $_GET['user'] ) ) {
|
489 |
$args['user'] = urldecode( $_GET['user'] );
|
|
|
|
|
490 |
} elseif( isset( $_GET['s'] ) ) {
|
491 |
|
492 |
$is_user = strpos( $_GET['s'], strtolower( 'user:' ) ) !== false;
|
|
|
493 |
if ( $is_user ) {
|
494 |
$args['user'] = absint( trim( str_replace( 'user:', '', strtolower( $_GET['s'] ) ) ) );
|
495 |
unset( $args['s'] );
|
@@ -532,6 +535,7 @@ class EDD_Payment_History_Table extends WP_List_Table {
|
|
532 |
$orderby = isset( $_GET['orderby'] ) ? urldecode( $_GET['orderby'] ) : 'ID';
|
533 |
$order = isset( $_GET['order'] ) ? $_GET['order'] : 'DESC';
|
534 |
$user = isset( $_GET['user'] ) ? $_GET['user'] : null;
|
|
|
535 |
$status = isset( $_GET['status'] ) ? $_GET['status'] : edd_get_payment_status_keys();
|
536 |
$meta_key = isset( $_GET['meta_key'] ) ? $_GET['meta_key'] : null;
|
537 |
$year = isset( $_GET['year'] ) ? $_GET['year'] : null;
|
@@ -552,6 +556,7 @@ class EDD_Payment_History_Table extends WP_List_Table {
|
|
552 |
'orderby' => $orderby,
|
553 |
'order' => $order,
|
554 |
'user' => $user,
|
|
|
555 |
'status' => $status,
|
556 |
'meta_key' => $meta_key,
|
557 |
'year' => $year,
|
315 |
if ( ! empty( $search_terms ) ) {
|
316 |
$this->base_url = add_query_arg( 's', $search_terms, $this->base_url );
|
317 |
}
|
318 |
+
|
319 |
if ( edd_is_payment_complete( $payment->ID ) && ! empty( $email ) ) {
|
320 |
$row_actions['email_links'] = '<a href="' . add_query_arg( array( 'edd-action' => 'email_links', 'purchase_id' => $payment->ID ), $this->base_url ) . '">' . __( 'Resend Purchase Receipt', 'easy-digital-downloads' ) . '</a>';
|
321 |
}
|
487 |
|
488 |
if( isset( $_GET['user'] ) ) {
|
489 |
$args['user'] = urldecode( $_GET['user'] );
|
490 |
+
} elseif( isset( $_GET['customer'] ) ) {
|
491 |
+
$args['customer'] = absint( $_GET['customer'] );
|
492 |
} elseif( isset( $_GET['s'] ) ) {
|
493 |
|
494 |
$is_user = strpos( $_GET['s'], strtolower( 'user:' ) ) !== false;
|
495 |
+
|
496 |
if ( $is_user ) {
|
497 |
$args['user'] = absint( trim( str_replace( 'user:', '', strtolower( $_GET['s'] ) ) ) );
|
498 |
unset( $args['s'] );
|
535 |
$orderby = isset( $_GET['orderby'] ) ? urldecode( $_GET['orderby'] ) : 'ID';
|
536 |
$order = isset( $_GET['order'] ) ? $_GET['order'] : 'DESC';
|
537 |
$user = isset( $_GET['user'] ) ? $_GET['user'] : null;
|
538 |
+
$customer = isset( $_GET['customer'] ) ? $_GET['customer'] : null;
|
539 |
$status = isset( $_GET['status'] ) ? $_GET['status'] : edd_get_payment_status_keys();
|
540 |
$meta_key = isset( $_GET['meta_key'] ) ? $_GET['meta_key'] : null;
|
541 |
$year = isset( $_GET['year'] ) ? $_GET['year'] : null;
|
556 |
'orderby' => $orderby,
|
557 |
'order' => $order,
|
558 |
'user' => $user,
|
559 |
+
'customer' => $customer,
|
560 |
'status' => $status,
|
561 |
'meta_key' => $meta_key,
|
562 |
'year' => $year,
|
includes/admin/payments/view-order-details.php
CHANGED
@@ -77,6 +77,18 @@ $currency_code = $payment->currency;
|
|
77 |
<option value="<?php echo esc_attr( $key ); ?>"<?php selected( $payment->status, $key, true ); ?>><?php echo esc_html( $status ); ?></option>
|
78 |
<?php endforeach; ?>
|
79 |
</select>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
80 |
</p>
|
81 |
</div>
|
82 |
|
@@ -166,6 +178,7 @@ $currency_code = $payment->currency;
|
|
166 |
<?php do_action( 'edd_view_order_details_resend_receipt_before', $payment_id ); ?>
|
167 |
<?php if( edd_is_payment_complete( $payment_id ) ) : ?>
|
168 |
<a href="<?php echo add_query_arg( array( 'edd-action' => 'email_links', 'purchase_id' => $payment_id ) ); ?>" id="edd-resend-receipt" class="button-secondary alignleft"><?php _e( 'Resend Receipt', 'easy-digital-downloads' ); ?></a>
|
|
|
169 |
<?php endif; ?>
|
170 |
<div class="clear"></div>
|
171 |
<?php do_action( 'edd_view_order_details_resend_receipt_after', $payment_id ); ?>
|
@@ -218,9 +231,10 @@ $currency_code = $payment->currency;
|
|
218 |
|
219 |
<div class="edd-unlimited-downloads edd-admin-box-inside">
|
220 |
<p>
|
221 |
-
<span class="label"
|
222 |
<input type="checkbox" name="edd-unlimited-downloads" id="edd_unlimited_downloads" value="1"<?php checked( true, $unlimited, true ); ?>/>
|
223 |
<label class="description" for="edd_unlimited_downloads"><?php _e( 'Unlimited file downloads', 'easy-digital-downloads' ); ?></label>
|
|
|
224 |
</p>
|
225 |
</div>
|
226 |
|
@@ -419,10 +433,10 @@ $currency_code = $payment->currency;
|
|
419 |
<div class="column">
|
420 |
<?php if( ! empty( $customer->id ) ) : ?>
|
421 |
<?php $customer_url = admin_url( 'edit.php?post_type=download&page=edd-customers&view=overview&id=' . $customer->id ); ?>
|
422 |
-
<a href="<?php echo $customer_url; ?>"
|
423 |
|
|
424 |
<?php endif; ?>
|
425 |
-
<a href="#new" class="edd-payment-new-customer"
|
426 |
</div>
|
427 |
</div>
|
428 |
|
@@ -575,4 +589,4 @@ $currency_code = $payment->currency;
|
|
575 |
<?php do_action( 'edd_view_order_details_after', $payment_id ); ?>
|
576 |
</div><!-- /.wrap -->
|
577 |
|
578 |
-
<div id="edd-download-link"
|
77 |
<option value="<?php echo esc_attr( $key ); ?>"<?php selected( $payment->status, $key, true ); ?>><?php echo esc_html( $status ); ?></option>
|
78 |
<?php endforeach; ?>
|
79 |
</select>
|
80 |
+
|
81 |
+
<?php
|
82 |
+
$status_help = '<ul>';
|
83 |
+
$status_help .= '<li>' . __( '<strong>Pending</strong>: payment is still processing or was abandoned by customer. Successful payments will be marked as Complete automatically once processing is finalized.', 'easy-digital-downloads' ) . '</li>';
|
84 |
+
$status_help .= '<li>' . __( '<strong>Complete</strong>: all processing is completed for this purchase.', 'easy-digital-downloads' ) . '</li>';
|
85 |
+
$status_help .= '<li>' . __( '<strong>Revoked</strong>: access to purchased items is disabled, perhaps due to policy violation or fraud.', 'easy-digital-downloads' ) . '</li>';
|
86 |
+
$status_help .= '<li>' . __( '<strong>Refunded</strong>: the purchase amount is returned to the customer and access to items is disabled.', 'easy-digital-downloads' ) . '</li>';
|
87 |
+
$status_help .= '<li>' . __( '<strong>Abandoned</strong>: the purchase attempt was not completed by the customer.', 'easy-digital-downloads' ) . '</li>';
|
88 |
+
$status_help .= '<li>' . __( '<strong>Failed</strong>: customer clicked Cancel before completing the purchase.', 'easy-digital-downloads' ) . '</li>';
|
89 |
+
$status_help .= '</ul>';
|
90 |
+
?>
|
91 |
+
<span alt="f223" class="edd-help-tip dashicons dashicons-editor-help" title="<?php echo $status_help; ?>"></span>
|
92 |
</p>
|
93 |
</div>
|
94 |
|
178 |
<?php do_action( 'edd_view_order_details_resend_receipt_before', $payment_id ); ?>
|
179 |
<?php if( edd_is_payment_complete( $payment_id ) ) : ?>
|
180 |
<a href="<?php echo add_query_arg( array( 'edd-action' => 'email_links', 'purchase_id' => $payment_id ) ); ?>" id="edd-resend-receipt" class="button-secondary alignleft"><?php _e( 'Resend Receipt', 'easy-digital-downloads' ); ?></a>
|
181 |
+
<span alt="f223" class="edd-help-tip dashicons dashicons-editor-help" title="<?php _e( '<strong>Resend Receipt</strong>: This will send a new copy of the purchase receipt to the customer’s email address. If download URLs are included in the receipt, new file download URLs will also be included with the receipt.', 'easy-digital-downloads' ); ?>"></span>
|
182 |
<?php endif; ?>
|
183 |
<div class="clear"></div>
|
184 |
<?php do_action( 'edd_view_order_details_resend_receipt_after', $payment_id ); ?>
|
231 |
|
232 |
<div class="edd-unlimited-downloads edd-admin-box-inside">
|
233 |
<p>
|
234 |
+
<span class="label"><i data-code="f316" class="dashicons dashicons-download"></i></span>
|
235 |
<input type="checkbox" name="edd-unlimited-downloads" id="edd_unlimited_downloads" value="1"<?php checked( true, $unlimited, true ); ?>/>
|
236 |
<label class="description" for="edd_unlimited_downloads"><?php _e( 'Unlimited file downloads', 'easy-digital-downloads' ); ?></label>
|
237 |
+
<span alt="f223" class="edd-help-tip dashicons dashicons-editor-help" title="<?php _e( '<strong>Unlimited file downloads</strong>: checking this box will override all other file download limits for this purchase, granting the customer unliimited downloads of all files included on the purchase.', 'easy-digital-downloads' ); ?>"></span>
|
238 |
</p>
|
239 |
</div>
|
240 |
|
433 |
<div class="column">
|
434 |
<?php if( ! empty( $customer->id ) ) : ?>
|
435 |
<?php $customer_url = admin_url( 'edit.php?post_type=download&page=edd-customers&view=overview&id=' . $customer->id ); ?>
|
436 |
+
<a href="<?php echo $customer_url; ?>"><?php _e( 'View Customer Details', 'easy-digital-downloads' ); ?></a>
|
437 |
|
|
438 |
<?php endif; ?>
|
439 |
+
<a href="#new" class="edd-payment-new-customer"><?php _e( 'New Customer', 'easy-digital-downloads' ); ?></a>
|
440 |
</div>
|
441 |
</div>
|
442 |
|
589 |
<?php do_action( 'edd_view_order_details_after', $payment_id ); ?>
|
590 |
</div><!-- /.wrap -->
|
591 |
|
592 |
+
<div id="edd-download-link"></div>
|
includes/admin/reporting/class-api-requests-logs-list-table.php
CHANGED
@@ -134,7 +134,7 @@ class EDD_API_Request_Log_Table extends WP_List_Table {
|
|
134 |
*/
|
135 |
public function column_details( $item ) {
|
136 |
?>
|
137 |
-
<a href="#TB_inline?width=640&inlineId=log-details-<?php echo $item['ID']; ?>" class="thickbox"
|
138 |
<div id="log-details-<?php echo $item['ID']; ?>" style="display:none;">
|
139 |
<?php
|
140 |
|
134 |
*/
|
135 |
public function column_details( $item ) {
|
136 |
?>
|
137 |
+
<a href="#TB_inline?width=640&inlineId=log-details-<?php echo $item['ID']; ?>" class="thickbox"><?php _e( 'View Request', 'easy-digital-downloads' ); ?></a>
|
138 |
<div id="log-details-<?php echo $item['ID']; ?>" style="display:none;">
|
139 |
<?php
|
140 |
|
includes/admin/reporting/class-gateway-error-logs-list-table.php
CHANGED
@@ -92,7 +92,7 @@ class EDD_Gateway_Error_Log_Table extends WP_List_Table {
|
|
92 |
*/
|
93 |
public function column_message( $item ) {
|
94 |
?>
|
95 |
-
<a href="#TB_inline?width=640&inlineId=log-message-<?php echo $item['ID']; ?>" class="thickbox"
|
96 |
<div id="log-message-<?php echo $item['ID']; ?>" style="display:none;">
|
97 |
<?php
|
98 |
|
@@ -240,4 +240,4 @@ class EDD_Gateway_Error_Log_Table extends WP_List_Table {
|
|
240 |
public function has_items() {
|
241 |
return true;
|
242 |
}
|
243 |
-
}
|
92 |
*/
|
93 |
public function column_message( $item ) {
|
94 |
?>
|
95 |
+
<a href="#TB_inline?width=640&inlineId=log-message-<?php echo $item['ID']; ?>" class="thickbox"><?php _e( 'View Log Message', 'easy-digital-downloads' ); ?></a>
|
96 |
<div id="log-message-<?php echo $item['ID']; ?>" style="display:none;">
|
97 |
<?php
|
98 |
|
240 |
public function has_items() {
|
241 |
return true;
|
242 |
}
|
243 |
+
}
|
includes/admin/reporting/class-sales-logs-list-table.php
CHANGED
@@ -80,7 +80,18 @@ class EDD_Sales_Log_Table extends WP_List_Table {
|
|
80 |
|
81 |
switch ( $column_name ){
|
82 |
case 'download' :
|
83 |
-
$
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
84 |
break;
|
85 |
|
86 |
case 'user_id' :
|
@@ -315,20 +326,31 @@ class EDD_Sales_Log_Table extends WP_List_Table {
|
|
315 |
|
316 |
if ( $logs ) {
|
317 |
foreach ( $logs as $log ) {
|
|
|
318 |
$payment_id = get_post_meta( $log->ID, '_edd_log_payment_id', true );
|
|
|
319 |
|
320 |
// Make sure this payment hasn't been deleted
|
321 |
-
if (
|
322 |
|
323 |
-
$
|
324 |
-
$cart_items =
|
325 |
$amount = 0;
|
326 |
|
327 |
-
if ( is_array( $cart_items )
|
328 |
|
329 |
foreach ( $cart_items as $item ) {
|
330 |
|
|
|
331 |
if ( $item['id'] == $log->post_parent ) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
332 |
$amount = isset( $item['price'] ) ? $item['price'] : $item['item_price'];
|
333 |
break;
|
334 |
}
|
@@ -337,21 +359,23 @@ class EDD_Sales_Log_Table extends WP_List_Table {
|
|
337 |
|
338 |
$logs_data[] = array(
|
339 |
'ID' => $log->ID,
|
340 |
-
'payment_id' => $
|
341 |
'download' => $log->post_parent,
|
|
|
342 |
'item_price' => isset( $item['item_price'] ) ? $item['item_price'] : $item['price'],
|
343 |
'amount' => $amount,
|
344 |
-
'user_id' => $
|
345 |
-
'user_name' => $
|
346 |
'date' => get_post_field( 'post_date', $payment_id ),
|
347 |
'quantity' => $item['quantity'],
|
348 |
// Keep track of the currency. Vital to produce the correct report
|
349 |
-
'currency' => $
|
350 |
);
|
351 |
|
352 |
}
|
353 |
|
354 |
}
|
|
|
355 |
}
|
356 |
}
|
357 |
|
80 |
|
81 |
switch ( $column_name ){
|
82 |
case 'download' :
|
83 |
+
$download_id = $item[ $column_name ];
|
84 |
+
$download = new EDD_Download( $download_id );
|
85 |
+
|
86 |
+
$title = $download->post_title;
|
87 |
+
if ( edd_has_variable_prices( $download->ID ) ) {
|
88 |
+
$price_id = $item['price_id'];
|
89 |
+
if ( ! is_null( $price_id ) && ! empty( $download->prices[ $price_id] ) ) {
|
90 |
+
$title .= ' — ' . $download->prices[ $price_id ]['name'];
|
91 |
+
}
|
92 |
+
}
|
93 |
+
|
94 |
+
$return = '<a href="' . add_query_arg( 'download', $item[ $column_name ] ) . '" >' . $title . '</a>';
|
95 |
break;
|
96 |
|
97 |
case 'user_id' :
|
326 |
|
327 |
if ( $logs ) {
|
328 |
foreach ( $logs as $log ) {
|
329 |
+
|
330 |
$payment_id = get_post_meta( $log->ID, '_edd_log_payment_id', true );
|
331 |
+
$payment = new EDD_Payment( $payment_id );
|
332 |
|
333 |
// Make sure this payment hasn't been deleted
|
334 |
+
if ( ! empty( $payment->ID ) ) {
|
335 |
|
336 |
+
$customer = new EDD_Customer( $payment->customer_id );
|
337 |
+
$cart_items = $payment->cart_details;
|
338 |
$amount = 0;
|
339 |
|
340 |
+
if ( is_array( $cart_items ) ) {
|
341 |
|
342 |
foreach ( $cart_items as $item ) {
|
343 |
|
344 |
+
// If the item has variable pricing, make sure it's the right variation
|
345 |
if ( $item['id'] == $log->post_parent ) {
|
346 |
+
if ( isset( $item['item_number']['options']['price_id'] ) ) {
|
347 |
+
$log_price_id = get_post_meta( $log->ID, '_edd_log_price_id', true );
|
348 |
+
|
349 |
+
if ( (int) $item['item_number']['options']['price_id'] !== (int) $log_price_id ) {
|
350 |
+
continue;
|
351 |
+
}
|
352 |
+
}
|
353 |
+
|
354 |
$amount = isset( $item['price'] ) ? $item['price'] : $item['item_price'];
|
355 |
break;
|
356 |
}
|
359 |
|
360 |
$logs_data[] = array(
|
361 |
'ID' => $log->ID,
|
362 |
+
'payment_id' => $payment->ID,
|
363 |
'download' => $log->post_parent,
|
364 |
+
'price_id' => isset( $log_price_id ) ? $log_price_id : null,
|
365 |
'item_price' => isset( $item['item_price'] ) ? $item['item_price'] : $item['price'],
|
366 |
'amount' => $amount,
|
367 |
+
'user_id' => $customer->user_id,
|
368 |
+
'user_name' => $customer->name,
|
369 |
'date' => get_post_field( 'post_date', $payment_id ),
|
370 |
'quantity' => $item['quantity'],
|
371 |
// Keep track of the currency. Vital to produce the correct report
|
372 |
+
'currency' => $payment->currency,
|
373 |
);
|
374 |
|
375 |
}
|
376 |
|
377 |
}
|
378 |
+
|
379 |
}
|
380 |
}
|
381 |
|
includes/admin/reporting/export/class-batch-export-payments.php
CHANGED
@@ -37,28 +37,33 @@ class EDD_Batch_Payments_Export extends EDD_Batch_Export {
|
|
37 |
*/
|
38 |
public function csv_cols() {
|
39 |
$cols = array(
|
40 |
-
'id'
|
41 |
-
'seq_id'
|
42 |
-
'email'
|
43 |
-
'
|
44 |
-
'
|
45 |
-
'
|
46 |
-
'
|
47 |
-
'
|
48 |
-
'
|
49 |
-
'
|
50 |
-
'
|
51 |
-
'
|
52 |
-
'
|
53 |
-
'
|
54 |
-
'
|
55 |
-
'
|
56 |
-
'
|
57 |
-
'
|
58 |
-
'
|
59 |
-
'
|
60 |
-
'
|
61 |
-
'
|
|
|
|
|
|
|
|
|
|
|
62 |
);
|
63 |
|
64 |
if( ! edd_use_skus() ){
|
@@ -88,7 +93,9 @@ class EDD_Batch_Payments_Export extends EDD_Batch_Export {
|
|
88 |
$args = array(
|
89 |
'number' => 30,
|
90 |
'page' => $this->step,
|
91 |
-
'status' => $this->status
|
|
|
|
|
92 |
);
|
93 |
|
94 |
if( ! empty( $this->start ) || ! empty( $this->end ) ) {
|
@@ -116,6 +123,7 @@ class EDD_Batch_Payments_Export extends EDD_Batch_Export {
|
|
116 |
$total = edd_get_payment_amount( $payment->ID );
|
117 |
$user_id = isset( $user_info['id'] ) && $user_info['id'] != -1 ? $user_info['id'] : $user_info['email'];
|
118 |
$products = '';
|
|
|
119 |
$skus = '';
|
120 |
|
121 |
if ( $downloads ) {
|
@@ -133,8 +141,10 @@ class EDD_Batch_Payments_Export extends EDD_Batch_Export {
|
|
133 |
$price = edd_get_download_final_price( $id, $user_info, $price_override );
|
134 |
}
|
135 |
|
|
|
|
|
|
|
136 |
|
137 |
-
// Display the Downoad Name
|
138 |
$products .= html_entity_decode( get_the_title( $id ) );
|
139 |
|
140 |
if ( $qty > 1 ) {
|
@@ -146,14 +156,15 @@ class EDD_Batch_Payments_Export extends EDD_Batch_Export {
|
|
146 |
if ( edd_use_skus() ) {
|
147 |
$sku = edd_get_download_sku( $id );
|
148 |
|
149 |
-
if ( ! empty( $sku ) )
|
150 |
$skus .= $sku;
|
|
|
151 |
}
|
152 |
|
153 |
if ( isset( $downloads[ $key ]['item_number'] ) && isset( $downloads[ $key ]['item_number']['options'] ) ) {
|
154 |
$price_options = $downloads[ $key ]['item_number']['options'];
|
155 |
|
156 |
-
if ( isset( $price_options['price_id'] ) ) {
|
157 |
$products .= html_entity_decode( edd_get_price_option_name( $id, $price_options['price_id'], $payment->ID ) ) . ' - ';
|
158 |
}
|
159 |
}
|
@@ -161,10 +172,20 @@ class EDD_Batch_Payments_Export extends EDD_Batch_Export {
|
|
161 |
$products .= html_entity_decode( edd_currency_filter( edd_format_amount( $price ) ) );
|
162 |
|
163 |
if ( $key != ( count( $downloads ) -1 ) ) {
|
|
|
164 |
$products .= ' / ';
|
165 |
|
166 |
-
if( edd_use_skus() )
|
167 |
$skus .= ' / ';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
168 |
}
|
169 |
}
|
170 |
}
|
@@ -176,28 +197,33 @@ class EDD_Batch_Payments_Export extends EDD_Batch_Export {
|
|
176 |
}
|
177 |
|
178 |
$data[] = array(
|
179 |
-
'id'
|
180 |
-
'seq_id'
|
181 |
-
'email'
|
182 |
-
'
|
183 |
-
'
|
184 |
-
'
|
185 |
-
'
|
186 |
-
'
|
187 |
-
'
|
188 |
-
'
|
189 |
-
'
|
190 |
-
'
|
191 |
-
'
|
192 |
-
'
|
193 |
-
'
|
194 |
-
'
|
195 |
-
'
|
196 |
-
'
|
197 |
-
'
|
198 |
-
'
|
199 |
-
'
|
200 |
-
'
|
|
|
|
|
|
|
|
|
|
|
201 |
);
|
202 |
|
203 |
}
|
37 |
*/
|
38 |
public function csv_cols() {
|
39 |
$cols = array(
|
40 |
+
'id' => __( 'Payment ID', 'easy-digital-downloads' ), // unaltered payment ID (use for querying)
|
41 |
+
'seq_id' => __( 'Payment Number', 'easy-digital-downloads' ), // sequential payment ID
|
42 |
+
'email' => __( 'Email', 'easy-digital-downloads' ),
|
43 |
+
'customer_id' => __( 'Customer ID', 'easy-digital-downloads' ),
|
44 |
+
'first' => __( 'First Name', 'easy-digital-downloads' ),
|
45 |
+
'last' => __( 'Last Name', 'easy-digital-downloads' ),
|
46 |
+
'address1' => __( 'Address', 'easy-digital-downloads' ),
|
47 |
+
'address2' => __( 'Address (Line 2)', 'easy-digital-downloads' ),
|
48 |
+
'city' => __( 'City', 'easy-digital-downloads' ),
|
49 |
+
'state' => __( 'State', 'easy-digital-downloads' ),
|
50 |
+
'country' => __( 'Country', 'easy-digital-downloads' ),
|
51 |
+
'zip' => __( 'Zip / Postal Code', 'easy-digital-downloads' ),
|
52 |
+
'products' => __( 'Products (Verbose)', 'easy-digital-downloads' ),
|
53 |
+
'products_raw' => __( 'Products (Raw)', 'easy-digital-downloads' ),
|
54 |
+
'skus' => __( 'SKUs', 'easy-digital-downloads' ),
|
55 |
+
'amount' => __( 'Amount', 'easy-digital-downloads' ) . ' (' . html_entity_decode( edd_currency_filter( '' ) ) . ')',
|
56 |
+
'tax' => __( 'Tax', 'easy-digital-downloads' ) . ' (' . html_entity_decode( edd_currency_filter( '' ) ) . ')',
|
57 |
+
'discount' => __( 'Discount Code', 'easy-digital-downloads' ),
|
58 |
+
'gateway' => __( 'Payment Method', 'easy-digital-downloads' ),
|
59 |
+
'trans_id' => __( 'Transaction ID', 'easy-digital-downloads' ),
|
60 |
+
'key' => __( 'Purchase Key', 'easy-digital-downloads' ),
|
61 |
+
'date' => __( 'Date', 'easy-digital-downloads' ),
|
62 |
+
'user' => __( 'User', 'easy-digital-downloads' ),
|
63 |
+
'currency' => __( 'Currency', 'easy-digital-downloads' ),
|
64 |
+
'ip' => __( 'IP Address', 'easy-digital-downloads' ),
|
65 |
+
'mode' => __( 'Mode (Live|Test)', 'easy-digital-downloads' ),
|
66 |
+
'status' => __( 'Status', 'easy-digital-downloads' )
|
67 |
);
|
68 |
|
69 |
if( ! edd_use_skus() ){
|
93 |
$args = array(
|
94 |
'number' => 30,
|
95 |
'page' => $this->step,
|
96 |
+
'status' => $this->status,
|
97 |
+
'order' => 'ASC',
|
98 |
+
'orderby' => 'date'
|
99 |
);
|
100 |
|
101 |
if( ! empty( $this->start ) || ! empty( $this->end ) ) {
|
123 |
$total = edd_get_payment_amount( $payment->ID );
|
124 |
$user_id = isset( $user_info['id'] ) && $user_info['id'] != -1 ? $user_info['id'] : $user_info['email'];
|
125 |
$products = '';
|
126 |
+
$products_raw = '';
|
127 |
$skus = '';
|
128 |
|
129 |
if ( $downloads ) {
|
141 |
$price = edd_get_download_final_price( $id, $user_info, $price_override );
|
142 |
}
|
143 |
|
144 |
+
$download_tax = isset( $download['tax'] ) ? $download['tax'] : 0;
|
145 |
+
|
146 |
+
/* Set up verbose product column */
|
147 |
|
|
|
148 |
$products .= html_entity_decode( get_the_title( $id ) );
|
149 |
|
150 |
if ( $qty > 1 ) {
|
156 |
if ( edd_use_skus() ) {
|
157 |
$sku = edd_get_download_sku( $id );
|
158 |
|
159 |
+
if ( ! empty( $sku ) ) {
|
160 |
$skus .= $sku;
|
161 |
+
}
|
162 |
}
|
163 |
|
164 |
if ( isset( $downloads[ $key ]['item_number'] ) && isset( $downloads[ $key ]['item_number']['options'] ) ) {
|
165 |
$price_options = $downloads[ $key ]['item_number']['options'];
|
166 |
|
167 |
+
if ( isset( $price_options['price_id'] ) && ! is_null( $price_options['price_id'] ) ) {
|
168 |
$products .= html_entity_decode( edd_get_price_option_name( $id, $price_options['price_id'], $payment->ID ) ) . ' - ';
|
169 |
}
|
170 |
}
|
172 |
$products .= html_entity_decode( edd_currency_filter( edd_format_amount( $price ) ) );
|
173 |
|
174 |
if ( $key != ( count( $downloads ) -1 ) ) {
|
175 |
+
|
176 |
$products .= ' / ';
|
177 |
|
178 |
+
if( edd_use_skus() ) {
|
179 |
$skus .= ' / ';
|
180 |
+
}
|
181 |
+
}
|
182 |
+
|
183 |
+
/* Set up raw products column - Nothing but product names */
|
184 |
+
$products_raw .= html_entity_decode( get_the_title( $id ) ) . '|' . $price . '{' . $download_tax . '}';
|
185 |
+
if ( $key != ( count( $downloads ) -1 ) ) {
|
186 |
+
|
187 |
+
$products_raw .= ' / ';
|
188 |
+
|
189 |
}
|
190 |
}
|
191 |
}
|
197 |
}
|
198 |
|
199 |
$data[] = array(
|
200 |
+
'id' => $payment->ID,
|
201 |
+
'seq_id' => edd_get_payment_number( $payment->ID ),
|
202 |
+
'email' => $payment_meta['email'],
|
203 |
+
'customer_id' => edd_get_payment_customer_id( $payment->ID ),
|
204 |
+
'first' => $user_info['first_name'],
|
205 |
+
'last' => $user_info['last_name'],
|
206 |
+
'address1' => isset( $user_info['address']['line1'] ) ? $user_info['address']['line1'] : '',
|
207 |
+
'address2' => isset( $user_info['address']['line2'] ) ? $user_info['address']['line2'] : '',
|
208 |
+
'city' => isset( $user_info['address']['city'] ) ? $user_info['address']['city'] : '',
|
209 |
+
'state' => isset( $user_info['address']['state'] ) ? $user_info['address']['state'] : '',
|
210 |
+
'country' => isset( $user_info['address']['country'] ) ? $user_info['address']['country'] : '',
|
211 |
+
'zip' => isset( $user_info['address']['zip'] ) ? $user_info['address']['zip'] : '',
|
212 |
+
'products' => $products,
|
213 |
+
'products_raw' => $products_raw,
|
214 |
+
'skus' => $skus,
|
215 |
+
'amount' => html_entity_decode( edd_format_amount( $total ) ), // The non-discounted item price
|
216 |
+
'tax' => html_entity_decode( edd_format_amount( edd_get_payment_tax( $payment->ID, $payment_meta ) ) ),
|
217 |
+
'discount' => isset( $user_info['discount'] ) && $user_info['discount'] != 'none' ? $user_info['discount'] : __( 'none', 'easy-digital-downloads' ),
|
218 |
+
'gateway' => edd_get_gateway_admin_label( get_post_meta( $payment->ID, '_edd_payment_gateway', true ) ),
|
219 |
+
'trans_id' => edd_get_payment_transaction_id( $payment->ID ),
|
220 |
+
'key' => $payment_meta['key'],
|
221 |
+
'date' => $payment->post_date,
|
222 |
+
'user' => $user ? $user->display_name : __( 'guest', 'easy-digital-downloads' ),
|
223 |
+
'currency' => edd_get_payment_currency_code( $payment->ID ),
|
224 |
+
'ip' => edd_get_payment_user_ip( $payment->ID ),
|
225 |
+
'mode' => edd_get_payment_meta( $payment->ID, '_edd_payment_mode', true ),
|
226 |
+
'status' => edd_get_payment_status( $payment, true )
|
227 |
);
|
228 |
|
229 |
}
|
includes/admin/reporting/graphing.php
CHANGED
@@ -30,12 +30,14 @@ function edd_reports_graph() {
|
|
30 |
break;
|
31 |
case 'last_year' :
|
32 |
case 'this_year' :
|
|
|
|
|
33 |
case 'last_quarter' :
|
34 |
case 'this_quarter' :
|
35 |
-
$day_by_day =
|
36 |
break;
|
37 |
case 'other' :
|
38 |
-
if( $dates['m_end'] - $dates['m_start'] >=
|
39 |
$day_by_day = false;
|
40 |
} else {
|
41 |
$day_by_day = true;
|
@@ -50,8 +52,6 @@ function edd_reports_graph() {
|
|
50 |
$sales_totals = 0; // Total sales for time period shown
|
51 |
|
52 |
$include_taxes = empty( $_GET['exclude_taxes'] ) ? true : false;
|
53 |
-
$earnings_data = array();
|
54 |
-
$sales_data = array();
|
55 |
|
56 |
if( $dates['range'] == 'today' || $dates['range'] == 'yesterday' ) {
|
57 |
// Hour by hour
|
@@ -112,6 +112,10 @@ function edd_reports_graph() {
|
|
112 |
} else {
|
113 |
|
114 |
$y = $dates['year'];
|
|
|
|
|
|
|
|
|
115 |
|
116 |
while( $y <= $dates['year_end'] ) {
|
117 |
|
@@ -135,73 +139,116 @@ function edd_reports_graph() {
|
|
135 |
$i = $month_start;
|
136 |
while ( $i <= $month_end ) {
|
137 |
|
138 |
-
if ( $day_by_day ) {
|
139 |
|
140 |
-
|
141 |
|
142 |
-
|
143 |
|
144 |
-
|
145 |
|
146 |
-
|
147 |
|
148 |
-
|
149 |
|
150 |
-
|
151 |
|
152 |
-
|
153 |
|
154 |
-
|
155 |
|
156 |
-
|
157 |
|
|
|
158 |
|
|
|
|
|
159 |
|
|
|
|
|
160 |
|
161 |
-
|
|
|
162 |
|
163 |
-
|
164 |
-
$sales_totals += $sales;
|
165 |
|
166 |
-
|
167 |
-
$earnings_totals += $earnings;
|
168 |
|
169 |
-
|
170 |
-
|
171 |
-
|
172 |
-
|
|
|
|
|
|
|
|
|
|
|
173 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
174 |
}
|
175 |
|
176 |
-
}
|
|
|
177 |
|
178 |
-
|
179 |
-
|
|
|
|
|
|
|
|
|
180 |
|
181 |
-
|
182 |
-
|
183 |
|
184 |
-
|
|
|
185 |
|
186 |
-
|
187 |
|
188 |
-
|
|
|
189 |
|
190 |
-
|
191 |
|
192 |
-
|
|
|
193 |
|
194 |
-
$
|
|
|
|
|
|
|
195 |
$sales_data[] = array( $date, $sales );
|
196 |
-
$earnings_data[] = array( $date, $earnings );
|
197 |
|
198 |
}
|
199 |
|
200 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
201 |
|
202 |
}
|
203 |
|
204 |
-
$y++;
|
205 |
}
|
206 |
|
207 |
}
|
@@ -227,7 +274,7 @@ function edd_reports_graph() {
|
|
227 |
$graph->set( 'multiple_y_axes', true );
|
228 |
$graph->display();
|
229 |
|
230 |
-
if( 'this_month' == $dates['range'] ) {
|
231 |
$estimated = edd_estimated_monthly_stats( $include_taxes );
|
232 |
}
|
233 |
?>
|
@@ -245,7 +292,7 @@ function edd_reports_graph() {
|
|
245 |
</p>
|
246 |
<p class="edd_graph_totals"><strong><?php _e( 'Total sales for period shown: ', 'easy-digital-downloads' ); echo edd_format_amount( $sales_totals, false ); ?></strong></p>
|
247 |
|
248 |
-
<?php if( 'this_month' == $dates['range'] ) : ?>
|
249 |
<p class="edd_graph_totals">
|
250 |
<strong>
|
251 |
<?php
|
@@ -399,8 +446,9 @@ function edd_reports_graph_of_download( $download_id = 0 ) {
|
|
399 |
} else {
|
400 |
|
401 |
$y = $dates['year'];
|
|
|
402 |
|
403 |
-
while( $y <= $dates['year_end'] )
|
404 |
|
405 |
$last_year = false;
|
406 |
|
@@ -411,67 +459,131 @@ function edd_reports_graph_of_download( $download_id = 0 ) {
|
|
411 |
} elseif( $y == $dates['year'] ) {
|
412 |
$month_start = $dates['m_start'];
|
413 |
$month_end = 12;
|
|
|
|
|
|
|
414 |
} else {
|
415 |
$month_start = 1;
|
416 |
$month_end = 12;
|
417 |
}
|
418 |
|
419 |
$i = $month_start;
|
420 |
-
while ( $i <= $month_end )
|
|
|
421 |
|
422 |
-
|
423 |
|
424 |
-
|
425 |
|
426 |
-
|
427 |
|
428 |
-
|
429 |
|
430 |
-
$
|
431 |
|
432 |
}
|
433 |
|
434 |
-
|
435 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
436 |
|
437 |
-
|
438 |
-
|
439 |
|
440 |
-
|
441 |
-
|
442 |
|
443 |
-
|
444 |
-
|
445 |
|
446 |
-
$sales_data[] = array( $date * 1000, $sales );
|
447 |
-
$earnings_data[] = array( $date * 1000, $earnings );
|
448 |
$d++;
|
449 |
|
450 |
-
|
|
|
|
|
451 |
|
452 |
-
|
453 |
|
454 |
-
|
|
|
455 |
|
456 |
-
|
457 |
-
|
458 |
|
459 |
-
|
460 |
-
|
461 |
|
462 |
-
|
463 |
-
|
|
|
|
|
|
|
|
|
464 |
|
465 |
-
|
466 |
-
|
467 |
-
endif;
|
468 |
|
469 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
470 |
|
471 |
-
|
|
|
472 |
|
473 |
-
$
|
474 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
475 |
|
476 |
}
|
477 |
|
@@ -618,12 +730,15 @@ function edd_get_report_dates() {
|
|
618 |
$current_time = current_time( 'timestamp' );
|
619 |
|
620 |
$dates['range'] = isset( $_GET['range'] ) ? $_GET['range'] : 'this_month';
|
621 |
-
|
622 |
-
|
623 |
-
|
624 |
-
|
625 |
-
|
626 |
-
|
|
|
|
|
|
|
627 |
|
628 |
// Modify dates based on predefined ranges
|
629 |
switch ( $dates['range'] ) :
|
@@ -704,33 +819,34 @@ function edd_get_report_dates() {
|
|
704 |
|
705 |
case 'this_quarter' :
|
706 |
$month_now = date( 'n', $current_time );
|
|
|
|
|
707 |
|
708 |
if ( $month_now <= 3 ) {
|
709 |
|
710 |
-
$dates['m_start']
|
711 |
-
$dates['m_end']
|
712 |
-
|
713 |
|
714 |
} else if ( $month_now <= 6 ) {
|
715 |
|
716 |
$dates['m_start'] = 4;
|
717 |
-
$dates['m_end'] =
|
718 |
-
|
719 |
|
720 |
} else if ( $month_now <= 9 ) {
|
721 |
|
722 |
$dates['m_start'] = 7;
|
723 |
-
$dates['m_end'] =
|
724 |
-
$dates['year'] = date( 'Y', $current_time );
|
725 |
|
726 |
} else {
|
727 |
|
728 |
$dates['m_start'] = 10;
|
729 |
-
$dates['m_end'] =
|
730 |
-
$dates['year'] = date( 'Y', $current_time );
|
731 |
-
$dates['year_end'] = date( 'Y', $current_time ) + 1;
|
732 |
|
733 |
}
|
|
|
|
|
734 |
break;
|
735 |
|
736 |
case 'last_quarter' :
|
@@ -741,7 +857,6 @@ function edd_get_report_dates() {
|
|
741 |
$dates['m_start'] = 10;
|
742 |
$dates['m_end'] = 12;
|
743 |
$dates['year'] = date( 'Y', $current_time ) - 1; // Previous year
|
744 |
-
$dates['year_end'] = date( 'Y', $current_time ) - 1; // Previous year
|
745 |
|
746 |
} else if ( $month_now <= 6 ) {
|
747 |
|
@@ -762,12 +877,16 @@ function edd_get_report_dates() {
|
|
762 |
$dates['year'] = date( 'Y', $current_time );
|
763 |
|
764 |
}
|
|
|
|
|
|
|
765 |
break;
|
766 |
|
767 |
case 'this_year' :
|
768 |
-
$dates['m_start']
|
769 |
-
$dates['m_end']
|
770 |
-
$dates['year']
|
|
|
771 |
break;
|
772 |
|
773 |
case 'last_year' :
|
30 |
break;
|
31 |
case 'last_year' :
|
32 |
case 'this_year' :
|
33 |
+
$day_by_day = false;
|
34 |
+
break;
|
35 |
case 'last_quarter' :
|
36 |
case 'this_quarter' :
|
37 |
+
$day_by_day = true;
|
38 |
break;
|
39 |
case 'other' :
|
40 |
+
if( $dates['m_end'] - $dates['m_start'] >= 3 || ( $dates['year_end'] > $dates['year'] && ( $dates['m_start'] - $dates['m_end'] ) != 10 ) ) {
|
41 |
$day_by_day = false;
|
42 |
} else {
|
43 |
$day_by_day = true;
|
52 |
$sales_totals = 0; // Total sales for time period shown
|
53 |
|
54 |
$include_taxes = empty( $_GET['exclude_taxes'] ) ? true : false;
|
|
|
|
|
55 |
|
56 |
if( $dates['range'] == 'today' || $dates['range'] == 'yesterday' ) {
|
57 |
// Hour by hour
|
112 |
} else {
|
113 |
|
114 |
$y = $dates['year'];
|
115 |
+
$temp_data = array(
|
116 |
+
'sales' => array(),
|
117 |
+
'earnings' => array(),
|
118 |
+
);
|
119 |
|
120 |
while( $y <= $dates['year_end'] ) {
|
121 |
|
139 |
$i = $month_start;
|
140 |
while ( $i <= $month_end ) {
|
141 |
|
|
|
142 |
|
143 |
+
$d = $dates['day'];
|
144 |
|
145 |
+
if( $i == $month_end ) {
|
146 |
|
147 |
+
$num_of_days = $dates['day_end'];
|
148 |
|
149 |
+
if ( $month_start < $month_end ) {
|
150 |
|
151 |
+
$d = 1;
|
152 |
|
153 |
+
}
|
154 |
|
155 |
+
} else {
|
156 |
|
157 |
+
$num_of_days = cal_days_in_month( CAL_GREGORIAN, $i, $y );
|
158 |
|
159 |
+
}
|
160 |
|
161 |
+
while ( $d <= $num_of_days ) {
|
162 |
|
163 |
+
$earnings = edd_get_earnings_by_date( $d, $i, $y, null, $include_taxes );
|
164 |
+
$earnings_totals += $earnings;
|
165 |
|
166 |
+
$sales = edd_get_sales_by_date( $d, $i, $y );
|
167 |
+
$sales_totals += $sales;
|
168 |
|
169 |
+
$temp_data['earnings'][ $y ][ $i ][ $d ] = $earnings;
|
170 |
+
$temp_data['sales'][ $y ][ $i ][ $d ] = $sales;
|
171 |
|
172 |
+
$d++;
|
|
|
173 |
|
174 |
+
}
|
|
|
175 |
|
176 |
+
$i++;
|
177 |
+
|
178 |
+
}
|
179 |
+
|
180 |
+
$y++;
|
181 |
+
}
|
182 |
+
|
183 |
+
$sales_data = array();
|
184 |
+
$earnings_data = array();
|
185 |
|
186 |
+
// When using 3 months or smaller as the custom range, show each day individually on the graph
|
187 |
+
if ( $day_by_day ) {
|
188 |
+
|
189 |
+
foreach ( $temp_data[ 'sales' ] as $year => $months ) {
|
190 |
+
foreach( $months as $month => $days ) {
|
191 |
+
foreach ( $days as $day => $sales ) {
|
192 |
+
$date = mktime( 0, 0, 0, $month, $day, $year ) * 1000;
|
193 |
+
$sales_data[] = array( $date, $sales );
|
194 |
}
|
195 |
|
196 |
+
}
|
197 |
+
}
|
198 |
|
199 |
+
foreach ( $temp_data[ 'earnings' ] as $year => $months ) {
|
200 |
+
foreach( $months as $month => $days ) {
|
201 |
+
foreach ( $days as $day => $earnings ) {
|
202 |
+
$date = mktime( 0, 0, 0, $month, $day, $year ) * 1000;
|
203 |
+
$earnings_data[] = array( $date, $earnings );
|
204 |
+
}
|
205 |
|
206 |
+
}
|
207 |
+
}
|
208 |
|
209 |
+
// When showing more than 3 months of results, group them by month, by the first (except for the last month, group on the last day of the month selected)
|
210 |
+
} else {
|
211 |
|
212 |
+
foreach ( $temp_data[ 'sales' ] as $year => $months ) {
|
213 |
|
214 |
+
$month_keys = array_keys( $months );
|
215 |
+
$last_month = end( $month_keys );
|
216 |
|
217 |
+
foreach( $months as $month => $days ) {
|
218 |
|
219 |
+
$day_keys = array_keys( $days );
|
220 |
+
$last_day = end( $day_keys );
|
221 |
|
222 |
+
$consolidated_date = $month === $last_month ? $last_day : 1;
|
223 |
+
|
224 |
+
$sales = array_sum( $days );
|
225 |
+
$date = mktime( 0, 0, 0, $month, $consolidated_date, $year ) * 1000;
|
226 |
$sales_data[] = array( $date, $sales );
|
|
|
227 |
|
228 |
}
|
229 |
|
230 |
+
}
|
231 |
+
|
232 |
+
foreach ( $temp_data[ 'earnings' ] as $year => $months ) {
|
233 |
+
|
234 |
+
$month_keys = array_keys( $months );
|
235 |
+
$last_month = end( $month_keys );
|
236 |
+
|
237 |
+
foreach( $months as $month => $days ) {
|
238 |
+
|
239 |
+
$day_keys = array_keys( $days );
|
240 |
+
$last_day = end( $day_keys );
|
241 |
+
|
242 |
+
$consolidated_date = $month === $last_month ? $last_day : 1;
|
243 |
+
|
244 |
+
$earnings = array_sum( $days );
|
245 |
+
$date = mktime( 0, 0, 0, $month, $consolidated_date, $year ) * 1000;
|
246 |
+
$earnings_data[] = array( $date, $earnings );
|
247 |
+
|
248 |
+
}
|
249 |
|
250 |
}
|
251 |
|
|
|
252 |
}
|
253 |
|
254 |
}
|
274 |
$graph->set( 'multiple_y_axes', true );
|
275 |
$graph->display();
|
276 |
|
277 |
+
if( ! empty( $dates['range'] ) && 'this_month' == $dates['range'] ) {
|
278 |
$estimated = edd_estimated_monthly_stats( $include_taxes );
|
279 |
}
|
280 |
?>
|
292 |
</p>
|
293 |
<p class="edd_graph_totals"><strong><?php _e( 'Total sales for period shown: ', 'easy-digital-downloads' ); echo edd_format_amount( $sales_totals, false ); ?></strong></p>
|
294 |
|
295 |
+
<?php if( ! empty( $dates['range'] ) && 'this_month' == $dates['range'] ) : ?>
|
296 |
<p class="edd_graph_totals">
|
297 |
<strong>
|
298 |
<?php
|
446 |
} else {
|
447 |
|
448 |
$y = $dates['year'];
|
449 |
+
$temp_data = array();
|
450 |
|
451 |
+
while( $y <= $dates['year_end'] ) {
|
452 |
|
453 |
$last_year = false;
|
454 |
|
459 |
} elseif( $y == $dates['year'] ) {
|
460 |
$month_start = $dates['m_start'];
|
461 |
$month_end = 12;
|
462 |
+
} elseif ( $y == $dates['year_end'] ) {
|
463 |
+
$month_start = 1;
|
464 |
+
$month_end = $dates['m_end'];
|
465 |
} else {
|
466 |
$month_start = 1;
|
467 |
$month_end = 12;
|
468 |
}
|
469 |
|
470 |
$i = $month_start;
|
471 |
+
while ( $i <= $month_end ) {
|
472 |
+
|
473 |
|
474 |
+
$d = $dates['day'];
|
475 |
|
476 |
+
if( $i == $month_end ) {
|
477 |
|
478 |
+
$num_of_days = $dates['day_end'];
|
479 |
|
480 |
+
if ( $month_start < $month_end ) {
|
481 |
|
482 |
+
$d = 1;
|
483 |
|
484 |
}
|
485 |
|
486 |
+
} else {
|
487 |
+
|
488 |
+
$num_of_days = cal_days_in_month( CAL_GREGORIAN, $i, $y );
|
489 |
+
|
490 |
+
}
|
491 |
+
|
492 |
+
while ( $d <= $num_of_days ) {
|
493 |
+
|
494 |
+
$date = mktime( 0, 0, 0, $i, $d, $y );
|
495 |
+
$end_date = mktime( 23, 59, 59, $i, $d, $y );
|
496 |
|
497 |
+
$earnings = $stats->get_earnings( $download_id, $date, $end_date, $include_taxes );
|
498 |
+
$earnings_totals += $earnings;
|
499 |
|
500 |
+
$sales = $stats->get_sales( $download_id, $date, $end_date );
|
501 |
+
$sales_totals += $sales;
|
502 |
|
503 |
+
$temp_data['earnings'][ $y ][ $i ][ $d ] = $earnings;
|
504 |
+
$temp_data['sales'][ $y ][ $i ][ $d ] = $sales;
|
505 |
|
|
|
|
|
506 |
$d++;
|
507 |
|
508 |
+
}
|
509 |
+
|
510 |
+
$i++;
|
511 |
|
512 |
+
}
|
513 |
|
514 |
+
$y++;
|
515 |
+
}
|
516 |
|
517 |
+
$sales_data = array();
|
518 |
+
$earnings_data = array();
|
519 |
|
520 |
+
// When using 2 months or smaller as the custom range, show each day individually on the graph
|
521 |
+
if ( $day_by_day ) {
|
522 |
|
523 |
+
foreach ( $temp_data[ 'sales' ] as $year => $months ) {
|
524 |
+
foreach( $months as $month => $dates ) {
|
525 |
+
foreach ( $dates as $day => $sales ) {
|
526 |
+
$date = mktime( 0, 0, 0, $month, $day, $year ) * 1000;
|
527 |
+
$sales_data[] = array( $date, $sales );
|
528 |
+
}
|
529 |
|
530 |
+
}
|
531 |
+
}
|
|
|
532 |
|
533 |
+
foreach ( $temp_data[ 'earnings' ] as $year => $months ) {
|
534 |
+
foreach( $months as $month => $dates ) {
|
535 |
+
foreach ( $dates as $day => $sales ) {
|
536 |
+
$date = mktime( 0, 0, 0, $month, $day, $year ) * 1000;
|
537 |
+
$earnings_data[] = array( $date, $earnings );
|
538 |
+
}
|
539 |
+
|
540 |
+
}
|
541 |
+
}
|
542 |
|
543 |
+
// When showing more than 2 months of results, group them by month, by the first (except for the last month, group on the last day of the month selected)
|
544 |
+
} else {
|
545 |
|
546 |
+
foreach ( $temp_data[ 'sales' ] as $year => $months ) {
|
547 |
+
|
548 |
+
$month_keys = array_keys( $months );
|
549 |
+
$last_month = end( $month_keys );
|
550 |
+
|
551 |
+
foreach( $months as $month => $days ) {
|
552 |
+
|
553 |
+
$day_keys = array_keys( $days );
|
554 |
+
$last_day = end( $day_keys );
|
555 |
+
|
556 |
+
$consolidated_date = $month === $last_month ? $last_day : 1;
|
557 |
+
|
558 |
+
$sales = array_sum( $days );
|
559 |
+
$date = mktime( 0, 0, 0, $month, $consolidated_date, $year ) * 1000;
|
560 |
+
$sales_data[] = array( $date, $sales );
|
561 |
+
|
562 |
+
}
|
563 |
+
|
564 |
+
}
|
565 |
+
|
566 |
+
foreach ( $temp_data[ 'earnings' ] as $year => $months ) {
|
567 |
+
|
568 |
+
$month_keys = array_keys( $months );
|
569 |
+
$last_month = end( $month_keys );
|
570 |
+
|
571 |
+
foreach( $months as $month => $days ) {
|
572 |
+
|
573 |
+
$day_keys = array_keys( $days );
|
574 |
+
$last_day = end( $day_keys );
|
575 |
+
|
576 |
+
$consolidated_date = $month === $last_month ? $last_day : 1;
|
577 |
+
|
578 |
+
$earnings = array_sum( $days );
|
579 |
+
$date = mktime( 0, 0, 0, $month, $consolidated_date, $year ) * 1000;
|
580 |
+
$earnings_data[] = array( $date, $earnings );
|
581 |
+
|
582 |
+
}
|
583 |
+
|
584 |
+
}
|
585 |
+
|
586 |
+
}
|
587 |
|
588 |
}
|
589 |
|
730 |
$current_time = current_time( 'timestamp' );
|
731 |
|
732 |
$dates['range'] = isset( $_GET['range'] ) ? $_GET['range'] : 'this_month';
|
733 |
+
|
734 |
+
if ( 'custom' !== $dates['range'] ) {
|
735 |
+
$dates['year'] = isset( $_GET['year'] ) ? $_GET['year'] : date( 'Y' );
|
736 |
+
$dates['year_end'] = isset( $_GET['year_end'] )? $_GET['year_end']: date( 'Y' );
|
737 |
+
$dates['m_start'] = isset( $_GET['m_start'] ) ? $_GET['m_start'] : 1;
|
738 |
+
$dates['m_end'] = isset( $_GET['m_end'] ) ? $_GET['m_end'] : 12;
|
739 |
+
$dates['day'] = isset( $_GET['day'] ) ? $_GET['day'] : 1;
|
740 |
+
$dates['day_end'] = isset( $_GET['day_end'] ) ? $_GET['day_end'] : cal_days_in_month( CAL_GREGORIAN, $dates['m_end'], $dates['year'] );
|
741 |
+
}
|
742 |
|
743 |
// Modify dates based on predefined ranges
|
744 |
switch ( $dates['range'] ) :
|
819 |
|
820 |
case 'this_quarter' :
|
821 |
$month_now = date( 'n', $current_time );
|
822 |
+
$dates['year'] = date( 'Y', $current_time );
|
823 |
+
$dates['year_end'] = $dates['year'];
|
824 |
|
825 |
if ( $month_now <= 3 ) {
|
826 |
|
827 |
+
$dates['m_start'] = 1;
|
828 |
+
$dates['m_end'] = 3;
|
829 |
+
|
830 |
|
831 |
} else if ( $month_now <= 6 ) {
|
832 |
|
833 |
$dates['m_start'] = 4;
|
834 |
+
$dates['m_end'] = 6;
|
835 |
+
|
836 |
|
837 |
} else if ( $month_now <= 9 ) {
|
838 |
|
839 |
$dates['m_start'] = 7;
|
840 |
+
$dates['m_end'] = 9;
|
|
|
841 |
|
842 |
} else {
|
843 |
|
844 |
$dates['m_start'] = 10;
|
845 |
+
$dates['m_end'] = 12;
|
|
|
|
|
846 |
|
847 |
}
|
848 |
+
|
849 |
+
$dates['day_end'] = cal_days_in_month( CAL_GREGORIAN, $dates['m_end'], $dates['year'] );
|
850 |
break;
|
851 |
|
852 |
case 'last_quarter' :
|
857 |
$dates['m_start'] = 10;
|
858 |
$dates['m_end'] = 12;
|
859 |
$dates['year'] = date( 'Y', $current_time ) - 1; // Previous year
|
|
|
860 |
|
861 |
} else if ( $month_now <= 6 ) {
|
862 |
|
877 |
$dates['year'] = date( 'Y', $current_time );
|
878 |
|
879 |
}
|
880 |
+
|
881 |
+
$dates['day_end'] = cal_days_in_month( CAL_GREGORIAN, $dates['m_end'], $dates['year'] );
|
882 |
+
$dates['year_end'] = $dates['year'];
|
883 |
break;
|
884 |
|
885 |
case 'this_year' :
|
886 |
+
$dates['m_start'] = 1;
|
887 |
+
$dates['m_end'] = 12;
|
888 |
+
$dates['year'] = date( 'Y', $current_time );
|
889 |
+
$dates['year_end'] = $dates['year'];
|
890 |
break;
|
891 |
|
892 |
case 'last_year' :
|
includes/admin/reporting/reports.php
CHANGED
@@ -378,7 +378,8 @@ function edd_reports_tab_export() {
|
|
378 |
<h3><span><?php _e('Export Payment History','easy-digital-downloads' ); ?></span></h3>
|
379 |
<div class="inside">
|
380 |
<p><?php _e( 'Download a CSV of all payments recorded.', 'easy-digital-downloads' ); ?></p>
|
381 |
-
|
|
|
382 |
<?php echo EDD()->html->date_field( array( 'id' => 'edd-payment-export-start', 'name' => 'start', 'placeholder' => __( 'Choose start date', 'easy-digital-downloads' ) )); ?>
|
383 |
<?php echo EDD()->html->date_field( array( 'id' => 'edd-payment-export-end','name' => 'end', 'placeholder' => __( 'Choose end date', 'easy-digital-downloads' ) )); ?>
|
384 |
<select name="status">
|
@@ -397,6 +398,7 @@ function edd_reports_tab_export() {
|
|
397 |
<span class="spinner"></span>
|
398 |
</span>
|
399 |
</form>
|
|
|
400 |
</div><!-- .inside -->
|
401 |
</div><!-- .postbox -->
|
402 |
|
@@ -404,7 +406,7 @@ function edd_reports_tab_export() {
|
|
404 |
<h3><span><?php _e('Export Customers in CSV','easy-digital-downloads' ); ?></span></h3>
|
405 |
<div class="inside">
|
406 |
<p><?php _e( 'Download a CSV of customers.', 'easy-digital-downloads' ); ?></p>
|
407 |
-
<form id="edd-export-customers" class="edd-export-form" method="post">
|
408 |
<?php echo EDD()->html->product_dropdown( array( 'name' => 'download', 'id' => 'edd_customer_export_download', 'chosen' => true ) ); ?>
|
409 |
<?php wp_nonce_field( 'edd_ajax_export', 'edd_ajax_export' ); ?>
|
410 |
<input type="hidden" name="edd-export-class" value="EDD_Batch_Customers_Export"/>
|
@@ -417,7 +419,7 @@ function edd_reports_tab_export() {
|
|
417 |
<h3><span><?php _e('Export Download Products in CSV','easy-digital-downloads' ); ?></span></h3>
|
418 |
<div class="inside">
|
419 |
<p><?php _e( 'Download a CSV of download products.', 'easy-digital-downloads' ); ?></p>
|
420 |
-
<form id="edd-export-file-downloads" class="edd-export-form" method="post">
|
421 |
<?php wp_nonce_field( 'edd_ajax_export', 'edd_ajax_export' ); ?>
|
422 |
<input type="hidden" name="edd-export-class" value="EDD_Batch_Downloads_Export"/>
|
423 |
<input type="submit" value="<?php _e( 'Generate CSV', 'easy-digital-downloads' ); ?>" class="button-secondary"/>
|
@@ -429,7 +431,7 @@ function edd_reports_tab_export() {
|
|
429 |
<h3><span><?php _e('Export Download History in CSV','easy-digital-downloads' ); ?></span></h3>
|
430 |
<div class="inside">
|
431 |
<p><?php _e( 'Download a CSV of file downloads.', 'easy-digital-downloads' ); ?></p>
|
432 |
-
<form id="edd-export-file-downloads" class="edd-export-form" method="post">
|
433 |
<?php echo EDD()->html->date_field( array( 'id' => 'edd-file-download-export-start', 'name' => 'start', 'placeholder' => __( 'Choose start date', 'easy-digital-downloads' ) )); ?>
|
434 |
<?php echo EDD()->html->date_field( array( 'id' => 'edd-file-download-export-end', 'name' => 'end', 'placeholder' => __( 'Choose end date', 'easy-digital-downloads' ) )); ?>
|
435 |
<?php wp_nonce_field( 'edd_ajax_export', 'edd_ajax_export' ); ?>
|
378 |
<h3><span><?php _e('Export Payment History','easy-digital-downloads' ); ?></span></h3>
|
379 |
<div class="inside">
|
380 |
<p><?php _e( 'Download a CSV of all payments recorded.', 'easy-digital-downloads' ); ?></p>
|
381 |
+
|
382 |
+
<form id="edd-export-payments" class="edd-export-form edd-import-export-form" method="post">
|
383 |
<?php echo EDD()->html->date_field( array( 'id' => 'edd-payment-export-start', 'name' => 'start', 'placeholder' => __( 'Choose start date', 'easy-digital-downloads' ) )); ?>
|
384 |
<?php echo EDD()->html->date_field( array( 'id' => 'edd-payment-export-end','name' => 'end', 'placeholder' => __( 'Choose end date', 'easy-digital-downloads' ) )); ?>
|
385 |
<select name="status">
|
398 |
<span class="spinner"></span>
|
399 |
</span>
|
400 |
</form>
|
401 |
+
|
402 |
</div><!-- .inside -->
|
403 |
</div><!-- .postbox -->
|
404 |
|
406 |
<h3><span><?php _e('Export Customers in CSV','easy-digital-downloads' ); ?></span></h3>
|
407 |
<div class="inside">
|
408 |
<p><?php _e( 'Download a CSV of customers.', 'easy-digital-downloads' ); ?></p>
|
409 |
+
<form id="edd-export-customers" class="edd-export-form edd-import-export-form" method="post">
|
410 |
<?php echo EDD()->html->product_dropdown( array( 'name' => 'download', 'id' => 'edd_customer_export_download', 'chosen' => true ) ); ?>
|
411 |
<?php wp_nonce_field( 'edd_ajax_export', 'edd_ajax_export' ); ?>
|
412 |
<input type="hidden" name="edd-export-class" value="EDD_Batch_Customers_Export"/>
|
419 |
<h3><span><?php _e('Export Download Products in CSV','easy-digital-downloads' ); ?></span></h3>
|
420 |
<div class="inside">
|
421 |
<p><?php _e( 'Download a CSV of download products.', 'easy-digital-downloads' ); ?></p>
|
422 |
+
<form id="edd-export-file-downloads" class="edd-export-form edd-import-export-form" method="post">
|
423 |
<?php wp_nonce_field( 'edd_ajax_export', 'edd_ajax_export' ); ?>
|
424 |
<input type="hidden" name="edd-export-class" value="EDD_Batch_Downloads_Export"/>
|
425 |
<input type="submit" value="<?php _e( 'Generate CSV', 'easy-digital-downloads' ); ?>" class="button-secondary"/>
|
431 |
<h3><span><?php _e('Export Download History in CSV','easy-digital-downloads' ); ?></span></h3>
|
432 |
<div class="inside">
|
433 |
<p><?php _e( 'Download a CSV of file downloads.', 'easy-digital-downloads' ); ?></p>
|
434 |
+
<form id="edd-export-file-downloads" class="edd-export-form edd-import-export-form" method="post">
|
435 |
<?php echo EDD()->html->date_field( array( 'id' => 'edd-file-download-export-start', 'name' => 'start', 'placeholder' => __( 'Choose start date', 'easy-digital-downloads' ) )); ?>
|
436 |
<?php echo EDD()->html->date_field( array( 'id' => 'edd-file-download-export-end', 'name' => 'end', 'placeholder' => __( 'Choose end date', 'easy-digital-downloads' ) )); ?>
|
437 |
<?php wp_nonce_field( 'edd_ajax_export', 'edd_ajax_export' ); ?>
|
includes/admin/settings/display-settings.php
CHANGED
@@ -61,7 +61,7 @@ function edd_options_page() {
|
|
61 |
|
62 |
ob_start();
|
63 |
?>
|
64 |
-
<div class="wrap">
|
65 |
<h1 class="nav-tab-wrapper">
|
66 |
<?php
|
67 |
foreach( edd_get_settings_tabs() as $tab_id => $tab_name ) {
|
@@ -76,7 +76,7 @@ function edd_options_page() {
|
|
76 |
|
77 |
$active = $active_tab == $tab_id ? ' nav-tab-active' : '';
|
78 |
|
79 |
-
echo '<a href="' . esc_url( $tab_url ) . '"
|
80 |
echo esc_html( $tab_name );
|
81 |
echo '</a>';
|
82 |
}
|
61 |
|
62 |
ob_start();
|
63 |
?>
|
64 |
+
<div class="wrap <?php echo 'wrap-' . $active_tab; ?>">
|
65 |
<h1 class="nav-tab-wrapper">
|
66 |
<?php
|
67 |
foreach( edd_get_settings_tabs() as $tab_id => $tab_name ) {
|
76 |
|
77 |
$active = $active_tab == $tab_id ? ' nav-tab-active' : '';
|
78 |
|
79 |
+
echo '<a href="' . esc_url( $tab_url ) . '" class="nav-tab' . $active . '">';
|
80 |
echo esc_html( $tab_name );
|
81 |
echo '</a>';
|
82 |
}
|
includes/admin/settings/register-settings.php
CHANGED
@@ -19,6 +19,7 @@ if ( !defined( 'ABSPATH' ) ) exit;
|
|
19 |
* Looks to see if the specified setting exists, returns default if not
|
20 |
*
|
21 |
* @since 1.8.4
|
|
|
22 |
* @return mixed
|
23 |
*/
|
24 |
function edd_get_option( $key = '', $default = false ) {
|
@@ -38,6 +39,7 @@ function edd_get_option( $key = '', $default = false ) {
|
|
38 |
* @since 2.3
|
39 |
* @param string $key The Key to update
|
40 |
* @param string|bool|int $value The value to set the key to
|
|
|
41 |
* @return boolean True if updated, false if not.
|
42 |
*/
|
43 |
function edd_update_option( $key = '', $value = false ) {
|
@@ -79,6 +81,7 @@ function edd_update_option( $key = '', $value = false ) {
|
|
79 |
*
|
80 |
* @since 2.3
|
81 |
* @param string $key The Key to delete
|
|
|
82 |
* @return boolean True if updated, false if not.
|
83 |
*/
|
84 |
function edd_delete_option( $key = '' ) {
|
@@ -186,21 +189,23 @@ function edd_register_settings() {
|
|
186 |
'edd_settings_' . $tab . '_' . $section,
|
187 |
'edd_settings_' . $tab . '_' . $section,
|
188 |
array(
|
189 |
-
'section'
|
190 |
-
'id'
|
191 |
-
'desc'
|
192 |
-
'name'
|
193 |
-
'size'
|
194 |
-
'options'
|
195 |
-
'std'
|
196 |
-
'min'
|
197 |
-
'max'
|
198 |
-
'step'
|
199 |
-
'chosen'
|
200 |
-
'placeholder'
|
201 |
-
'allow_blank'
|
202 |
-
'readonly'
|
203 |
-
'faux'
|
|
|
|
|
204 |
)
|
205 |
);
|
206 |
}
|
@@ -236,6 +241,8 @@ function edd_get_registered_settings() {
|
|
236 |
'name' => '<h3>' . __( 'Page Settings', 'easy-digital-downloads' ) . '</h3>',
|
237 |
'desc' => '',
|
238 |
'type' => 'header',
|
|
|
|
|
239 |
),
|
240 |
'purchase_page' => array(
|
241 |
'id' => 'purchase_page',
|
@@ -258,7 +265,7 @@ function edd_get_registered_settings() {
|
|
258 |
'failure_page' => array(
|
259 |
'id' => 'failure_page',
|
260 |
'name' => __( 'Failed Transaction Page', 'easy-digital-downloads' ),
|
261 |
-
'desc' => __( 'This is the page buyers are sent to if their transaction is cancelled or fails', 'easy-digital-downloads' ),
|
262 |
'type' => 'select',
|
263 |
'options' => edd_get_pages(),
|
264 |
'chosen' => true,
|
@@ -267,17 +274,19 @@ function edd_get_registered_settings() {
|
|
267 |
'purchase_history_page' => array(
|
268 |
'id' => 'purchase_history_page',
|
269 |
'name' => __( 'Purchase History Page', 'easy-digital-downloads' ),
|
270 |
-
'desc' => __( 'This page shows a complete purchase history for the current user, including download links', 'easy-digital-downloads' ),
|
271 |
'type' => 'select',
|
272 |
'options' => edd_get_pages(),
|
273 |
'chosen' => true,
|
274 |
'placeholder' => __( 'Select a page', 'easy-digital-downloads' ),
|
275 |
),
|
276 |
'locale_settings' => array(
|
277 |
-
'id'
|
278 |
-
'name'
|
279 |
-
'desc'
|
280 |
-
'type'
|
|
|
|
|
281 |
),
|
282 |
'base_country' => array(
|
283 |
'id' => 'base_country',
|
@@ -360,6 +369,8 @@ function edd_get_registered_settings() {
|
|
360 |
'name' => '<h3>' . __( 'API Settings', 'easy-digital-downloads' ) . '</h3>',
|
361 |
'desc' => '',
|
362 |
'type' => 'header',
|
|
|
|
|
363 |
),
|
364 |
'api_allow_user_keys' => array(
|
365 |
'id' => 'api_allow_user_keys',
|
@@ -367,6 +378,11 @@ function edd_get_registered_settings() {
|
|
367 |
'desc' => __( 'Check this box to allow all users to generate API keys. Users with the \'manage_shop_settings\' capability are always allowed to generate keys.', 'easy-digital-downloads' ),
|
368 |
'type' => 'checkbox',
|
369 |
),
|
|
|
|
|
|
|
|
|
|
|
370 |
),
|
371 |
)
|
372 |
),
|
@@ -415,33 +431,6 @@ function edd_get_registered_settings() {
|
|
415 |
),
|
416 |
),
|
417 |
),
|
418 |
-
'paypal' => array(
|
419 |
-
'paypal_settings' => array(
|
420 |
-
'id' => 'paypal_settings',
|
421 |
-
'name' => '<h3>' . __( 'PayPal Standard Settings', 'easy-digital-downloads' ) . '</h3>',
|
422 |
-
'type' => 'header',
|
423 |
-
),
|
424 |
-
'paypal_email' => array(
|
425 |
-
'id' => 'paypal_email',
|
426 |
-
'name' => __( 'PayPal Email', 'easy-digital-downloads' ),
|
427 |
-
'desc' => __( 'Enter your PayPal account\'s email', 'easy-digital-downloads' ),
|
428 |
-
'type' => 'text',
|
429 |
-
'size' => 'regular',
|
430 |
-
),
|
431 |
-
'paypal_page_style' => array(
|
432 |
-
'id' => 'paypal_page_style',
|
433 |
-
'name' => __( 'PayPal Page Style', 'easy-digital-downloads' ),
|
434 |
-
'desc' => __( 'Enter the name of the page style to use, or leave blank for default', 'easy-digital-downloads' ),
|
435 |
-
'type' => 'text',
|
436 |
-
'size' => 'regular',
|
437 |
-
),
|
438 |
-
'disable_paypal_verification' => array(
|
439 |
-
'id' => 'disable_paypal_verification',
|
440 |
-
'name' => __( 'Disable PayPal IPN Verification', 'easy-digital-downloads' ),
|
441 |
-
'desc' => __( 'If payments are not getting marked as complete, then check this box. This forces the site to use a slightly less secure method of verifying purchases.', 'easy-digital-downloads' ),
|
442 |
-
'type' => 'checkbox',
|
443 |
-
),
|
444 |
-
),
|
445 |
)
|
446 |
),
|
447 |
/** Emails Settings */
|
@@ -561,10 +550,12 @@ function edd_get_registered_settings() {
|
|
561 |
'type' => 'header',
|
562 |
),
|
563 |
'disable_styles' => array(
|
564 |
-
'id'
|
565 |
-
'name'
|
566 |
-
'desc'
|
567 |
-
'type'
|
|
|
|
|
568 |
),
|
569 |
'button_header' => array(
|
570 |
'id' => 'button_header',
|
@@ -598,11 +589,19 @@ function edd_get_registered_settings() {
|
|
598 |
'name' => '<h3>' . __( 'Tax Settings', 'easy-digital-downloads' ) . '</h3>',
|
599 |
'type' => 'header',
|
600 |
),
|
|
|
|
|
|
|
|
|
|
|
|
|
601 |
'enable_taxes' => array(
|
602 |
-
'id'
|
603 |
-
'name'
|
604 |
-
'desc'
|
605 |
-
'type'
|
|
|
|
|
606 |
),
|
607 |
'tax_rates' => array(
|
608 |
'id' => 'tax_rates',
|
@@ -616,6 +615,8 @@ function edd_get_registered_settings() {
|
|
616 |
'desc' => __( 'Enter a percentage, such as 6.5. Customers not in a specific rate will be charged this rate.', 'easy-digital-downloads' ),
|
617 |
'type' => 'text',
|
618 |
'size' => 'small',
|
|
|
|
|
619 |
),
|
620 |
'prices_include_tax' => array(
|
621 |
'id' => 'prices_include_tax',
|
@@ -627,6 +628,8 @@ function edd_get_registered_settings() {
|
|
627 |
'yes' => __( 'Yes, I will enter prices inclusive of tax', 'easy-digital-downloads' ),
|
628 |
'no' => __( 'No, I will enter prices exclusive of tax', 'easy-digital-downloads' ),
|
629 |
),
|
|
|
|
|
630 |
),
|
631 |
'display_tax_rate' => array(
|
632 |
'id' => 'display_tax_rate',
|
@@ -666,16 +669,20 @@ function edd_get_registered_settings() {
|
|
666 |
),
|
667 |
'enable_ajax_cart' => array(
|
668 |
'id' => 'enable_ajax_cart',
|
669 |
-
'name' => __( 'Enable
|
670 |
'desc' => __( 'Check this to enable AJAX for the shopping cart.', 'easy-digital-downloads' ),
|
671 |
'type' => 'checkbox',
|
672 |
'std' => '1',
|
|
|
|
|
673 |
),
|
674 |
'redirect_on_add' => array(
|
675 |
'id' => 'redirect_on_add',
|
676 |
'name' => __( 'Redirect to Checkout', 'easy-digital-downloads' ),
|
677 |
'desc' => __( 'Immediately redirect to checkout after adding an item to the cart?', 'easy-digital-downloads' ),
|
678 |
'type' => 'checkbox',
|
|
|
|
|
679 |
),
|
680 |
'item_quantities' => array(
|
681 |
'id' => 'item_quantities',
|
@@ -707,6 +714,8 @@ function edd_get_registered_settings() {
|
|
707 |
'name' => __( 'Disable Guest Checkout', 'easy-digital-downloads' ),
|
708 |
'desc' => __( 'Require that users be logged-in to purchase files.', 'easy-digital-downloads' ),
|
709 |
'type' => 'checkbox',
|
|
|
|
|
710 |
),
|
711 |
'show_register_form' => array(
|
712 |
'id' => 'show_register_form',
|
@@ -732,6 +741,8 @@ function edd_get_registered_settings() {
|
|
732 |
'name' => __( 'Enable Cart Saving', 'easy-digital-downloads' ),
|
733 |
'desc' => __( 'Check this to enable cart saving on the checkout.', 'easy-digital-downloads' ),
|
734 |
'type' => 'checkbox',
|
|
|
|
|
735 |
),
|
736 |
),
|
737 |
'button_text' => array(
|
@@ -773,6 +784,8 @@ function edd_get_registered_settings() {
|
|
773 |
'name' => __( 'Download Method', 'easy-digital-downloads' ),
|
774 |
'desc' => sprintf( __( 'Select the file download method. Note, not all methods work on all servers.', 'easy-digital-downloads' ), edd_get_label_singular() ),
|
775 |
'type' => 'select',
|
|
|
|
|
776 |
'options' => array(
|
777 |
'direct' => __( 'Forced', 'easy-digital-downloads' ),
|
778 |
'redirect' => __( 'Redirect', 'easy-digital-downloads' ),
|
@@ -790,15 +803,19 @@ function edd_get_registered_settings() {
|
|
790 |
'desc' => sprintf( __( 'The maximum number of times files can be downloaded for purchases. Can be overwritten for each %s.', 'easy-digital-downloads' ), edd_get_label_singular() ),
|
791 |
'type' => 'number',
|
792 |
'size' => 'small',
|
|
|
|
|
793 |
),
|
794 |
'download_link_expiration' => array(
|
795 |
-
'id'
|
796 |
-
'name'
|
797 |
-
'desc'
|
798 |
-
'
|
799 |
-
'
|
800 |
-
'
|
801 |
-
'
|
|
|
|
|
802 |
),
|
803 |
'disable_redownload' => array(
|
804 |
'id' => 'disable_redownload',
|
@@ -888,6 +905,7 @@ function edd_get_registered_settings() {
|
|
888 |
* @since 1.0.8.2
|
889 |
*
|
890 |
* @param array $input The value inputted in the field
|
|
|
891 |
*
|
892 |
* @return string $input Sanitizied value
|
893 |
*/
|
@@ -896,7 +914,8 @@ function edd_settings_sanitize( $input = array() ) {
|
|
896 |
global $edd_options;
|
897 |
|
898 |
if ( empty( $_POST['_wp_http_referer'] ) ) {
|
899 |
-
return
|
|
|
900 |
}
|
901 |
|
902 |
parse_str( $_POST['_wp_http_referer'], $referrer );
|
@@ -907,14 +926,27 @@ function edd_settings_sanitize( $input = array() ) {
|
|
907 |
|
908 |
$input = $input ? $input : array();
|
909 |
|
|
|
|
|
|
|
|
|
910 |
$input = apply_filters( 'edd_settings_' . $tab . '-' . $section . '_sanitize', $input );
|
911 |
-
|
|
|
912 |
// Check for extensions that aren't using new sections
|
913 |
$input = apply_filters( 'edd_settings_' . $tab . '_sanitize', $input );
|
914 |
|
915 |
-
|
916 |
-
|
917 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
918 |
}
|
919 |
}
|
920 |
|
@@ -922,7 +954,7 @@ function edd_settings_sanitize( $input = array() ) {
|
|
922 |
foreach ( $input as $key => $value ) {
|
923 |
|
924 |
// Get the setting type (checkbox, select, etc)
|
925 |
-
$type = isset( $settings[ $tab ][ $key ]['type'] ) ? $settings[ $tab ][ $key ]['type'] : false;
|
926 |
|
927 |
if ( $type ) {
|
928 |
// Field type specific filter
|
@@ -934,10 +966,10 @@ function edd_settings_sanitize( $input = array() ) {
|
|
934 |
}
|
935 |
|
936 |
// Loop through the whitelist and unset any that are empty for the tab being saved
|
937 |
-
$main_settings = $section == 'main' ? $settings[ $tab ] : array(); // Check for extensions that aren't using new sections
|
938 |
$section_settings = ! empty( $settings[ $tab ][ $section ] ) ? $settings[ $tab ][ $section ] : array();
|
939 |
|
940 |
-
$found_settings
|
941 |
|
942 |
if ( ! empty( $found_settings ) ) {
|
943 |
foreach ( $found_settings as $key => $value ) {
|
@@ -971,8 +1003,6 @@ function edd_settings_sanitize( $input = array() ) {
|
|
971 |
*/
|
972 |
function edd_settings_sanitize_misc_file_downloads( $input ) {
|
973 |
|
974 |
-
global $edd_options;
|
975 |
-
|
976 |
if( ! current_user_can( 'manage_shop_settings' ) ) {
|
977 |
return $input;
|
978 |
}
|
@@ -995,8 +1025,6 @@ add_filter( 'edd_settings_misc-file_downloads_sanitize', 'edd_settings_sanitize_
|
|
995 |
*/
|
996 |
function edd_settings_sanitize_misc_accounting( $input ) {
|
997 |
|
998 |
-
global $edd_options;
|
999 |
-
|
1000 |
if( ! current_user_can( 'manage_shop_settings' ) ) {
|
1001 |
return $input;
|
1002 |
}
|
@@ -1028,6 +1056,10 @@ function edd_settings_sanitize_taxes( $input ) {
|
|
1028 |
return $input;
|
1029 |
}
|
1030 |
|
|
|
|
|
|
|
|
|
1031 |
$new_rates = ! empty( $_POST['tax_rates'] ) ? array_values( $_POST['tax_rates'] ) : array();
|
1032 |
|
1033 |
update_option( 'edd_tax_rates', $new_rates );
|
@@ -1044,7 +1076,48 @@ add_filter( 'edd_settings_taxes_sanitize', 'edd_settings_sanitize_taxes' );
|
|
1044 |
* @return string $input Sanitizied value
|
1045 |
*/
|
1046 |
function edd_sanitize_text_field( $input ) {
|
1047 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1048 |
}
|
1049 |
add_filter( 'edd_settings_sanitize_text', 'edd_sanitize_text_field' );
|
1050 |
|
@@ -1189,7 +1262,7 @@ function edd_get_pages( $force = false ) {
|
|
1189 |
* @return void
|
1190 |
*/
|
1191 |
function edd_header_callback( $args ) {
|
1192 |
-
echo '';
|
1193 |
}
|
1194 |
|
1195 |
/**
|
@@ -1199,11 +1272,11 @@ function edd_header_callback( $args ) {
|
|
1199 |
*
|
1200 |
* @since 1.0
|
1201 |
* @param array $args Arguments passed by the setting
|
1202 |
-
*
|
1203 |
* @return void
|
1204 |
*/
|
1205 |
function edd_checkbox_callback( $args ) {
|
1206 |
-
|
1207 |
|
1208 |
if ( isset( $args['faux'] ) && true === $args['faux'] ) {
|
1209 |
$name = '';
|
@@ -1211,11 +1284,11 @@ function edd_checkbox_callback( $args ) {
|
|
1211 |
$name = 'name="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"';
|
1212 |
}
|
1213 |
|
1214 |
-
$checked
|
1215 |
-
$html
|
1216 |
-
$html
|
1217 |
|
1218 |
-
echo $html;
|
1219 |
}
|
1220 |
|
1221 |
/**
|
@@ -1225,20 +1298,23 @@ function edd_checkbox_callback( $args ) {
|
|
1225 |
*
|
1226 |
* @since 1.0
|
1227 |
* @param array $args Arguments passed by the setting
|
1228 |
-
*
|
1229 |
* @return void
|
1230 |
*/
|
1231 |
function edd_multicheck_callback( $args ) {
|
1232 |
-
|
1233 |
|
|
|
1234 |
if ( ! empty( $args['options'] ) ) {
|
1235 |
foreach( $args['options'] as $key => $option ):
|
1236 |
-
if( isset( $
|
1237 |
-
|
1238 |
-
|
1239 |
endforeach;
|
1240 |
-
|
1241 |
}
|
|
|
|
|
1242 |
}
|
1243 |
|
1244 |
/**
|
@@ -1246,24 +1322,25 @@ function edd_multicheck_callback( $args ) {
|
|
1246 |
*
|
1247 |
* @since 2.1
|
1248 |
* @param array $args Arguments passed by the setting
|
1249 |
-
*
|
1250 |
* @return void
|
1251 |
*/
|
1252 |
function edd_payment_icons_callback( $args ) {
|
1253 |
-
|
1254 |
|
|
|
1255 |
if ( ! empty( $args['options'] ) ) {
|
1256 |
foreach( $args['options'] as $key => $option ) {
|
1257 |
|
1258 |
-
if( isset( $
|
1259 |
$enabled = $option;
|
1260 |
} else {
|
1261 |
$enabled = NULL;
|
1262 |
}
|
1263 |
|
1264 |
-
|
1265 |
|
1266 |
-
|
1267 |
|
1268 |
if( edd_string_is_image_url( $key ) ) {
|
1269 |
|
@@ -1294,15 +1371,17 @@ function edd_payment_icons_callback( $args ) {
|
|
1294 |
|
1295 |
}
|
1296 |
|
1297 |
-
|
1298 |
}
|
1299 |
|
1300 |
|
1301 |
-
|
1302 |
|
1303 |
}
|
1304 |
-
|
1305 |
}
|
|
|
|
|
1306 |
}
|
1307 |
|
1308 |
/**
|
@@ -1312,25 +1391,29 @@ function edd_payment_icons_callback( $args ) {
|
|
1312 |
*
|
1313 |
* @since 1.3.3
|
1314 |
* @param array $args Arguments passed by the setting
|
1315 |
-
*
|
1316 |
* @return void
|
1317 |
*/
|
1318 |
function edd_radio_callback( $args ) {
|
1319 |
-
|
|
|
|
|
1320 |
|
1321 |
foreach ( $args['options'] as $key => $option ) :
|
1322 |
$checked = false;
|
1323 |
|
1324 |
-
if (
|
1325 |
$checked = true;
|
1326 |
-
elseif( isset( $args['std'] ) && $args['std'] == $key && !
|
1327 |
$checked = true;
|
1328 |
|
1329 |
-
|
1330 |
-
|
1331 |
endforeach;
|
1332 |
|
1333 |
-
|
|
|
|
|
1334 |
}
|
1335 |
|
1336 |
/**
|
@@ -1340,21 +1423,25 @@ function edd_radio_callback( $args ) {
|
|
1340 |
*
|
1341 |
* @since 1.0
|
1342 |
* @param array $args Arguments passed by the setting
|
1343 |
-
*
|
1344 |
* @return void
|
1345 |
*/
|
1346 |
function edd_gateways_callback( $args ) {
|
1347 |
-
|
|
|
|
|
1348 |
|
1349 |
foreach ( $args['options'] as $key => $option ) :
|
1350 |
-
if ( isset( $
|
1351 |
$enabled = '1';
|
1352 |
else
|
1353 |
$enabled = null;
|
1354 |
|
1355 |
-
|
1356 |
-
|
1357 |
endforeach;
|
|
|
|
|
1358 |
}
|
1359 |
|
1360 |
/**
|
@@ -1364,21 +1451,25 @@ function edd_gateways_callback( $args ) {
|
|
1364 |
*
|
1365 |
* @since 1.5
|
1366 |
* @param array $args Arguments passed by the setting
|
1367 |
-
*
|
1368 |
* @return void
|
1369 |
*/
|
1370 |
-
function edd_gateway_select_callback($args) {
|
1371 |
-
|
|
|
|
|
1372 |
|
1373 |
-
|
1374 |
|
1375 |
foreach ( $args['options'] as $key => $option ) :
|
1376 |
-
$selected = isset( $
|
1377 |
-
|
1378 |
endforeach;
|
1379 |
|
1380 |
-
|
1381 |
-
|
|
|
|
|
1382 |
}
|
1383 |
|
1384 |
/**
|
@@ -1388,14 +1479,14 @@ function edd_gateway_select_callback($args) {
|
|
1388 |
*
|
1389 |
* @since 1.0
|
1390 |
* @param array $args Arguments passed by the setting
|
1391 |
-
*
|
1392 |
* @return void
|
1393 |
*/
|
1394 |
function edd_text_callback( $args ) {
|
1395 |
-
|
1396 |
|
1397 |
-
if (
|
1398 |
-
$value = $
|
1399 |
} else {
|
1400 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
1401 |
}
|
@@ -1413,7 +1504,7 @@ function edd_text_callback( $args ) {
|
|
1413 |
$html = '<input type="text" class="' . sanitize_html_class( $size ) . '-text" id="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']" ' . $name . ' value="' . esc_attr( stripslashes( $value ) ) . '"' . $readonly . '/>';
|
1414 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1415 |
|
1416 |
-
echo $html;
|
1417 |
}
|
1418 |
|
1419 |
/**
|
@@ -1423,14 +1514,14 @@ function edd_text_callback( $args ) {
|
|
1423 |
*
|
1424 |
* @since 1.9
|
1425 |
* @param array $args Arguments passed by the setting
|
1426 |
-
*
|
1427 |
* @return void
|
1428 |
*/
|
1429 |
function edd_number_callback( $args ) {
|
1430 |
-
|
1431 |
|
1432 |
-
if (
|
1433 |
-
$value = $
|
1434 |
} else {
|
1435 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
1436 |
}
|
@@ -1451,7 +1542,7 @@ function edd_number_callback( $args ) {
|
|
1451 |
$html = '<input type="number" step="' . esc_attr( $step ) . '" max="' . esc_attr( $max ) . '" min="' . esc_attr( $min ) . '" class="' . sanitize_html_class( $size ) . '-text" id="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']" ' . $name . ' value="' . esc_attr( stripslashes( $value ) ) . '"/>';
|
1452 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1453 |
|
1454 |
-
echo $html;
|
1455 |
}
|
1456 |
|
1457 |
/**
|
@@ -1461,14 +1552,14 @@ function edd_number_callback( $args ) {
|
|
1461 |
*
|
1462 |
* @since 1.0
|
1463 |
* @param array $args Arguments passed by the setting
|
1464 |
-
*
|
1465 |
* @return void
|
1466 |
*/
|
1467 |
function edd_textarea_callback( $args ) {
|
1468 |
-
|
1469 |
|
1470 |
-
if (
|
1471 |
-
$value = $
|
1472 |
} else {
|
1473 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
1474 |
}
|
@@ -1476,7 +1567,7 @@ function edd_textarea_callback( $args ) {
|
|
1476 |
$html = '<textarea class="large-text" cols="50" rows="5" id="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']" name="edd_settings[' . esc_attr( $args['id'] ) . ']">' . esc_textarea( stripslashes( $value ) ) . '</textarea>';
|
1477 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1478 |
|
1479 |
-
echo $html;
|
1480 |
}
|
1481 |
|
1482 |
/**
|
@@ -1486,14 +1577,14 @@ function edd_textarea_callback( $args ) {
|
|
1486 |
*
|
1487 |
* @since 1.3
|
1488 |
* @param array $args Arguments passed by the setting
|
1489 |
-
*
|
1490 |
* @return void
|
1491 |
*/
|
1492 |
function edd_password_callback( $args ) {
|
1493 |
-
|
1494 |
|
1495 |
-
if (
|
1496 |
-
$value = $edd_options
|
1497 |
} else {
|
1498 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
1499 |
}
|
@@ -1502,7 +1593,7 @@ function edd_password_callback( $args ) {
|
|
1502 |
$html = '<input type="password" class="' . sanitize_html_class( $size ) . '-text" id="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']" name="edd_settings[' . esc_attr( $args['id'] ) . ']" value="' . esc_attr( $value ) . '"/>';
|
1503 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1504 |
|
1505 |
-
echo $html;
|
1506 |
}
|
1507 |
|
1508 |
/**
|
@@ -1528,14 +1619,14 @@ function edd_missing_callback($args) {
|
|
1528 |
*
|
1529 |
* @since 1.0
|
1530 |
* @param array $args Arguments passed by the setting
|
1531 |
-
*
|
1532 |
* @return void
|
1533 |
*/
|
1534 |
function edd_select_callback($args) {
|
1535 |
-
|
1536 |
|
1537 |
-
if (
|
1538 |
-
$value = $
|
1539 |
} else {
|
1540 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
1541 |
}
|
@@ -1562,7 +1653,7 @@ function edd_select_callback($args) {
|
|
1562 |
$html .= '</select>';
|
1563 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1564 |
|
1565 |
-
echo $html;
|
1566 |
}
|
1567 |
|
1568 |
/**
|
@@ -1572,14 +1663,14 @@ function edd_select_callback($args) {
|
|
1572 |
*
|
1573 |
* @since 1.8
|
1574 |
* @param array $args Arguments passed by the setting
|
1575 |
-
*
|
1576 |
* @return void
|
1577 |
*/
|
1578 |
function edd_color_select_callback( $args ) {
|
1579 |
-
|
1580 |
|
1581 |
-
if (
|
1582 |
-
$value = $
|
1583 |
} else {
|
1584 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
1585 |
}
|
@@ -1594,7 +1685,7 @@ function edd_color_select_callback( $args ) {
|
|
1594 |
$html .= '</select>';
|
1595 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1596 |
|
1597 |
-
echo $html;
|
1598 |
}
|
1599 |
|
1600 |
/**
|
@@ -1604,14 +1695,12 @@ function edd_color_select_callback( $args ) {
|
|
1604 |
*
|
1605 |
* @since 1.0
|
1606 |
* @param array $args Arguments passed by the setting
|
1607 |
-
* @global $edd_options Array of all the EDD Options
|
1608 |
-
* @global $wp_version WordPress Version
|
1609 |
*/
|
1610 |
function edd_rich_editor_callback( $args ) {
|
1611 |
-
|
1612 |
|
1613 |
-
if (
|
1614 |
-
$value = $
|
1615 |
|
1616 |
if( empty( $args['allow_blank'] ) && empty( $value ) ) {
|
1617 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
@@ -1622,17 +1711,14 @@ function edd_rich_editor_callback( $args ) {
|
|
1622 |
|
1623 |
$rows = isset( $args['size'] ) ? $args['size'] : 20;
|
1624 |
|
1625 |
-
|
1626 |
-
|
1627 |
-
|
1628 |
-
|
1629 |
-
} else {
|
1630 |
-
$html = '<textarea class="large-text" rows="10" id="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']" name="edd_settings[' . esc_attr( $args['id'] ) . ']">' . esc_textarea( stripslashes( $value ) ) . '</textarea>';
|
1631 |
-
}
|
1632 |
|
1633 |
$html .= '<br/><label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1634 |
|
1635 |
-
echo $html;
|
1636 |
}
|
1637 |
|
1638 |
/**
|
@@ -1642,14 +1728,14 @@ function edd_rich_editor_callback( $args ) {
|
|
1642 |
*
|
1643 |
* @since 1.0
|
1644 |
* @param array $args Arguments passed by the setting
|
1645 |
-
*
|
1646 |
* @return void
|
1647 |
*/
|
1648 |
function edd_upload_callback( $args ) {
|
1649 |
-
|
1650 |
|
1651 |
-
if (
|
1652 |
-
$value = $
|
1653 |
} else {
|
1654 |
$value = isset($args['std']) ? $args['std'] : '';
|
1655 |
}
|
@@ -1659,7 +1745,7 @@ function edd_upload_callback( $args ) {
|
|
1659 |
$html .= '<span> <input type="button" class="edd_settings_upload_button button-secondary" value="' . __( 'Upload File', 'easy-digital-downloads' ) . '"/></span>';
|
1660 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1661 |
|
1662 |
-
echo $html;
|
1663 |
}
|
1664 |
|
1665 |
|
@@ -1670,14 +1756,14 @@ function edd_upload_callback( $args ) {
|
|
1670 |
*
|
1671 |
* @since 1.6
|
1672 |
* @param array $args Arguments passed by the setting
|
1673 |
-
*
|
1674 |
* @return void
|
1675 |
*/
|
1676 |
function edd_color_callback( $args ) {
|
1677 |
-
|
1678 |
|
1679 |
-
if (
|
1680 |
-
$value = $
|
1681 |
} else {
|
1682 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
1683 |
}
|
@@ -1687,7 +1773,7 @@ function edd_color_callback( $args ) {
|
|
1687 |
$html = '<input type="text" class="edd-color-picker" id="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']" name="edd_settings[' . esc_attr( $args['id'] ) . ']" value="' . esc_attr( $value ) . '" data-default-color="' . esc_attr( $default ) . '" />';
|
1688 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1689 |
|
1690 |
-
echo $html;
|
1691 |
}
|
1692 |
|
1693 |
/**
|
@@ -1697,11 +1783,11 @@ function edd_color_callback( $args ) {
|
|
1697 |
*
|
1698 |
* @since 1.6
|
1699 |
* @param array $args Arguments passed by the setting
|
1700 |
-
*
|
1701 |
* @return void
|
1702 |
*/
|
1703 |
function edd_shop_states_callback($args) {
|
1704 |
-
|
1705 |
|
1706 |
if ( isset( $args['placeholder'] ) ) {
|
1707 |
$placeholder = $args['placeholder'];
|
@@ -1716,14 +1802,14 @@ function edd_shop_states_callback($args) {
|
|
1716 |
$html = '<select id="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']" name="edd_settings[' . esc_attr( $args['id'] ) . ']"' . $class . 'data-placeholder="' . esc_html( $placeholder ) . '"/>';
|
1717 |
|
1718 |
foreach ( $states as $option => $name ) {
|
1719 |
-
$selected = isset( $
|
1720 |
$html .= '<option value="' . esc_attr( $option ) . '" ' . $selected . '>' . esc_html( $name ) . '</option>';
|
1721 |
}
|
1722 |
|
1723 |
$html .= '</select>';
|
1724 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1725 |
|
1726 |
-
echo $html;
|
1727 |
}
|
1728 |
|
1729 |
/**
|
@@ -1733,11 +1819,9 @@ function edd_shop_states_callback($args) {
|
|
1733 |
*
|
1734 |
* @since 1.6
|
1735 |
* @param array $args Arguments passed by the setting
|
1736 |
-
* @global $edd_options Array of all the EDD Options
|
1737 |
* @return void
|
1738 |
*/
|
1739 |
function edd_tax_rates_callback($args) {
|
1740 |
-
global $edd_options;
|
1741 |
$rates = edd_get_tax_rates();
|
1742 |
ob_start(); ?>
|
1743 |
<p><?php echo $args['desc']; ?></p>
|
@@ -1746,7 +1830,7 @@ function edd_tax_rates_callback($args) {
|
|
1746 |
<tr>
|
1747 |
<th scope="col" class="edd_tax_country"><?php _e( 'Country', 'easy-digital-downloads' ); ?></th>
|
1748 |
<th scope="col" class="edd_tax_state"><?php _e( 'State / Province', 'easy-digital-downloads' ); ?></th>
|
1749 |
-
<th scope="col" class="edd_tax_global"
|
1750 |
<th scope="col" class="edd_tax_rate"><?php _e( 'Rate', 'easy-digital-downloads' ); ?></th>
|
1751 |
<th scope="col"><?php _e( 'Remove', 'easy-digital-downloads' ); ?></th>
|
1752 |
</tr>
|
@@ -1842,7 +1926,9 @@ function edd_tax_rates_callback($args) {
|
|
1842 |
* @return void
|
1843 |
*/
|
1844 |
function edd_descriptive_text_callback( $args ) {
|
1845 |
-
|
|
|
|
|
1846 |
}
|
1847 |
|
1848 |
/**
|
@@ -1850,18 +1936,18 @@ function edd_descriptive_text_callback( $args ) {
|
|
1850 |
*
|
1851 |
* @since 1.5
|
1852 |
* @param array $args Arguments passed by the setting
|
1853 |
-
*
|
1854 |
* @return void
|
1855 |
*/
|
1856 |
if ( ! function_exists( 'edd_license_key_callback' ) ) {
|
1857 |
function edd_license_key_callback( $args ) {
|
1858 |
-
|
1859 |
|
1860 |
$messages = array();
|
1861 |
$license = get_option( $args['options']['is_valid_license_option'] );
|
1862 |
|
1863 |
-
if (
|
1864 |
-
$value = $
|
1865 |
} else {
|
1866 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
1867 |
}
|
@@ -1875,9 +1961,9 @@ if ( ! function_exists( 'edd_license_key_callback' ) ) {
|
|
1875 |
|
1876 |
case 'expired' :
|
1877 |
|
1878 |
-
$class = '
|
1879 |
$messages[] = sprintf(
|
1880 |
-
__( 'Your license key expired on %s. Please <a href="%s" target="_blank"
|
1881 |
date_i18n( get_option( 'date_format' ), strtotime( $license->expires, current_time( 'timestamp' ) ) ),
|
1882 |
'https://easydigitaldownloads.com/checkout/?edd_license_key=' . $value . '&utm_campaign=admin&utm_source=licenses&utm_medium=expired'
|
1883 |
);
|
@@ -1886,11 +1972,23 @@ if ( ! function_exists( 'edd_license_key_callback' ) ) {
|
|
1886 |
|
1887 |
break;
|
1888 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1889 |
case 'missing' :
|
1890 |
|
1891 |
$class = 'error';
|
1892 |
$messages[] = sprintf(
|
1893 |
-
__( 'Invalid license. Please <a href="%s" target="_blank"
|
1894 |
'https://easydigitaldownloads.com/your-account?utm_campaign=admin&utm_source=licenses&utm_medium=missing'
|
1895 |
);
|
1896 |
|
@@ -1903,7 +2001,7 @@ if ( ! function_exists( 'edd_license_key_callback' ) ) {
|
|
1903 |
|
1904 |
$class = 'error';
|
1905 |
$messages[] = sprintf(
|
1906 |
-
__( 'Your %s is not active for this URL. Please <a href="%s" target="_blank"
|
1907 |
$args['name'],
|
1908 |
'https://easydigitaldownloads.com/your-account?utm_campaign=admin&utm_source=licenses&utm_medium=invalid'
|
1909 |
);
|
@@ -1915,7 +2013,7 @@ if ( ! function_exists( 'edd_license_key_callback' ) ) {
|
|
1915 |
case 'item_name_mismatch' :
|
1916 |
|
1917 |
$class = 'error';
|
1918 |
-
$messages[] = sprintf( __( 'This
|
1919 |
|
1920 |
$license_status = 'license-' . $class . '-notice';
|
1921 |
|
@@ -1930,6 +2028,10 @@ if ( ! function_exists( 'edd_license_key_callback' ) ) {
|
|
1930 |
|
1931 |
break;
|
1932 |
|
|
|
|
|
|
|
|
|
1933 |
}
|
1934 |
|
1935 |
} else {
|
@@ -1953,7 +2055,7 @@ if ( ! function_exists( 'edd_license_key_callback' ) ) {
|
|
1953 |
} elseif( $expiration > $now && $expiration - $now < ( DAY_IN_SECONDS * 30 ) ) {
|
1954 |
|
1955 |
$messages[] = sprintf(
|
1956 |
-
__( 'Your license key expires soon! It expires on %s. <a href="%s" target="_blank"
|
1957 |
date_i18n( get_option( 'date_format' ), strtotime( $license->expires, current_time( 'timestamp' ) ) ),
|
1958 |
'https://easydigitaldownloads.com/checkout/?edd_license_key=' . $value . '&utm_campaign=admin&utm_source=licenses&utm_medium=renew'
|
1959 |
);
|
@@ -1978,6 +2080,13 @@ if ( ! function_exists( 'edd_license_key_callback' ) ) {
|
|
1978 |
}
|
1979 |
|
1980 |
} else {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1981 |
$license_status = null;
|
1982 |
}
|
1983 |
|
@@ -1993,7 +2102,7 @@ if ( ! function_exists( 'edd_license_key_callback' ) ) {
|
|
1993 |
if ( ! empty( $messages ) ) {
|
1994 |
foreach( $messages as $message ) {
|
1995 |
|
1996 |
-
$html .= '<div class="edd-license-data edd-license-' . $class . '">';
|
1997 |
$html .= '<p>' . $message . '</p>';
|
1998 |
$html .= '</div>';
|
1999 |
|
@@ -2002,11 +2111,7 @@ if ( ! function_exists( 'edd_license_key_callback' ) ) {
|
|
2002 |
|
2003 |
wp_nonce_field( edd_sanitize_key( $args['id'] ) . '-nonce', edd_sanitize_key( $args['id'] ) . '-nonce' );
|
2004 |
|
2005 |
-
|
2006 |
-
echo '<div class="' . $license_status . '">' . $html . '</div>';
|
2007 |
-
} else {
|
2008 |
-
echo '<div class="license-null">' . $html . '</div>';
|
2009 |
-
}
|
2010 |
}
|
2011 |
}
|
2012 |
|
@@ -2033,3 +2138,14 @@ function edd_set_settings_cap() {
|
|
2033 |
return 'manage_shop_settings';
|
2034 |
}
|
2035 |
add_filter( 'option_page_capability_edd_settings', 'edd_set_settings_cap' );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
19 |
* Looks to see if the specified setting exists, returns default if not
|
20 |
*
|
21 |
* @since 1.8.4
|
22 |
+
* @global $edd_options Array of all the EDD Options
|
23 |
* @return mixed
|
24 |
*/
|
25 |
function edd_get_option( $key = '', $default = false ) {
|
39 |
* @since 2.3
|
40 |
* @param string $key The Key to update
|
41 |
* @param string|bool|int $value The value to set the key to
|
42 |
+
* @global $edd_options Array of all the EDD Options
|
43 |
* @return boolean True if updated, false if not.
|
44 |
*/
|
45 |
function edd_update_option( $key = '', $value = false ) {
|
81 |
*
|
82 |
* @since 2.3
|
83 |
* @param string $key The Key to delete
|
84 |
+
* @global $edd_options Array of all the EDD Options
|
85 |
* @return boolean True if updated, false if not.
|
86 |
*/
|
87 |
function edd_delete_option( $key = '' ) {
|
189 |
'edd_settings_' . $tab . '_' . $section,
|
190 |
'edd_settings_' . $tab . '_' . $section,
|
191 |
array(
|
192 |
+
'section' => $section,
|
193 |
+
'id' => isset( $option['id'] ) ? $option['id'] : null,
|
194 |
+
'desc' => ! empty( $option['desc'] ) ? $option['desc'] : '',
|
195 |
+
'name' => isset( $option['name'] ) ? $option['name'] : null,
|
196 |
+
'size' => isset( $option['size'] ) ? $option['size'] : null,
|
197 |
+
'options' => isset( $option['options'] ) ? $option['options'] : '',
|
198 |
+
'std' => isset( $option['std'] ) ? $option['std'] : '',
|
199 |
+
'min' => isset( $option['min'] ) ? $option['min'] : null,
|
200 |
+
'max' => isset( $option['max'] ) ? $option['max'] : null,
|
201 |
+
'step' => isset( $option['step'] ) ? $option['step'] : null,
|
202 |
+
'chosen' => isset( $option['chosen'] ) ? $option['chosen'] : null,
|
203 |
+
'placeholder' => isset( $option['placeholder'] ) ? $option['placeholder'] : null,
|
204 |
+
'allow_blank' => isset( $option['allow_blank'] ) ? $option['allow_blank'] : true,
|
205 |
+
'readonly' => isset( $option['readonly'] ) ? $option['readonly'] : false,
|
206 |
+
'faux' => isset( $option['faux'] ) ? $option['faux'] : false,
|
207 |
+
'tooltip_title' => isset( $option['tooltip_title'] ) ? $option['tooltip_title'] : false,
|
208 |
+
'tooltip_desc' => isset( $option['tooltip_desc'] ) ? $option['tooltip_desc'] : false,
|
209 |
)
|
210 |
);
|
211 |
}
|
241 |
'name' => '<h3>' . __( 'Page Settings', 'easy-digital-downloads' ) . '</h3>',
|
242 |
'desc' => '',
|
243 |
'type' => 'header',
|
244 |
+
'tooltip_title' => __( 'Page Settings', 'easy-digital-downloads' ),
|
245 |
+
'tooltip_desc' => __( 'Easy Digital Downloads uses the pages below for handling the display of checkout, purchase confirmation, purchase history, and purchase failures. If pages are deleted or removed in some way, they can be recreated manually from the Pages menu. When re-creating the pages, enter the shortcode shown in the page content area.','easy-digital-downloads' ),
|
246 |
),
|
247 |
'purchase_page' => array(
|
248 |
'id' => 'purchase_page',
|
265 |
'failure_page' => array(
|
266 |
'id' => 'failure_page',
|
267 |
'name' => __( 'Failed Transaction Page', 'easy-digital-downloads' ),
|
268 |
+
'desc' => __( 'This is the page buyers are sent to if their transaction is cancelled or fails.', 'easy-digital-downloads' ),
|
269 |
'type' => 'select',
|
270 |
'options' => edd_get_pages(),
|
271 |
'chosen' => true,
|
274 |
'purchase_history_page' => array(
|
275 |
'id' => 'purchase_history_page',
|
276 |
'name' => __( 'Purchase History Page', 'easy-digital-downloads' ),
|
277 |
+
'desc' => __( 'This page shows a complete purchase history for the current user, including download links. The [purchase_history] short code should be on this page.', 'easy-digital-downloads' ),
|
278 |
'type' => 'select',
|
279 |
'options' => edd_get_pages(),
|
280 |
'chosen' => true,
|
281 |
'placeholder' => __( 'Select a page', 'easy-digital-downloads' ),
|
282 |
),
|
283 |
'locale_settings' => array(
|
284 |
+
'id' => 'locale_settings',
|
285 |
+
'name' => '<h3>' . __( 'Store Location', 'easy-digital-downloads' ) . '</h3>',
|
286 |
+
'desc' => '',
|
287 |
+
'type' => 'header',
|
288 |
+
'tooltip_title' => __( 'Store Location Settings', 'easy-digital-downloads' ),
|
289 |
+
'tooltip_desc' => __( 'Easy Digital Downloads will use the following Country and State to pre-fill fields at checkout. This will also pre-calculate any taxes defined if the location below has taxes enabled.','easy-digital-downloads' ),
|
290 |
),
|
291 |
'base_country' => array(
|
292 |
'id' => 'base_country',
|
369 |
'name' => '<h3>' . __( 'API Settings', 'easy-digital-downloads' ) . '</h3>',
|
370 |
'desc' => '',
|
371 |
'type' => 'header',
|
372 |
+
'tooltip_title' => __( 'API Settings', 'easy-digital-downloads' ),
|
373 |
+
'tooltip_desc' => __( 'The Easy Digital Downloads REST API provides access to store data through our API endpoints. Enable this setting if you would like all user accounts to be able to generate their own API keys.', 'easy-digital-downloads' ),
|
374 |
),
|
375 |
'api_allow_user_keys' => array(
|
376 |
'id' => 'api_allow_user_keys',
|
378 |
'desc' => __( 'Check this box to allow all users to generate API keys. Users with the \'manage_shop_settings\' capability are always allowed to generate keys.', 'easy-digital-downloads' ),
|
379 |
'type' => 'checkbox',
|
380 |
),
|
381 |
+
'api_help' => array(
|
382 |
+
'id' => 'api_help',
|
383 |
+
'desc' => sprintf( __( 'Visit the <a href="%s" target="_blank">REST API documentation</a> for further information.', 'easy-digital-downloads' ), 'http://docs.easydigitaldownloads.com/article/1131-edd-rest-api-introduction' ),
|
384 |
+
'type' => 'descriptive_text',
|
385 |
+
),
|
386 |
),
|
387 |
)
|
388 |
),
|
431 |
),
|
432 |
),
|
433 |
),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
434 |
)
|
435 |
),
|
436 |
/** Emails Settings */
|
550 |
'type' => 'header',
|
551 |
),
|
552 |
'disable_styles' => array(
|
553 |
+
'id' => 'disable_styles',
|
554 |
+
'name' => __( 'Disable Styles', 'easy-digital-downloads' ),
|
555 |
+
'desc' => __( 'Check this to disable all included styling of buttons, checkout fields, and all other elements.', 'easy-digital-downloads' ),
|
556 |
+
'type' => 'checkbox',
|
557 |
+
'tooltip_title' => __( 'Disabling Styles', 'easy-digital-downloads' ),
|
558 |
+
'tooltip_desc' => __( 'If your theme has a complete custom CSS file for Easy Digital Downloads, you may wish to disable our default styles. This is not recommended unless your sure your theme has a complete custom CSS.', 'easy-digital-downloads' ),
|
559 |
),
|
560 |
'button_header' => array(
|
561 |
'id' => 'button_header',
|
589 |
'name' => '<h3>' . __( 'Tax Settings', 'easy-digital-downloads' ) . '</h3>',
|
590 |
'type' => 'header',
|
591 |
),
|
592 |
+
'tax_help' => array(
|
593 |
+
'id' => 'tax_help',
|
594 |
+
'name' => __( 'Need help?', 'easy-digital-downloads' ),
|
595 |
+
'desc' => sprintf( __( 'Visit the <a href="%s" target="_blank">Tax setup documentation</a> for further information. If you need VAT support, there are options listed on the documentation page.', 'easy-digital-downloads' ), 'http://docs.easydigitaldownloads.com/article/238-tax-settings' ),
|
596 |
+
'type' => 'descriptive_text',
|
597 |
+
),
|
598 |
'enable_taxes' => array(
|
599 |
+
'id' => 'enable_taxes',
|
600 |
+
'name' => __( 'Enable Taxes', 'easy-digital-downloads' ),
|
601 |
+
'desc' => __( 'Check this to enable taxes on purchases.', 'easy-digital-downloads' ),
|
602 |
+
'type' => 'checkbox',
|
603 |
+
'tooltip_title' => __( 'Enabling Taxes', 'easy-digital-downloads' ),
|
604 |
+
'tooltip_desc' => __( 'With taxes enabled, Easy Digital Downloads will use the rules below to charge tax to customers. With taxes enabled, customers are required to input their address on checkout so that taxes can be properly calculated.', 'easy-digital-downloads' ),
|
605 |
),
|
606 |
'tax_rates' => array(
|
607 |
'id' => 'tax_rates',
|
615 |
'desc' => __( 'Enter a percentage, such as 6.5. Customers not in a specific rate will be charged this rate.', 'easy-digital-downloads' ),
|
616 |
'type' => 'text',
|
617 |
'size' => 'small',
|
618 |
+
'tooltip_title' => __( 'Fallback Tax Rate', 'easy-digital-downloads' ),
|
619 |
+
'tooltip_desc' => __( 'If the customer\'s address fails to meet the above tax rules, you can define a `default` tax rate to be applied to all other customers.', 'easy-digital-downloads' ),
|
620 |
),
|
621 |
'prices_include_tax' => array(
|
622 |
'id' => 'prices_include_tax',
|
628 |
'yes' => __( 'Yes, I will enter prices inclusive of tax', 'easy-digital-downloads' ),
|
629 |
'no' => __( 'No, I will enter prices exclusive of tax', 'easy-digital-downloads' ),
|
630 |
),
|
631 |
+
'tooltip_title' => __( 'Prices Inclusive of Tax', 'easy-digital-downloads' ),
|
632 |
+
'tooltip_desc' => __( 'When using prices inclusive of tax, you will be entering your prices as the total amount you want a customer to pay for the download, including tax. Easy Digital Downloads will calculate the proper amount to tax the customer for the defined total price.', 'easy-digital-downloads' ),
|
633 |
),
|
634 |
'display_tax_rate' => array(
|
635 |
'id' => 'display_tax_rate',
|
669 |
),
|
670 |
'enable_ajax_cart' => array(
|
671 |
'id' => 'enable_ajax_cart',
|
672 |
+
'name' => __( 'Enable AJAX', 'easy-digital-downloads' ),
|
673 |
'desc' => __( 'Check this to enable AJAX for the shopping cart.', 'easy-digital-downloads' ),
|
674 |
'type' => 'checkbox',
|
675 |
'std' => '1',
|
676 |
+
'tooltip_title' => __( 'Enabling AJAX', 'easy-digital-downloads' ),
|
677 |
+
'tooltip_desc' => __( 'With AJAX enabled, customers can perform cart actions like adding and removing items from their shopping cart without pages having to be reloaded. This also creates fewer steps during the checkout process.', 'easy-digital-downloads' ),
|
678 |
),
|
679 |
'redirect_on_add' => array(
|
680 |
'id' => 'redirect_on_add',
|
681 |
'name' => __( 'Redirect to Checkout', 'easy-digital-downloads' ),
|
682 |
'desc' => __( 'Immediately redirect to checkout after adding an item to the cart?', 'easy-digital-downloads' ),
|
683 |
'type' => 'checkbox',
|
684 |
+
'tooltip_title' => __( 'Redirect to Checkout', 'easy-digital-downloads' ),
|
685 |
+
'tooltip_desc' => __( 'When enabled, once an item has been added to the cart, the customer will be redirected directly to your checkout page. This is useful for stores that sell single items.', 'easy-digital-downloads' ),
|
686 |
),
|
687 |
'item_quantities' => array(
|
688 |
'id' => 'item_quantities',
|
714 |
'name' => __( 'Disable Guest Checkout', 'easy-digital-downloads' ),
|
715 |
'desc' => __( 'Require that users be logged-in to purchase files.', 'easy-digital-downloads' ),
|
716 |
'type' => 'checkbox',
|
717 |
+
'tooltip_title' => __( 'Disabling Guest Checkout', 'easy-digital-downloads' ),
|
718 |
+
'tooltip_desc' => __( 'You can require that customers create and login to user accounts prior to purchasing from your store by enabling this option. When unchecked, users can purchase without being logged in by using their name and email address.', 'easy-digital-downloads' ),
|
719 |
),
|
720 |
'show_register_form' => array(
|
721 |
'id' => 'show_register_form',
|
741 |
'name' => __( 'Enable Cart Saving', 'easy-digital-downloads' ),
|
742 |
'desc' => __( 'Check this to enable cart saving on the checkout.', 'easy-digital-downloads' ),
|
743 |
'type' => 'checkbox',
|
744 |
+
'tooltip_title' => __( 'Cart Saving', 'easy-digital-downloads' ),
|
745 |
+
'tooltip_desc' => __( 'Cart saving allows shoppers to create a temporary link to their current shopping cart so they can come back to it later, or share it with someone.', 'easy-digital-downloads' ),
|
746 |
),
|
747 |
),
|
748 |
'button_text' => array(
|
784 |
'name' => __( 'Download Method', 'easy-digital-downloads' ),
|
785 |
'desc' => sprintf( __( 'Select the file download method. Note, not all methods work on all servers.', 'easy-digital-downloads' ), edd_get_label_singular() ),
|
786 |
'type' => 'select',
|
787 |
+
'tooltip_title' => __( 'Download Method', 'easy-digital-downloads' ),
|
788 |
+
'tooltip_desc' => __( 'Due to its consistency in multiple platforms and better file protection, \'forced\' is the default method. Because Easy Digital Downloads uses PHP to process the file with the \'forced\' method, larger files can cause problems with delivery, resulting in hitting the \'max execution time\' of the server. If users are getting 404 or 403 errors when trying to access their purchased files when using the \'forced\' method, changing to the \'redirect\' method can help resolve this.', 'easy-digital-downloads' ),
|
789 |
'options' => array(
|
790 |
'direct' => __( 'Forced', 'easy-digital-downloads' ),
|
791 |
'redirect' => __( 'Redirect', 'easy-digital-downloads' ),
|
803 |
'desc' => sprintf( __( 'The maximum number of times files can be downloaded for purchases. Can be overwritten for each %s.', 'easy-digital-downloads' ), edd_get_label_singular() ),
|
804 |
'type' => 'number',
|
805 |
'size' => 'small',
|
806 |
+
'tooltip_title' => __( 'File Download Limits', 'easy-digital-downloads' ),
|
807 |
+
'tooltip_desc' => sprintf( __( 'Set the global default for the number of times a customer can download items they purchase. Using a value of 0 is unlimited. This can be defined on a %s-specific level as well. Download limits can also be reset for an individual purchase.', 'easy-digital-downloads' ), edd_get_label_singular( true ) ),
|
808 |
),
|
809 |
'download_link_expiration' => array(
|
810 |
+
'id' => 'download_link_expiration',
|
811 |
+
'name' => __( 'Download Link Expiration', 'easy-digital-downloads' ),
|
812 |
+
'desc' => __( 'How long should download links be valid for? Default is 24 hours from the time they are generated. Enter a time in hours.', 'easy-digital-downloads' ),
|
813 |
+
'tooltip_title' => __( 'Download Link Expiration', 'easy-digital-downloads' ),
|
814 |
+
'tooltip_desc' => __( 'When a customer receives a link to their downloads via email, in their receipt, or in their purchase history, the link will only be valid for the timeframe (in hours) defined in this setting. Sending a new purchase receipt or visiting the account page will re-generate a valid link for the customer.', 'easy-digital-downloads' ),
|
815 |
+
'type' => 'number',
|
816 |
+
'size' => 'small',
|
817 |
+
'std' => '24',
|
818 |
+
'min' => '0',
|
819 |
),
|
820 |
'disable_redownload' => array(
|
821 |
'id' => 'disable_redownload',
|
905 |
* @since 1.0.8.2
|
906 |
*
|
907 |
* @param array $input The value inputted in the field
|
908 |
+
* @global $edd_options Array of all the EDD Options
|
909 |
*
|
910 |
* @return string $input Sanitizied value
|
911 |
*/
|
914 |
global $edd_options;
|
915 |
|
916 |
if ( empty( $_POST['_wp_http_referer'] ) ) {
|
917 |
+
// If we didn't get the referer, just return the settings with nothing changed
|
918 |
+
return $edd_options;
|
919 |
}
|
920 |
|
921 |
parse_str( $_POST['_wp_http_referer'], $referrer );
|
926 |
|
927 |
$input = $input ? $input : array();
|
928 |
|
929 |
+
// Run a general sanitization for the tab for special fields (like taxes)
|
930 |
+
$input = apply_filters( 'edd_settings_' . $tab . '_sanitize', $input );
|
931 |
+
|
932 |
+
// Run a general sanitization for the section so custom tabs with sub-sections can save special data
|
933 |
$input = apply_filters( 'edd_settings_' . $tab . '-' . $section . '_sanitize', $input );
|
934 |
+
|
935 |
+
if ( 'main' === $section && empty( $settings[ $tab ]['main'] ) ) {
|
936 |
// Check for extensions that aren't using new sections
|
937 |
$input = apply_filters( 'edd_settings_' . $tab . '_sanitize', $input );
|
938 |
|
939 |
+
$settings[ $tab ]['main'] = array();
|
940 |
+
foreach ( $settings[ $tab ] as $key => $setting ) {
|
941 |
+
if ( is_int( $key ) ) {
|
942 |
+
$settings[ $tab ]['main'][ $setting[ 'id' ] ] = $setting;
|
943 |
+
unset( $settings[ $tab ][ $key ]);
|
944 |
+
}
|
945 |
+
|
946 |
+
// Check for an override on the section for when main is empty
|
947 |
+
if ( ! empty( $_POST['edd_section_override'] ) ) {
|
948 |
+
$section = sanitize_text_field( $_POST['edd_section_override'] );
|
949 |
+
}
|
950 |
}
|
951 |
}
|
952 |
|
954 |
foreach ( $input as $key => $value ) {
|
955 |
|
956 |
// Get the setting type (checkbox, select, etc)
|
957 |
+
$type = isset( $settings[ $tab ][ $section ][ $key ]['type'] ) ? $settings[ $tab ][ $section ][ $key ]['type'] : false;
|
958 |
|
959 |
if ( $type ) {
|
960 |
// Field type specific filter
|
966 |
}
|
967 |
|
968 |
// Loop through the whitelist and unset any that are empty for the tab being saved
|
969 |
+
$main_settings = $section == 'main' ? $settings[ $tab ]['main'] : array(); // Check for extensions that aren't using new sections
|
970 |
$section_settings = ! empty( $settings[ $tab ][ $section ] ) ? $settings[ $tab ][ $section ] : array();
|
971 |
|
972 |
+
$found_settings = array_merge( $main_settings, $section_settings );
|
973 |
|
974 |
if ( ! empty( $found_settings ) ) {
|
975 |
foreach ( $found_settings as $key => $value ) {
|
1003 |
*/
|
1004 |
function edd_settings_sanitize_misc_file_downloads( $input ) {
|
1005 |
|
|
|
|
|
1006 |
if( ! current_user_can( 'manage_shop_settings' ) ) {
|
1007 |
return $input;
|
1008 |
}
|
1025 |
*/
|
1026 |
function edd_settings_sanitize_misc_accounting( $input ) {
|
1027 |
|
|
|
|
|
1028 |
if( ! current_user_can( 'manage_shop_settings' ) ) {
|
1029 |
return $input;
|
1030 |
}
|
1056 |
return $input;
|
1057 |
}
|
1058 |
|
1059 |
+
if( ! isset( $_POST['tax_rates'] ) ) {
|
1060 |
+
return $input;
|
1061 |
+
}
|
1062 |
+
|
1063 |
$new_rates = ! empty( $_POST['tax_rates'] ) ? array_values( $_POST['tax_rates'] ) : array();
|
1064 |
|
1065 |
update_option( 'edd_tax_rates', $new_rates );
|
1076 |
* @return string $input Sanitizied value
|
1077 |
*/
|
1078 |
function edd_sanitize_text_field( $input ) {
|
1079 |
+
$tags = array(
|
1080 |
+
'p' => array(
|
1081 |
+
'class' => array(),
|
1082 |
+
'id' => array(),
|
1083 |
+
),
|
1084 |
+
'span' => array(
|
1085 |
+
'class' => array(),
|
1086 |
+
'id' => array(),
|
1087 |
+
),
|
1088 |
+
'a' => array(
|
1089 |
+
'href' => array(),
|
1090 |
+
'title' => array(),
|
1091 |
+
'class' => array(),
|
1092 |
+
'title' => array(),
|
1093 |
+
'id' => array(),
|
1094 |
+
),
|
1095 |
+
'strong' => array(),
|
1096 |
+
'em' => array(),
|
1097 |
+
'br' => array(),
|
1098 |
+
'img' => array(
|
1099 |
+
'src' => array(),
|
1100 |
+
'title' => array(),
|
1101 |
+
'alt' => array(),
|
1102 |
+
'id' => array(),
|
1103 |
+
),
|
1104 |
+
'div' => array(
|
1105 |
+
'class' => array(),
|
1106 |
+
'id' => array(),
|
1107 |
+
),
|
1108 |
+
'ul' => array(
|
1109 |
+
'class' => array(),
|
1110 |
+
'id' => array(),
|
1111 |
+
),
|
1112 |
+
'li' => array(
|
1113 |
+
'class' => array(),
|
1114 |
+
'id' => array(),
|
1115 |
+
)
|
1116 |
+
);
|
1117 |
+
|
1118 |
+
$allowed_tags = apply_filters( 'edd_allowed_html_tags', $tags );
|
1119 |
+
|
1120 |
+
return trim( wp_kses( $input, $allowed_tags ) );
|
1121 |
}
|
1122 |
add_filter( 'edd_settings_sanitize_text', 'edd_sanitize_text_field' );
|
1123 |
|
1262 |
* @return void
|
1263 |
*/
|
1264 |
function edd_header_callback( $args ) {
|
1265 |
+
echo apply_filters( 'edd_after_setting_output', '', $args );
|
1266 |
}
|
1267 |
|
1268 |
/**
|
1272 |
*
|
1273 |
* @since 1.0
|
1274 |
* @param array $args Arguments passed by the setting
|
1275 |
+
*
|
1276 |
* @return void
|
1277 |
*/
|
1278 |
function edd_checkbox_callback( $args ) {
|
1279 |
+
$edd_option = edd_get_option( $args['id'] );
|
1280 |
|
1281 |
if ( isset( $args['faux'] ) && true === $args['faux'] ) {
|
1282 |
$name = '';
|
1284 |
$name = 'name="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"';
|
1285 |
}
|
1286 |
|
1287 |
+
$checked = ! empty( $edd_option ) ? checked( 1, $edd_option, false ) : '';
|
1288 |
+
$html = '<input type="checkbox" id="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"' . $name . ' value="1" ' . $checked . '/>';
|
1289 |
+
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1290 |
|
1291 |
+
echo apply_filters( 'edd_after_setting_output', $html, $args );
|
1292 |
}
|
1293 |
|
1294 |
/**
|
1298 |
*
|
1299 |
* @since 1.0
|
1300 |
* @param array $args Arguments passed by the setting
|
1301 |
+
*
|
1302 |
* @return void
|
1303 |
*/
|
1304 |
function edd_multicheck_callback( $args ) {
|
1305 |
+
$edd_option = edd_get_option( $args['id'] );
|
1306 |
|
1307 |
+
$html = '';
|
1308 |
if ( ! empty( $args['options'] ) ) {
|
1309 |
foreach( $args['options'] as $key => $option ):
|
1310 |
+
if( isset( $edd_option[ $key ] ) ) { $enabled = $option; } else { $enabled = NULL; }
|
1311 |
+
$html .= '<input name="edd_settings[' . edd_sanitize_key( $args['id'] ) . '][' . edd_sanitize_key( $key ) . ']" id="edd_settings[' . edd_sanitize_key( $args['id'] ) . '][' . edd_sanitize_key( $key ) . ']" type="checkbox" value="' . esc_attr( $option ) . '" ' . checked($option, $enabled, false) . '/> ';
|
1312 |
+
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . '][' . edd_sanitize_key( $key ) . ']">' . wp_kses_post( $option ) . '</label><br/>';
|
1313 |
endforeach;
|
1314 |
+
$html .= '<p class="description">' . $args['desc'] . '</p>';
|
1315 |
}
|
1316 |
+
|
1317 |
+
echo apply_filters( 'edd_after_setting_output', $html, $args );
|
1318 |
}
|
1319 |
|
1320 |
/**
|
1322 |
*
|
1323 |
* @since 2.1
|
1324 |
* @param array $args Arguments passed by the setting
|
1325 |
+
*
|
1326 |
* @return void
|
1327 |
*/
|
1328 |
function edd_payment_icons_callback( $args ) {
|
1329 |
+
$edd_option = edd_get_option( $args['id'] );
|
1330 |
|
1331 |
+
$html = '';
|
1332 |
if ( ! empty( $args['options'] ) ) {
|
1333 |
foreach( $args['options'] as $key => $option ) {
|
1334 |
|
1335 |
+
if( isset( $edd_option[$key] ) ) {
|
1336 |
$enabled = $option;
|
1337 |
} else {
|
1338 |
$enabled = NULL;
|
1339 |
}
|
1340 |
|
1341 |
+
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . '][' . edd_sanitize_key( $key ) . ']" style="margin-right:10px;line-height:16px;height:16px;display:inline-block;">';
|
1342 |
|
1343 |
+
$html .= '<input name="edd_settings[' . edd_sanitize_key( $args['id'] ) . '][' . edd_sanitize_key( $key ) . ']" id="edd_settings[' . edd_sanitize_key( $args['id'] ) . '][' . edd_sanitize_key( $key ) . ']" type="checkbox" value="' . esc_attr( $option ) . '" ' . checked( $option, $enabled, false ) . '/> ';
|
1344 |
|
1345 |
if( edd_string_is_image_url( $key ) ) {
|
1346 |
|
1371 |
|
1372 |
}
|
1373 |
|
1374 |
+
$html .= '<img class="payment-icon" src="' . esc_url( $image ) . '" style="width:32px;height:24px;position:relative;top:6px;margin-right:5px;"/>';
|
1375 |
}
|
1376 |
|
1377 |
|
1378 |
+
$html .= $option . '</label>';
|
1379 |
|
1380 |
}
|
1381 |
+
$html .= '<p class="description" style="margin-top:16px;">' . wp_kses_post( $args['desc'] ) . '</p>';
|
1382 |
}
|
1383 |
+
|
1384 |
+
echo apply_filters( 'edd_after_setting_output', $html, $args );
|
1385 |
}
|
1386 |
|
1387 |
/**
|
1391 |
*
|
1392 |
* @since 1.3.3
|
1393 |
* @param array $args Arguments passed by the setting
|
1394 |
+
*
|
1395 |
* @return void
|
1396 |
*/
|
1397 |
function edd_radio_callback( $args ) {
|
1398 |
+
$edd_options = edd_get_option( $args['id'] );
|
1399 |
+
|
1400 |
+
$html = '';
|
1401 |
|
1402 |
foreach ( $args['options'] as $key => $option ) :
|
1403 |
$checked = false;
|
1404 |
|
1405 |
+
if ( $edd_options && $edd_options == $key )
|
1406 |
$checked = true;
|
1407 |
+
elseif( isset( $args['std'] ) && $args['std'] == $key && ! $edd_options )
|
1408 |
$checked = true;
|
1409 |
|
1410 |
+
$html .= '<input name="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']" id="edd_settings[' . edd_sanitize_key( $args['id'] ) . '][' . edd_sanitize_key( $key ) . ']" type="radio" value="' . edd_sanitize_key( $key ) . '" ' . checked(true, $checked, false) . '/> ';
|
1411 |
+
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . '][' . edd_sanitize_key( $key ) . ']">' . esc_html( $option ) . '</label><br/>';
|
1412 |
endforeach;
|
1413 |
|
1414 |
+
$html .= '<p class="description">' . apply_filters( 'edd_after_setting_output', wp_kses_post( $args['desc'] ), $args ) . '</p>';
|
1415 |
+
|
1416 |
+
echo $html;
|
1417 |
}
|
1418 |
|
1419 |
/**
|
1423 |
*
|
1424 |
* @since 1.0
|
1425 |
* @param array $args Arguments passed by the setting
|
1426 |
+
*
|
1427 |
* @return void
|
1428 |
*/
|
1429 |
function edd_gateways_callback( $args ) {
|
1430 |
+
$edd_option = edd_get_option( $args['id'] );
|
1431 |
+
|
1432 |
+
$html = '';
|
1433 |
|
1434 |
foreach ( $args['options'] as $key => $option ) :
|
1435 |
+
if ( isset( $edd_option[ $key ] ) )
|
1436 |
$enabled = '1';
|
1437 |
else
|
1438 |
$enabled = null;
|
1439 |
|
1440 |
+
$html .= '<input name="edd_settings[' . esc_attr( $args['id'] ) . '][' . edd_sanitize_key( $key ) . ']"" id="edd_settings[' . edd_sanitize_key( $args['id'] ) . '][' . edd_sanitize_key( $key ) . ']" type="checkbox" value="1" ' . checked('1', $enabled, false) . '/> ';
|
1441 |
+
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . '][' . edd_sanitize_key( $key ) . ']">' . esc_html( $option['admin_label'] ) . '</label><br/>';
|
1442 |
endforeach;
|
1443 |
+
|
1444 |
+
echo apply_filters( 'edd_after_setting_output', $html, $args );
|
1445 |
}
|
1446 |
|
1447 |
/**
|
1451 |
*
|
1452 |
* @since 1.5
|
1453 |
* @param array $args Arguments passed by the setting
|
1454 |
+
*
|
1455 |
* @return void
|
1456 |
*/
|
1457 |
+
function edd_gateway_select_callback( $args ) {
|
1458 |
+
$edd_option = edd_get_option( $args['id'] );
|
1459 |
+
|
1460 |
+
$html = '';
|
1461 |
|
1462 |
+
$html .= '<select name="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"" id="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']">';
|
1463 |
|
1464 |
foreach ( $args['options'] as $key => $option ) :
|
1465 |
+
$selected = isset( $edd_option ) ? selected( $key, $edd_option, false ) : '';
|
1466 |
+
$html .= '<option value="' . edd_sanitize_key( $key ) . '"' . $selected . '>' . esc_html( $option['admin_label'] ) . '</option>';
|
1467 |
endforeach;
|
1468 |
|
1469 |
+
$html .= '</select>';
|
1470 |
+
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1471 |
+
|
1472 |
+
echo apply_filters( 'edd_after_setting_output', $html, $args );
|
1473 |
}
|
1474 |
|
1475 |
/**
|
1479 |
*
|
1480 |
* @since 1.0
|
1481 |
* @param array $args Arguments passed by the setting
|
1482 |
+
*
|
1483 |
* @return void
|
1484 |
*/
|
1485 |
function edd_text_callback( $args ) {
|
1486 |
+
$edd_option = edd_get_option( $args['id'] );
|
1487 |
|
1488 |
+
if ( $edd_option ) {
|
1489 |
+
$value = $edd_option;
|
1490 |
} else {
|
1491 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
1492 |
}
|
1504 |
$html = '<input type="text" class="' . sanitize_html_class( $size ) . '-text" id="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']" ' . $name . ' value="' . esc_attr( stripslashes( $value ) ) . '"' . $readonly . '/>';
|
1505 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1506 |
|
1507 |
+
echo apply_filters( 'edd_after_setting_output', $html, $args );
|
1508 |
}
|
1509 |
|
1510 |
/**
|
1514 |
*
|
1515 |
* @since 1.9
|
1516 |
* @param array $args Arguments passed by the setting
|
1517 |
+
*
|
1518 |
* @return void
|
1519 |
*/
|
1520 |
function edd_number_callback( $args ) {
|
1521 |
+
$edd_option = edd_get_option( $args['id'] );
|
1522 |
|
1523 |
+
if ( $edd_option ) {
|
1524 |
+
$value = $edd_option;
|
1525 |
} else {
|
1526 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
1527 |
}
|
1542 |
$html = '<input type="number" step="' . esc_attr( $step ) . '" max="' . esc_attr( $max ) . '" min="' . esc_attr( $min ) . '" class="' . sanitize_html_class( $size ) . '-text" id="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']" ' . $name . ' value="' . esc_attr( stripslashes( $value ) ) . '"/>';
|
1543 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1544 |
|
1545 |
+
echo apply_filters( 'edd_after_setting_output', $html, $args );
|
1546 |
}
|
1547 |
|
1548 |
/**
|
1552 |
*
|
1553 |
* @since 1.0
|
1554 |
* @param array $args Arguments passed by the setting
|
1555 |
+
*
|
1556 |
* @return void
|
1557 |
*/
|
1558 |
function edd_textarea_callback( $args ) {
|
1559 |
+
$edd_option = edd_get_option( $args['id'] );
|
1560 |
|
1561 |
+
if ( $edd_option ) {
|
1562 |
+
$value = $edd_option;
|
1563 |
} else {
|
1564 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
1565 |
}
|
1567 |
$html = '<textarea class="large-text" cols="50" rows="5" id="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']" name="edd_settings[' . esc_attr( $args['id'] ) . ']">' . esc_textarea( stripslashes( $value ) ) . '</textarea>';
|
1568 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1569 |
|
1570 |
+
echo apply_filters( 'edd_after_setting_output', $html, $args );
|
1571 |
}
|
1572 |
|
1573 |
/**
|
1577 |
*
|
1578 |
* @since 1.3
|
1579 |
* @param array $args Arguments passed by the setting
|
1580 |
+
*
|
1581 |
* @return void
|
1582 |
*/
|
1583 |
function edd_password_callback( $args ) {
|
1584 |
+
$edd_options = edd_get_option( $args['id'] );
|
1585 |
|
1586 |
+
if ( $edd_options ) {
|
1587 |
+
$value = $edd_options;
|
1588 |
} else {
|
1589 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
1590 |
}
|
1593 |
$html = '<input type="password" class="' . sanitize_html_class( $size ) . '-text" id="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']" name="edd_settings[' . esc_attr( $args['id'] ) . ']" value="' . esc_attr( $value ) . '"/>';
|
1594 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1595 |
|
1596 |
+
echo apply_filters( 'edd_after_setting_output', $html, $args );
|
1597 |
}
|
1598 |
|
1599 |
/**
|
1619 |
*
|
1620 |
* @since 1.0
|
1621 |
* @param array $args Arguments passed by the setting
|
1622 |
+
*
|
1623 |
* @return void
|
1624 |
*/
|
1625 |
function edd_select_callback($args) {
|
1626 |
+
$edd_option = edd_get_option( $args['id'] );
|
1627 |
|
1628 |
+
if ( $edd_option ) {
|
1629 |
+
$value = $edd_option;
|
1630 |
} else {
|
1631 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
1632 |
}
|
1653 |
$html .= '</select>';
|
1654 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1655 |
|
1656 |
+
echo apply_filters( 'edd_after_setting_output', $html, $args );
|
1657 |
}
|
1658 |
|
1659 |
/**
|
1663 |
*
|
1664 |
* @since 1.8
|
1665 |
* @param array $args Arguments passed by the setting
|
1666 |
+
*
|
1667 |
* @return void
|
1668 |
*/
|
1669 |
function edd_color_select_callback( $args ) {
|
1670 |
+
$edd_option = edd_get_option( $args['id'] );
|
1671 |
|
1672 |
+
if ( $edd_option ) {
|
1673 |
+
$value = $edd_option;
|
1674 |
} else {
|
1675 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
1676 |
}
|
1685 |
$html .= '</select>';
|
1686 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1687 |
|
1688 |
+
echo apply_filters( 'edd_after_setting_output', $html, $args );
|
1689 |
}
|
1690 |
|
1691 |
/**
|
1695 |
*
|
1696 |
* @since 1.0
|
1697 |
* @param array $args Arguments passed by the setting
|
|
|
|
|
1698 |
*/
|
1699 |
function edd_rich_editor_callback( $args ) {
|
1700 |
+
$edd_option = edd_get_option( $args['id'] );
|
1701 |
|
1702 |
+
if ( $edd_option ) {
|
1703 |
+
$value = $edd_option;
|
1704 |
|
1705 |
if( empty( $args['allow_blank'] ) && empty( $value ) ) {
|
1706 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
1711 |
|
1712 |
$rows = isset( $args['size'] ) ? $args['size'] : 20;
|
1713 |
|
1714 |
+
|
1715 |
+
ob_start();
|
1716 |
+
wp_editor( stripslashes( $value ), 'edd_settings_' . esc_attr( $args['id'] ), array( 'textarea_name' => 'edd_settings[' . esc_attr( $args['id'] ) . ']', 'textarea_rows' => absint( $rows ) ) );
|
1717 |
+
$html = ob_get_clean();
|
|
|
|
|
|
|
1718 |
|
1719 |
$html .= '<br/><label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1720 |
|
1721 |
+
echo apply_filters( 'edd_after_setting_output', $html, $args );
|
1722 |
}
|
1723 |
|
1724 |
/**
|
1728 |
*
|
1729 |
* @since 1.0
|
1730 |
* @param array $args Arguments passed by the setting
|
1731 |
+
*
|
1732 |
* @return void
|
1733 |
*/
|
1734 |
function edd_upload_callback( $args ) {
|
1735 |
+
$edd_option = edd_get_option( $args['id'] );
|
1736 |
|
1737 |
+
if ( $edd_option ) {
|
1738 |
+
$value = $edd_option;
|
1739 |
} else {
|
1740 |
$value = isset($args['std']) ? $args['std'] : '';
|
1741 |
}
|
1745 |
$html .= '<span> <input type="button" class="edd_settings_upload_button button-secondary" value="' . __( 'Upload File', 'easy-digital-downloads' ) . '"/></span>';
|
1746 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1747 |
|
1748 |
+
echo apply_filters( 'edd_after_setting_output', $html, $args );
|
1749 |
}
|
1750 |
|
1751 |
|
1756 |
*
|
1757 |
* @since 1.6
|
1758 |
* @param array $args Arguments passed by the setting
|
1759 |
+
*
|
1760 |
* @return void
|
1761 |
*/
|
1762 |
function edd_color_callback( $args ) {
|
1763 |
+
$edd_option = edd_get_option( $args['id'] );
|
1764 |
|
1765 |
+
if ( $edd_option ) {
|
1766 |
+
$value = $edd_option;
|
1767 |
} else {
|
1768 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
1769 |
}
|
1773 |
$html = '<input type="text" class="edd-color-picker" id="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']" name="edd_settings[' . esc_attr( $args['id'] ) . ']" value="' . esc_attr( $value ) . '" data-default-color="' . esc_attr( $default ) . '" />';
|
1774 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1775 |
|
1776 |
+
echo apply_filters( 'edd_after_setting_output', $html, $args );
|
1777 |
}
|
1778 |
|
1779 |
/**
|
1783 |
*
|
1784 |
* @since 1.6
|
1785 |
* @param array $args Arguments passed by the setting
|
1786 |
+
*
|
1787 |
* @return void
|
1788 |
*/
|
1789 |
function edd_shop_states_callback($args) {
|
1790 |
+
$edd_option = edd_get_option( $args['id'] );
|
1791 |
|
1792 |
if ( isset( $args['placeholder'] ) ) {
|
1793 |
$placeholder = $args['placeholder'];
|
1802 |
$html = '<select id="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']" name="edd_settings[' . esc_attr( $args['id'] ) . ']"' . $class . 'data-placeholder="' . esc_html( $placeholder ) . '"/>';
|
1803 |
|
1804 |
foreach ( $states as $option => $name ) {
|
1805 |
+
$selected = isset( $edd_option ) ? selected( $option, $edd_option, false ) : '';
|
1806 |
$html .= '<option value="' . esc_attr( $option ) . '" ' . $selected . '>' . esc_html( $name ) . '</option>';
|
1807 |
}
|
1808 |
|
1809 |
$html .= '</select>';
|
1810 |
$html .= '<label for="edd_settings[' . edd_sanitize_key( $args['id'] ) . ']"> ' . wp_kses_post( $args['desc'] ) . '</label>';
|
1811 |
|
1812 |
+
echo apply_filters( 'edd_after_setting_output', $html, $args );
|
1813 |
}
|
1814 |
|
1815 |
/**
|
1819 |
*
|
1820 |
* @since 1.6
|
1821 |
* @param array $args Arguments passed by the setting
|
|
|
1822 |
* @return void
|
1823 |
*/
|
1824 |
function edd_tax_rates_callback($args) {
|
|
|
1825 |
$rates = edd_get_tax_rates();
|
1826 |
ob_start(); ?>
|
1827 |
<p><?php echo $args['desc']; ?></p>
|
1830 |
<tr>
|
1831 |
<th scope="col" class="edd_tax_country"><?php _e( 'Country', 'easy-digital-downloads' ); ?></th>
|
1832 |
<th scope="col" class="edd_tax_state"><?php _e( 'State / Province', 'easy-digital-downloads' ); ?></th>
|
1833 |
+
<th scope="col" class="edd_tax_global"><?php _e( 'Country Wide', 'easy-digital-downloads' ); ?></th>
|
1834 |
<th scope="col" class="edd_tax_rate"><?php _e( 'Rate', 'easy-digital-downloads' ); ?></th>
|
1835 |
<th scope="col"><?php _e( 'Remove', 'easy-digital-downloads' ); ?></th>
|
1836 |
</tr>
|
1926 |
* @return void
|
1927 |
*/
|
1928 |
function edd_descriptive_text_callback( $args ) {
|
1929 |
+
$html = wp_kses_post( $args['desc'] );
|
1930 |
+
|
1931 |
+
echo apply_filters( 'edd_after_setting_output', $html, $args );
|
1932 |
}
|
1933 |
|
1934 |
/**
|
1936 |
*
|
1937 |
* @since 1.5
|
1938 |
* @param array $args Arguments passed by the setting
|
1939 |
+
*
|
1940 |
* @return void
|
1941 |
*/
|
1942 |
if ( ! function_exists( 'edd_license_key_callback' ) ) {
|
1943 |
function edd_license_key_callback( $args ) {
|
1944 |
+
$edd_option = edd_get_option( $args['id'] );
|
1945 |
|
1946 |
$messages = array();
|
1947 |
$license = get_option( $args['options']['is_valid_license_option'] );
|
1948 |
|
1949 |
+
if ( $edd_option ) {
|
1950 |
+
$value = $edd_option;
|
1951 |
} else {
|
1952 |
$value = isset( $args['std'] ) ? $args['std'] : '';
|
1953 |
}
|
1961 |
|
1962 |
case 'expired' :
|
1963 |
|
1964 |
+
$class = 'expired';
|
1965 |
$messages[] = sprintf(
|
1966 |
+
__( 'Your license key expired on %s. Please <a href="%s" target="_blank">renew your license key</a>.', 'easy-digital-downloads' ),
|
1967 |
date_i18n( get_option( 'date_format' ), strtotime( $license->expires, current_time( 'timestamp' ) ) ),
|
1968 |
'https://easydigitaldownloads.com/checkout/?edd_license_key=' . $value . '&utm_campaign=admin&utm_source=licenses&utm_medium=expired'
|
1969 |
);
|
1972 |
|
1973 |
break;
|
1974 |
|
1975 |
+
case 'revoked' :
|
1976 |
+
|
1977 |
+
$class = 'error';
|
1978 |
+
$messages[] = sprintf(
|
1979 |
+
__( 'Your license key has been disabled. Please <a href="%s" target="_blank">contact support</a> for more information.', 'easy-digital-downloads' ),
|
1980 |
+
'https://easydigitaldownloads.com/support?utm_campaign=admin&utm_source=licenses&utm_medium=revoked'
|
1981 |
+
);
|
1982 |
+
|
1983 |
+
$license_status = 'license-' . $class . '-notice';
|
1984 |
+
|
1985 |
+
break;
|
1986 |
+
|
1987 |
case 'missing' :
|
1988 |
|
1989 |
$class = 'error';
|
1990 |
$messages[] = sprintf(
|
1991 |
+
__( 'Invalid license. Please <a href="%s" target="_blank">visit your account page</a> and verify it.', 'easy-digital-downloads' ),
|
1992 |
'https://easydigitaldownloads.com/your-account?utm_campaign=admin&utm_source=licenses&utm_medium=missing'
|
1993 |
);
|
1994 |
|
2001 |
|
2002 |
$class = 'error';
|
2003 |
$messages[] = sprintf(
|
2004 |
+
__( 'Your %s is not active for this URL. Please <a href="%s" target="_blank">visit your account page</a> to manage your license key URLs.', 'easy-digital-downloads' ),
|
2005 |
$args['name'],
|
2006 |
'https://easydigitaldownloads.com/your-account?utm_campaign=admin&utm_source=licenses&utm_medium=invalid'
|
2007 |
);
|
2013 |
case 'item_name_mismatch' :
|
2014 |
|
2015 |
$class = 'error';
|
2016 |
+
$messages[] = sprintf( __( 'This appears to be an invalid license key for %s.', 'easy-digital-downloads' ), $args['name'] );
|
2017 |
|
2018 |
$license_status = 'license-' . $class . '-notice';
|
2019 |
|
2028 |
|
2029 |
break;
|
2030 |
|
2031 |
+
default :
|
2032 |
+
|
2033 |
+
$messages[] = print_r( $license, true );
|
2034 |
+
break;
|
2035 |
}
|
2036 |
|
2037 |
} else {
|
2055 |
} elseif( $expiration > $now && $expiration - $now < ( DAY_IN_SECONDS * 30 ) ) {
|
2056 |
|
2057 |
$messages[] = sprintf(
|
2058 |
+
__( 'Your license key expires soon! It expires on %s. <a href="%s" target="_blank">Renew your license key</a>.', 'easy-digital-downloads' ),
|
2059 |
date_i18n( get_option( 'date_format' ), strtotime( $license->expires, current_time( 'timestamp' ) ) ),
|
2060 |
'https://easydigitaldownloads.com/checkout/?edd_license_key=' . $value . '&utm_campaign=admin&utm_source=licenses&utm_medium=renew'
|
2061 |
);
|
2080 |
}
|
2081 |
|
2082 |
} else {
|
2083 |
+
$class = 'empty';
|
2084 |
+
|
2085 |
+
$messages[] = sprintf(
|
2086 |
+
__( 'To receive updates, please enter your valid %s license key.', 'easy-digital-downloads' ),
|
2087 |
+
$args['name']
|
2088 |
+
);
|
2089 |
+
|
2090 |
$license_status = null;
|
2091 |
}
|
2092 |
|
2102 |
if ( ! empty( $messages ) ) {
|
2103 |
foreach( $messages as $message ) {
|
2104 |
|
2105 |
+
$html .= '<div class="edd-license-data edd-license-' . $class . ' ' . $license_status . '">';
|
2106 |
$html .= '<p>' . $message . '</p>';
|
2107 |
$html .= '</div>';
|
2108 |
|
2111 |
|
2112 |
wp_nonce_field( edd_sanitize_key( $args['id'] ) . '-nonce', edd_sanitize_key( $args['id'] ) . '-nonce' );
|
2113 |
|
2114 |
+
echo $html;
|
|
|
|
|
|
|
|
|
2115 |
}
|
2116 |
}
|
2117 |
|
2138 |
return 'manage_shop_settings';
|
2139 |
}
|
2140 |
add_filter( 'option_page_capability_edd_settings', 'edd_set_settings_cap' );
|
2141 |
+
|
2142 |
+
function edd_add_setting_tooltip( $html, $args ) {
|
2143 |
+
|
2144 |
+
if ( ! empty( $args['tooltip_title'] ) && ! empty( $args['tooltip_desc'] ) ) {
|
2145 |
+
$tooltip = '<span alt="f223" class="edd-help-tip dashicons dashicons-editor-help" title="<strong>' . $args['tooltip_title'] . '</strong>: ' . $args['tooltip_desc'] . '"></span>';
|
2146 |
+
$html .= $tooltip;
|
2147 |
+
}
|
2148 |
+
|
2149 |
+
return $html;
|
2150 |
+
}
|
2151 |
+
add_filter( 'edd_after_setting_output', 'edd_add_setting_tooltip', 10, 2 );
|
includes/admin/thickbox.php
CHANGED
@@ -19,19 +19,15 @@ if ( ! defined( 'ABSPATH' ) ) exit;
|
|
19 |
* @return string "Insert Download" Button
|
20 |
*/
|
21 |
function edd_media_button() {
|
22 |
-
global $pagenow, $typenow
|
23 |
$output = '';
|
24 |
|
25 |
/** Only run in post/page creation and edit screens */
|
26 |
if ( in_array( $pagenow, array( 'post.php', 'page.php', 'post-new.php', 'post-edit.php' ) ) && $typenow != 'download' ) {
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
} else {
|
32 |
-
$img = '<span class="wp-media-buttons-icon" id="edd-media-button"></span>';
|
33 |
-
$output = '<a href="#TB_inline?width=640&inlineId=choose-download" class="thickbox button edd-thickbox" title="' . sprintf( __( 'Insert %s', 'easy-digital-downloads' ), strtolower ( edd_get_label_singular() ) ) . '" style="padding-left: .4em;">' . $img . sprintf( __( 'Insert %s', 'easy-digital-downloads' ), strtolower( edd_get_label_singular() ) ) . '</a>';
|
34 |
-
}
|
35 |
}
|
36 |
echo $output;
|
37 |
}
|
@@ -54,37 +50,37 @@ function edd_admin_footer_for_thickbox() {
|
|
54 |
// Only run in post/page creation and edit screens
|
55 |
if ( in_array( $pagenow, array( 'post.php', 'page.php', 'post-new.php', 'post-edit.php' ) ) && $typenow != 'download' ) { ?>
|
56 |
<script type="text/javascript">
|
57 |
-
|
58 |
-
|
59 |
-
|
60 |
-
|
61 |
-
|
62 |
-
|
63 |
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
-
|
68 |
-
|
69 |
|
70 |
-
|
71 |
-
|
72 |
-
|
73 |
-
|
74 |
-
|
75 |
|
76 |
-
|
77 |
-
|
78 |
-
|
79 |
-
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
-
|
86 |
-
|
87 |
-
|
88 |
</script>
|
89 |
|
90 |
<div id="choose-download" style="display: none;">
|
@@ -132,11 +128,11 @@ function edd_admin_footer_for_thickbox() {
|
|
132 |
</div>
|
133 |
<p class="submit">
|
134 |
<input type="button" id="edd-insert-download" class="button-primary" value="<?php echo sprintf( __( 'Insert %s', 'easy-digital-downloads' ), edd_get_label_singular() ); ?>" onclick="insertDownload();" />
|
135 |
-
<a id="edd-cancel-download-insert" class="button-secondary" onclick="tb_remove();"
|
136 |
</p>
|
137 |
</div>
|
138 |
</div>
|
139 |
<?php
|
140 |
}
|
141 |
}
|
142 |
-
add_action( 'admin_footer', 'edd_admin_footer_for_thickbox' );
|
19 |
* @return string "Insert Download" Button
|
20 |
*/
|
21 |
function edd_media_button() {
|
22 |
+
global $pagenow, $typenow;
|
23 |
$output = '';
|
24 |
|
25 |
/** Only run in post/page creation and edit screens */
|
26 |
if ( in_array( $pagenow, array( 'post.php', 'page.php', 'post-new.php', 'post-edit.php' ) ) && $typenow != 'download' ) {
|
27 |
+
|
28 |
+
$img = '<span class="wp-media-buttons-icon" id="edd-media-button"></span>';
|
29 |
+
$output = '<a href="#TB_inline?width=640&inlineId=choose-download" class="thickbox button edd-thickbox" style="padding-left: .4em;">' . $img . sprintf( __( 'Insert %s', 'easy-digital-downloads' ), strtolower( edd_get_label_singular() ) ) . '</a>';
|
30 |
+
|
|
|
|
|
|
|
|
|
31 |
}
|
32 |
echo $output;
|
33 |
}
|
50 |
// Only run in post/page creation and edit screens
|
51 |
if ( in_array( $pagenow, array( 'post.php', 'page.php', 'post-new.php', 'post-edit.php' ) ) && $typenow != 'download' ) { ?>
|
52 |
<script type="text/javascript">
|
53 |
+
function insertDownload() {
|
54 |
+
var id = jQuery('#products').val(),
|
55 |
+
direct = jQuery('#select-edd-direct').val(),
|
56 |
+
style = jQuery('#select-edd-style').val(),
|
57 |
+
color = jQuery('#select-edd-color').is(':visible') ? jQuery('#select-edd-color').val() : '',
|
58 |
+
text = jQuery('#edd-text').val() || '<?php _e( "Purchase", "easy-digital-downloads" ); ?>';
|
59 |
|
60 |
+
// Return early if no download is selected
|
61 |
+
if ('' === id) {
|
62 |
+
alert('<?php _e( "You must choose a download", "easy-digital-downloads" ); ?>');
|
63 |
+
return;
|
64 |
+
}
|
65 |
|
66 |
+
if( '2' == direct ) {
|
67 |
+
direct = ' direct="true"';
|
68 |
+
} else {
|
69 |
+
direct = '';
|
70 |
+
}
|
71 |
|
72 |
+
// Send the shortcode to the editor
|
73 |
+
window.send_to_editor('[purchase_link id="' + id + '" style="' + style + '" color="' + color + '" text="' + text + '"' + direct +']');
|
74 |
+
}
|
75 |
+
jQuery(document).ready(function ($) {
|
76 |
+
$('#select-edd-style').change(function () {
|
77 |
+
if ($(this).val() === 'button') {
|
78 |
+
$('#edd-color-choice').slideDown();
|
79 |
+
} else {
|
80 |
+
$('#edd-color-choice').slideUp();
|
81 |
+
}
|
82 |
+
});
|
83 |
+
});
|
84 |
</script>
|
85 |
|
86 |
<div id="choose-download" style="display: none;">
|
128 |
</div>
|
129 |
<p class="submit">
|
130 |
<input type="button" id="edd-insert-download" class="button-primary" value="<?php echo sprintf( __( 'Insert %s', 'easy-digital-downloads' ), edd_get_label_singular() ); ?>" onclick="insertDownload();" />
|
131 |
+
<a id="edd-cancel-download-insert" class="button-secondary" onclick="tb_remove();"><?php _e( 'Cancel', 'easy-digital-downloads' ); ?></a>
|
132 |
</p>
|
133 |
</div>
|
134 |
</div>
|
135 |
<?php
|
136 |
}
|
137 |
}
|
138 |
+
add_action( 'admin_footer', 'edd_admin_footer_for_thickbox' );
|
includes/admin/tools.php
CHANGED
@@ -41,7 +41,7 @@ function edd_tools_page() {
|
|
41 |
), $tab_url );
|
42 |
|
43 |
$active = $active_tab == $tab_id ? ' nav-tab-active' : '';
|
44 |
-
echo '<a href="' . esc_url( $tab_url ) . '"
|
45 |
|
46 |
}
|
47 |
?>
|
@@ -323,6 +323,490 @@ function edd_tools_import_export_display() {
|
|
323 |
|
324 |
do_action( 'edd_tools_import_export_before' );
|
325 |
?>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
326 |
<div class="postbox">
|
327 |
<h3><span><?php _e( 'Export Settings', 'easy-digital-downloads' ); ?></span></h3>
|
328 |
<div class="inside">
|
@@ -448,7 +932,7 @@ function edd_tools_sysinfo_display() {
|
|
448 |
|
449 |
?>
|
450 |
<form action="<?php echo esc_url( admin_url( 'edit.php?post_type=download&page=edd-tools&tab=system_info' ) ); ?>" method="post" dir="ltr">
|
451 |
-
<textarea readonly="readonly" onclick="this.focus(); this.select()" id="system-info-textarea" name="edd-sysinfo"
|
452 |
<p class="submit">
|
453 |
<input type="hidden" name="edd-action" value="download_sysinfo" />
|
454 |
<?php submit_button( 'Download System Info File', 'primary', 'edd-download-sysinfo', false ); ?>
|
@@ -558,7 +1042,7 @@ function edd_tools_sysinfo_get() {
|
|
558 |
$return .= 'Version: ' . EDD_VERSION . "\n";
|
559 |
$return .= 'Upgraded From: ' . get_option( 'edd_version_upgraded_from', 'None' ) . "\n";
|
560 |
$return .= 'Test Mode: ' . ( edd_is_test_mode() ? "Enabled\n" : "Disabled\n" );
|
561 |
-
$return .= '
|
562 |
$return .= 'Guest Checkout: ' . ( edd_no_guest_checkout() ? "Disabled\n" : "Enabled\n" );
|
563 |
$return .= 'Symlinks: ' . ( apply_filters( 'edd_symlink_file_downloads', edd_get_option( 'symlink_file_downloads', false ) ) && function_exists( 'symlink' ) ? "Enabled\n" : "Disabled\n" );
|
564 |
$return .= 'Download Method: ' . ucfirst( edd_get_file_download_method() ) . "\n";
|
@@ -646,7 +1130,7 @@ function edd_tools_sysinfo_get() {
|
|
646 |
// Must-use plugins
|
647 |
// NOTE: MU plugins can't show updates!
|
648 |
$muplugins = get_mu_plugins();
|
649 |
-
if( count( $muplugins > 0 )
|
650 |
$return .= "\n" . '-- Must-Use Plugins' . "\n\n";
|
651 |
|
652 |
foreach( $muplugins as $plugin => $plugin_data ) {
|
41 |
), $tab_url );
|
42 |
|
43 |
$active = $active_tab == $tab_id ? ' nav-tab-active' : '';
|
44 |
+
echo '<a href="' . esc_url( $tab_url ) . '" class="nav-tab' . $active . '">' . esc_html( $tab_name ) . '</a>';
|
45 |
|
46 |
}
|
47 |
?>
|
323 |
|
324 |
do_action( 'edd_tools_import_export_before' );
|
325 |
?>
|
326 |
+
|
327 |
+
<div class="postbox edd-import-payment-history">
|
328 |
+
<h3><span><?php _e( 'Import Payment History', 'easy-digital-downloads' ); ?></span></h3>
|
329 |
+
<div class="inside">
|
330 |
+
<p><?php _e( 'Import a CSV file of payment records.', 'easy-digital-downloads' ); ?></p>
|
331 |
+
<form id="edd-import-payments" class="edd-import-form edd-import-export-form" action="<?php echo esc_url( add_query_arg( 'edd_action', 'upload_import_file', admin_url() ) ); ?>" method="post" enctype="multipart/form-data">
|
332 |
+
|
333 |
+
<div class="edd-import-file-wrap">
|
334 |
+
<?php wp_nonce_field( 'edd_ajax_import', 'edd_ajax_import' ); ?>
|
335 |
+
<input type="hidden" name="edd-import-class" value="EDD_Batch_Payments_Import"/>
|
336 |
+
<p>
|
337 |
+
<input name="edd-import-file" id="edd-payments-import-file" type="file" />
|
338 |
+
</p>
|
339 |
+
<span>
|
340 |
+
<input type="submit" value="<?php _e( 'Import CSV', 'easy-digital-downloads' ); ?>" class="button-secondary"/>
|
341 |
+
<span class="spinner"></span>
|
342 |
+
</span>
|
343 |
+
</div>
|
344 |
+
|
345 |
+
<div class="edd-import-options" id="edd-import-payments-options" style="display:none;">
|
346 |
+
|
347 |
+
<p>
|
348 |
+
<?php
|
349 |
+
printf(
|
350 |
+
__( 'Each column loaded from the CSV needs to be mapped to a payment field. Select the column that should be mapped to each field below. Any columns not needed can be ignored. See <a href="%s" target="_blank">this guide</a> for assistance with importing payment records.', 'easy-digital-downloads' ),
|
351 |
+
'http://docs.easydigitaldownloads.com/category/1337-importexport'
|
352 |
+
);
|
353 |
+
?>
|
354 |
+
</p>
|
355 |
+
|
356 |
+
<table class="widefat edd_repeatable_table" width="100%" cellpadding="0" cellspacing="0">
|
357 |
+
<thead>
|
358 |
+
<tr>
|
359 |
+
<th><strong><?php _e( 'Payment Field', 'easy-digital-downloads' ); ?></strong></th>
|
360 |
+
<th><strong><?php _e( 'CSV Column', 'easy-digital-downloads' ); ?></strong></th>
|
361 |
+
<th><strong><?php _e( 'Data Preview', 'easy-digital-downloads' ); ?></strong></th>
|
362 |
+
</tr>
|
363 |
+
</thead>
|
364 |
+
<tbody>
|
365 |
+
<tr>
|
366 |
+
<td><?php _e( 'Currency Code', 'easy-digital-downloads' ); ?></td>
|
367 |
+
<td>
|
368 |
+
<select name="edd-import-field[currency]" class="edd-import-csv-column">
|
369 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
370 |
+
</select>
|
371 |
+
</td>
|
372 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
373 |
+
</tr>
|
374 |
+
<tr class="alternate">
|
375 |
+
<td><?php _e( 'Email', 'easy-digital-downloads' ); ?></td>
|
376 |
+
<td>
|
377 |
+
<select name="edd-import-field[email]" class="edd-import-csv-column">
|
378 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
379 |
+
</select>
|
380 |
+
</td>
|
381 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
382 |
+
</tr>
|
383 |
+
<tr>
|
384 |
+
<td><?php _e( 'First Name', 'easy-digital-downloads' ); ?></td>
|
385 |
+
<td>
|
386 |
+
<select name="edd-import-field[first_name]" class="edd-import-csv-column">
|
387 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
388 |
+
</select>
|
389 |
+
</td>
|
390 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
391 |
+
</tr>
|
392 |
+
<tr class="alternate">
|
393 |
+
<td><?php _e( 'Last Name', 'easy-digital-downloads' ); ?></td>
|
394 |
+
<td>
|
395 |
+
<select name="edd-import-field[last_name]" class="edd-import-csv-column">
|
396 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
397 |
+
</select>
|
398 |
+
</td>
|
399 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
400 |
+
</tr>
|
401 |
+
<tr>
|
402 |
+
<td><?php _e( 'Customer ID', 'easy-digital-downloads' ); ?></td>
|
403 |
+
<td>
|
404 |
+
<select name="edd-import-field[customer_id]" class="edd-import-csv-column">
|
405 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
406 |
+
</select>
|
407 |
+
</td>
|
408 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
409 |
+
</tr>
|
410 |
+
<tr class="alternate">
|
411 |
+
<td><?php _e( 'Discount Code(s)', 'easy-digital-downloads' ); ?></td>
|
412 |
+
<td>
|
413 |
+
<select name="edd-import-field[discounts]" class="edd-import-csv-column">
|
414 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
415 |
+
</select>
|
416 |
+
</td>
|
417 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
418 |
+
</tr>
|
419 |
+
<tr>
|
420 |
+
<td><?php _e( 'IP Address', 'easy-digital-downloads' ); ?></td>
|
421 |
+
<td>
|
422 |
+
<select name="edd-import-field[ip]" class="edd-import-csv-column">
|
423 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
424 |
+
</select>
|
425 |
+
</td>
|
426 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
427 |
+
</tr>
|
428 |
+
<tr class="alternate">
|
429 |
+
<td><?php _e( 'Mode (Live|Test)', 'easy-digital-downloads' ); ?></td>
|
430 |
+
<td>
|
431 |
+
<select name="edd-import-field[mode]" class="edd-import-csv-column">
|
432 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
433 |
+
</select>
|
434 |
+
</td>
|
435 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
436 |
+
</tr>
|
437 |
+
<tr>
|
438 |
+
<td><?php _e( 'Parent Payment ID', 'easy-digital-downloads' ); ?></td>
|
439 |
+
<td>
|
440 |
+
<select name="edd-import-field[parent_payment_id]" class="edd-import-csv-column">
|
441 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
442 |
+
</select>
|
443 |
+
</td>
|
444 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
445 |
+
</tr>
|
446 |
+
<tr class="alternate">
|
447 |
+
<td><?php _e( 'Payment Method', 'easy-digital-downloads' ); ?></td>
|
448 |
+
<td>
|
449 |
+
<select name="edd-import-field[gateway]" class="edd-import-csv-column">
|
450 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
451 |
+
</select>
|
452 |
+
</td>
|
453 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
454 |
+
</tr>
|
455 |
+
<tr>
|
456 |
+
<td><?php _e( 'Payment Number', 'easy-digital-downloads' ); ?></td>
|
457 |
+
<td>
|
458 |
+
<select name="edd-import-field[number]" class="edd-import-csv-column">
|
459 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
460 |
+
</select>
|
461 |
+
</td>
|
462 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
463 |
+
</tr>
|
464 |
+
<tr class="alternate">
|
465 |
+
<td><?php _e( 'Date', 'easy-digital-downloads' ); ?></td>
|
466 |
+
<td>
|
467 |
+
<select name="edd-import-field[date]" class="edd-import-csv-column">
|
468 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
469 |
+
</select>
|
470 |
+
</td>
|
471 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
472 |
+
</tr>
|
473 |
+
<tr>
|
474 |
+
<td><?php _e( 'Purchase Key', 'easy-digital-downloads' ); ?></td>
|
475 |
+
<td>
|
476 |
+
<select name="edd-import-field[key]" class="edd-import-csv-column">
|
477 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
478 |
+
</select>
|
479 |
+
</td>
|
480 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
481 |
+
</tr>
|
482 |
+
<tr class="alternate">
|
483 |
+
<td><?php _e( 'Purchased Product(s)', 'easy-digital-downloads' ); ?></td>
|
484 |
+
<td>
|
485 |
+
<select name="edd-import-field[downloads]" class="edd-import-csv-column">
|
486 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
487 |
+
</select>
|
488 |
+
</td>
|
489 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
490 |
+
</tr>
|
491 |
+
<tr>
|
492 |
+
<td><?php _e( 'Status', 'easy-digital-downloads' ); ?></td>
|
493 |
+
<td>
|
494 |
+
<select name="edd-import-field[status]" class="edd-import-csv-column">
|
495 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
496 |
+
</select>
|
497 |
+
</td>
|
498 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
499 |
+
</tr>
|
500 |
+
<tr class="alternate">
|
501 |
+
<td><?php _e( 'Subtotal', 'easy-digital-downloads' ); ?></td>
|
502 |
+
<td>
|
503 |
+
<select name="edd-import-field[subtotal]" class="edd-import-csv-column">
|
504 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
505 |
+
</select>
|
506 |
+
</td>
|
507 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
508 |
+
</tr>
|
509 |
+
<tr>
|
510 |
+
<td><?php _e( 'Tax', 'easy-digital-downloads' ); ?></td>
|
511 |
+
<td>
|
512 |
+
<select name="edd-import-field[tax]" class="edd-import-csv-column">
|
513 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
514 |
+
</select>
|
515 |
+
</td>
|
516 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
517 |
+
</tr>
|
518 |
+
<tr class="alternate">
|
519 |
+
<td><?php _e( 'Total', 'easy-digital-downloads' ); ?></td>
|
520 |
+
<td>
|
521 |
+
<select name="edd-import-field[total]" class="edd-import-csv-column">
|
522 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
523 |
+
</select>
|
524 |
+
</td>
|
525 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
526 |
+
</tr>
|
527 |
+
<tr>
|
528 |
+
<td><?php _e( 'Transaction ID', 'easy-digital-downloads' ); ?></td>
|
529 |
+
<td>
|
530 |
+
<select name="edd-import-field[transaction_id]" class="edd-import-csv-column">
|
531 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
532 |
+
</select>
|
533 |
+
</td>
|
534 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
535 |
+
</tr>
|
536 |
+
<tr class="alternate">
|
537 |
+
<td><?php _e( 'User', 'easy-digital-downloads' ); ?></td>
|
538 |
+
<td>
|
539 |
+
<select name="edd-import-field[user_id]" class="edd-import-csv-column">
|
540 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
541 |
+
</select>
|
542 |
+
</td>
|
543 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
544 |
+
</tr>
|
545 |
+
<tr>
|
546 |
+
<td><?php _e( 'Address Line 1', 'easy-digital-downloads' ); ?></td>
|
547 |
+
<td>
|
548 |
+
<select name="edd-import-field[line1]" class="edd-import-csv-column">
|
549 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
550 |
+
</select>
|
551 |
+
</td>
|
552 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
553 |
+
</tr>
|
554 |
+
<tr class="alternate">
|
555 |
+
<td><?php _e( 'Address Line 2', 'easy-digital-downloads' ); ?></td>
|
556 |
+
<td>
|
557 |
+
<select name="edd-import-field[line2]" class="edd-import-csv-column">
|
558 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
559 |
+
</select>
|
560 |
+
</td>
|
561 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
562 |
+
</tr>
|
563 |
+
<tr class="alternate">
|
564 |
+
<td><?php _e( 'City', 'easy-digital-downloads' ); ?></td>
|
565 |
+
<td>
|
566 |
+
<select name="edd-import-field[city]" class="edd-import-csv-column">
|
567 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
568 |
+
</select>
|
569 |
+
</td>
|
570 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
571 |
+
</tr>
|
572 |
+
<tr>
|
573 |
+
<td><?php _e( 'State / Province', 'easy-digital-downloads' ); ?></td>
|
574 |
+
<td>
|
575 |
+
<select name="edd-import-field[state]" class="edd-import-csv-column">
|
576 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
577 |
+
</select>
|
578 |
+
</td>
|
579 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
580 |
+
</tr>
|
581 |
+
<tr class="alternate">
|
582 |
+
<td><?php _e( 'Zip / Postal Code', 'easy-digital-downloads' ); ?></td>
|
583 |
+
<td>
|
584 |
+
<select name="edd-import-field[zip]" class="edd-import-csv-column">
|
585 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
586 |
+
</select>
|
587 |
+
</td>
|
588 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
589 |
+
</tr>
|
590 |
+
<tr>
|
591 |
+
<td><?php _e( 'Country', 'easy-digital-downloads' ); ?></td>
|
592 |
+
<td>
|
593 |
+
<select name="edd-import-field[country]" class="edd-import-csv-column">
|
594 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
595 |
+
</select>
|
596 |
+
</td>
|
597 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
598 |
+
</tr>
|
599 |
+
</tbody>
|
600 |
+
</table>
|
601 |
+
<p class="submit">
|
602 |
+
<button class="edd-import-proceed button-primary"><?php _e( 'Process Import', 'easy-digital-downloads' ); ?></button>
|
603 |
+
</p>
|
604 |
+
</div>
|
605 |
+
</form>
|
606 |
+
</div><!-- .inside -->
|
607 |
+
</div><!-- .postbox -->
|
608 |
+
|
609 |
+
<div class="postbox edd-import-payment-history">
|
610 |
+
<h3><span><?php _e( 'Import Download Products', 'easy-digital-downloads' ); ?></span></h3>
|
611 |
+
<div class="inside">
|
612 |
+
<p><?php _e( 'Import a CSV file of products.', 'easy-digital-downloads' ); ?></p>
|
613 |
+
<form id="edd-import-downloads" class="edd-import-form edd-import-export-form" action="<?php echo esc_url( add_query_arg( 'edd_action', 'upload_import_file', admin_url() ) ); ?>" method="post" enctype="multipart/form-data">
|
614 |
+
|
615 |
+
<div class="edd-import-file-wrap">
|
616 |
+
<?php wp_nonce_field( 'edd_ajax_import', 'edd_ajax_import' ); ?>
|
617 |
+
<input type="hidden" name="edd-import-class" value="EDD_Batch_Downloads_Import"/>
|
618 |
+
<p>
|
619 |
+
<input name="edd-import-file" id="edd-downloads-import-file" type="file" />
|
620 |
+
</p>
|
621 |
+
<span>
|
622 |
+
<input type="submit" value="<?php _e( 'Import CSV', 'easy-digital-downloads' ); ?>" class="button-secondary"/>
|
623 |
+
<span class="spinner"></span>
|
624 |
+
</span>
|
625 |
+
</div>
|
626 |
+
|
627 |
+
<div class="edd-import-options" id="edd-import-downloads-options" style="display:none;">
|
628 |
+
|
629 |
+
<p>
|
630 |
+
<?php
|
631 |
+
printf(
|
632 |
+
__( 'Each column loaded from the CSV needs to be mapped to a Download product field. Select the column that should be mapped to each field below. Any columns not needed can be ignored. See <a href="%s" target="_blank">this guide</a> for assistance with importing Download products.', 'easy-digital-downloads' ),
|
633 |
+
'http://docs.easydigitaldownloads.com/category/1337-importexport'
|
634 |
+
);
|
635 |
+
?>
|
636 |
+
</p>
|
637 |
+
|
638 |
+
<table class="widefat edd_repeatable_table" width="100%" cellpadding="0" cellspacing="0">
|
639 |
+
<thead>
|
640 |
+
<tr>
|
641 |
+
<th><strong><?php _e( 'Product Field', 'easy-digital-downloads' ); ?></strong></th>
|
642 |
+
<th><strong><?php _e( 'CSV Column', 'easy-digital-downloads' ); ?></strong></th>
|
643 |
+
<th><strong><?php _e( 'Data Preview', 'easy-digital-downloads' ); ?></strong></th>
|
644 |
+
</tr>
|
645 |
+
</thead>
|
646 |
+
<tbody>
|
647 |
+
<tr>
|
648 |
+
<td><?php _e( 'Product Author', 'easy-digital-downloads' ); ?></td>
|
649 |
+
<td>
|
650 |
+
<select name="edd-import-field[post_author]" class="edd-import-csv-column">
|
651 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
652 |
+
</select>
|
653 |
+
</td>
|
654 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
655 |
+
</tr>
|
656 |
+
<tr class="alternate">
|
657 |
+
<td><?php _e( 'Product Categories', 'easy-digital-downloads' ); ?></td>
|
658 |
+
<td>
|
659 |
+
<select name="edd-import-field[categories]" class="edd-import-csv-column">
|
660 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
661 |
+
</select>
|
662 |
+
</td>
|
663 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
664 |
+
</tr>
|
665 |
+
<tr>
|
666 |
+
<td><?php _e( 'Product Creation Date', 'easy-digital-downloads' ); ?></td>
|
667 |
+
<td>
|
668 |
+
<select name="edd-import-field[post_date]" class="edd-import-csv-column">
|
669 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
670 |
+
</select>
|
671 |
+
</td>
|
672 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
673 |
+
</tr>
|
674 |
+
<tr class="alternate">
|
675 |
+
<td><?php _e( 'Product Description', 'easy-digital-downloads' ); ?></td>
|
676 |
+
<td>
|
677 |
+
<select name="edd-import-field[post_content]" class="edd-import-csv-column">
|
678 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
679 |
+
</select>
|
680 |
+
</td>
|
681 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
682 |
+
</tr>
|
683 |
+
<tr>
|
684 |
+
<td><?php _e( 'Product Excerpt', 'easy-digital-downloads' ); ?></td>
|
685 |
+
<td>
|
686 |
+
<select name="edd-import-field[post_excerpt]" class="edd-import-csv-column">
|
687 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
688 |
+
</select>
|
689 |
+
</td>
|
690 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
691 |
+
</tr>
|
692 |
+
<tr class="alternate">
|
693 |
+
<td><?php _e( 'Product Image', 'easy-digital-downloads' ); ?></td>
|
694 |
+
<td>
|
695 |
+
<select name="edd-import-field[featured_image]" class="edd-import-csv-column">
|
696 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
697 |
+
</select>
|
698 |
+
</td>
|
699 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
700 |
+
</tr>
|
701 |
+
<tr>
|
702 |
+
<td><?php _e( 'Product Notes', 'easy-digital-downloads' ); ?></td>
|
703 |
+
<td>
|
704 |
+
<select name="edd-import-field[notes]" class="edd-import-csv-column">
|
705 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
706 |
+
</select>
|
707 |
+
</td>
|
708 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
709 |
+
</tr>
|
710 |
+
<tr class="alternate">
|
711 |
+
<td><?php _e( 'Product Price(s)', 'easy-digital-downloads' ); ?></td>
|
712 |
+
<td>
|
713 |
+
<select name="edd-import-field[price]" class="edd-import-csv-column">
|
714 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
715 |
+
</select>
|
716 |
+
</td>
|
717 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
718 |
+
</tr>
|
719 |
+
<tr>
|
720 |
+
<td><?php _e( 'Product SKU', 'easy-digital-downloads' ); ?></td>
|
721 |
+
<td>
|
722 |
+
<select name="edd-import-field[sku]" class="edd-import-csv-column">
|
723 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
724 |
+
</select>
|
725 |
+
</td>
|
726 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
727 |
+
</tr>
|
728 |
+
<tr class="alternate">
|
729 |
+
<td><?php _e( 'Product Slug', 'easy-digital-downloads' ); ?></td>
|
730 |
+
<td>
|
731 |
+
<select name="edd-import-field[post_name]" class="edd-import-csv-column">
|
732 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
733 |
+
</select>
|
734 |
+
</td>
|
735 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
736 |
+
</tr>
|
737 |
+
<tr>
|
738 |
+
<td><?php _e( 'Product Status', 'easy-digital-downloads' ); ?></td>
|
739 |
+
<td>
|
740 |
+
<select name="edd-import-field[post_status]" class="edd-import-csv-column">
|
741 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
742 |
+
</select>
|
743 |
+
</td>
|
744 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
745 |
+
</tr>
|
746 |
+
<tr class="alternate">
|
747 |
+
<td><?php _e( 'Product Tags', 'easy-digital-downloads' ); ?></td>
|
748 |
+
<td>
|
749 |
+
<select name="edd-import-field[tags]" class="edd-import-csv-column">
|
750 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
751 |
+
</select>
|
752 |
+
</td>
|
753 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
754 |
+
</tr>
|
755 |
+
<tr>
|
756 |
+
<td><?php _e( 'Product Title', 'easy-digital-downloads' ); ?></td>
|
757 |
+
<td>
|
758 |
+
<select name="edd-import-field[post_title]" class="edd-import-csv-column">
|
759 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
760 |
+
</select>
|
761 |
+
</td>
|
762 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
763 |
+
</tr>
|
764 |
+
<tr class="alternate">
|
765 |
+
<td><?php _e( 'Download Files', 'easy-digital-downloads' ); ?></td>
|
766 |
+
<td>
|
767 |
+
<select name="edd-import-field[files]" class="edd-import-csv-column">
|
768 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
769 |
+
</select>
|
770 |
+
</td>
|
771 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
772 |
+
</tr>
|
773 |
+
<tr>
|
774 |
+
<td><?php _e( 'File Download Limit', 'easy-digital-downloads' ); ?></td>
|
775 |
+
<td>
|
776 |
+
<select name="edd-import-field[download_limit]" class="edd-import-csv-column">
|
777 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
778 |
+
</select>
|
779 |
+
</td>
|
780 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
781 |
+
</tr>
|
782 |
+
<tr class="alternate">
|
783 |
+
<td><?php _e( 'Sale Count', 'easy-digital-downloads' ); ?></td>
|
784 |
+
<td>
|
785 |
+
<select name="edd-import-field[sales]" class="edd-import-csv-column">
|
786 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
787 |
+
</select>
|
788 |
+
</td>
|
789 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
790 |
+
</tr>
|
791 |
+
<tr>
|
792 |
+
<td><?php _e( 'Total Earnings', 'easy-digital-downloads' ); ?></td>
|
793 |
+
<td>
|
794 |
+
<select name="edd-import-field[earnings]" class="edd-import-csv-column">
|
795 |
+
<option value=""><?php _e( '- Ignore this field -', 'easy-digital-downloads' ); ?></option>
|
796 |
+
</select>
|
797 |
+
</td>
|
798 |
+
<td class="edd-import-preview-field"><?php _e( '- select field to preview data -', 'easy-digital-downloads' ); ?></td>
|
799 |
+
</tr>
|
800 |
+
</tbody>
|
801 |
+
</table>
|
802 |
+
<p class="submit">
|
803 |
+
<button class="edd-import-proceed button-primary"><?php _e( 'Process Import', 'easy-digital-downloads' ); ?></button>
|
804 |
+
</p>
|
805 |
+
</div>
|
806 |
+
</form>
|
807 |
+
</div><!-- .inside -->
|
808 |
+
</div><!-- .postbox -->
|
809 |
+
|
810 |
<div class="postbox">
|
811 |
<h3><span><?php _e( 'Export Settings', 'easy-digital-downloads' ); ?></span></h3>
|
812 |
<div class="inside">
|
932 |
|
933 |
?>
|
934 |
<form action="<?php echo esc_url( admin_url( 'edit.php?post_type=download&page=edd-tools&tab=system_info' ) ); ?>" method="post" dir="ltr">
|
935 |
+
<textarea readonly="readonly" onclick="this.focus(); this.select()" id="system-info-textarea" name="edd-sysinfo"><?php echo edd_tools_sysinfo_get(); ?></textarea>
|
936 |
<p class="submit">
|
937 |
<input type="hidden" name="edd-action" value="download_sysinfo" />
|
938 |
<?php submit_button( 'Download System Info File', 'primary', 'edd-download-sysinfo', false ); ?>
|
1042 |
$return .= 'Version: ' . EDD_VERSION . "\n";
|
1043 |
$return .= 'Upgraded From: ' . get_option( 'edd_version_upgraded_from', 'None' ) . "\n";
|
1044 |
$return .= 'Test Mode: ' . ( edd_is_test_mode() ? "Enabled\n" : "Disabled\n" );
|
1045 |
+
$return .= 'AJAX: ' . ( ! edd_is_ajax_disabled() ? "Enabled\n" : "Disabled\n" );
|
1046 |
$return .= 'Guest Checkout: ' . ( edd_no_guest_checkout() ? "Disabled\n" : "Enabled\n" );
|
1047 |
$return .= 'Symlinks: ' . ( apply_filters( 'edd_symlink_file_downloads', edd_get_option( 'symlink_file_downloads', false ) ) && function_exists( 'symlink' ) ? "Enabled\n" : "Disabled\n" );
|
1048 |
$return .= 'Download Method: ' . ucfirst( edd_get_file_download_method() ) . "\n";
|
1130 |
// Must-use plugins
|
1131 |
// NOTE: MU plugins can't show updates!
|
1132 |
$muplugins = get_mu_plugins();
|
1133 |
+
if( count( $muplugins ) > 0 ) {
|
1134 |
$return .= "\n" . '-- Must-Use Plugins' . "\n\n";
|
1135 |
|
1136 |
foreach( $muplugins as $plugin => $plugin_data ) {
|
includes/admin/upgrades/upgrade-functions.php
CHANGED
@@ -12,6 +12,33 @@
|
|
12 |
// Exit if accessed directly
|
13 |
if ( ! defined( 'ABSPATH' ) ) exit;
|
14 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
15 |
/**
|
16 |
* Display Upgrade Notices
|
17 |
*
|
@@ -1114,3 +1141,14 @@ function edd_remove_refunded_sale_logs() {
|
|
1114 |
}
|
1115 |
}
|
1116 |
add_action( 'edd_remove_refunded_sale_logs', 'edd_remove_refunded_sale_logs' );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
12 |
// Exit if accessed directly
|
13 |
if ( ! defined( 'ABSPATH' ) ) exit;
|
14 |
|
15 |
+
|
16 |
+
/**
|
17 |
+
* Perform automatic database upgrades when necessary
|
18 |
+
*
|
19 |
+
* @since 2.6
|
20 |
+
* @return void
|
21 |
+
*/
|
22 |
+
function edd_do_automatic_upgrades() {
|
23 |
+
|
24 |
+
$did_upgrade = false;
|
25 |
+
$edd_version = preg_replace( '/[^0-9.].*/', '', get_option( 'edd_version' ) );
|
26 |
+
|
27 |
+
if( version_compare( $edd_version, EDD_VERSION, '<' ) ) {
|
28 |
+
|
29 |
+
edd_v26_upgrades();
|
30 |
+
$did_upgrade = true;
|
31 |
+
|
32 |
+
}
|
33 |
+
|
34 |
+
if( $did_upgrade ) {
|
35 |
+
update_option( 'edd_version', preg_replace( '/[^0-9.].*/', '', EDD_VERSION ) );
|
36 |
+
}
|
37 |
+
|
38 |
+
}
|
39 |
+
add_action( 'admin_init', 'edd_do_automatic_upgrades' );
|
40 |
+
|
41 |
+
|
42 |
/**
|
43 |
* Display Upgrade Notices
|
44 |
*
|
1141 |
}
|
1142 |
}
|
1143 |
add_action( 'edd_remove_refunded_sale_logs', 'edd_remove_refunded_sale_logs' );
|
1144 |
+
|
1145 |
+
/**
|
1146 |
+
* 2.6 Upgrade routine to create the customer meta table
|
1147 |
+
*
|
1148 |
+
* @since 2.6
|
1149 |
+
* @return void
|
1150 |
+
*/
|
1151 |
+
function edd_v26_upgrades() {
|
1152 |
+
@EDD()->customers->create_table();
|
1153 |
+
@EDD()->customer_meta->create_table();
|
1154 |
+
}
|
includes/admin/welcome.php
CHANGED
@@ -183,56 +183,53 @@ class EDD_Welcome {
|
|
183 |
$this->tabs();
|
184 |
?>
|
185 |
<div class="changelog">
|
186 |
-
<h3><?php _e( '
|
187 |
<div class="feature-section">
|
188 |
<div class="feature-section-media">
|
189 |
-
<img src="<?php echo EDD_PLUGIN_URL . 'assets/images/screenshots/
|
190 |
</div>
|
191 |
<div class="feature-section-content">
|
192 |
-
<p><?php _e( '
|
193 |
|
194 |
-
<
|
195 |
-
<p><?php _e( 'When using Amazon Payments, credit / debit card details are entered on Amazon\'s secure servers and never pass through your own server, making the entire process dramatically more secure and reliable.', 'easy-digital-downloads' );?></p>
|
196 |
|
197 |
-
<h4><?php _e( '
|
198 |
-
<p><?php _e( '
|
199 |
|
200 |
-
<h4><?php _e( '
|
201 |
-
<p><?php _e( '
|
202 |
</div>
|
203 |
</div>
|
204 |
</div>
|
205 |
|
206 |
<div class="changelog">
|
207 |
-
<h3><?php _e( '
|
208 |
<div class="feature-section">
|
209 |
<div class="feature-section-media">
|
210 |
-
<img src="<?php echo EDD_PLUGIN_URL . 'assets/images/screenshots/
|
211 |
</div>
|
212 |
<div class="feature-section-content">
|
213 |
-
<p><?php _e( '
|
214 |
|
215 |
-
<h4><?php _e( '
|
216 |
-
<p><?php _e( '
|
217 |
|
218 |
-
<h4><?php _e( '
|
219 |
-
<p><?php _e( '
|
220 |
</div>
|
221 |
</div>
|
222 |
</div>
|
223 |
|
224 |
<div class="changelog">
|
225 |
-
<h3><?php _e( '
|
226 |
<div class="feature-section">
|
227 |
<div class="feature-section-media">
|
228 |
-
<img src="<?php echo EDD_PLUGIN_URL . 'assets/images/screenshots/
|
229 |
</div>
|
230 |
<div class="feature-section-content">
|
231 |
-
<h4><?php _e( '
|
232 |
-
<p><?php _e( '
|
233 |
-
|
234 |
-
<h4><?php _e( 'Standardized Customer Export', 'easy-digital-downloads' );?></h4>
|
235 |
-
<p><?php _e( 'The Customer export has been standardized so it now produces the same data during export for all export options. It can also easily handle 20,000 or even 50,000 customer records in a single export.', 'easy-digital-downloads' );?></p>
|
236 |
</div>
|
237 |
</div>
|
238 |
</div>
|
@@ -241,29 +238,29 @@ class EDD_Welcome {
|
|
241 |
<h3><?php _e( 'Additional Updates', 'easy-digital-downloads' );?></h3>
|
242 |
<div class="feature-section three-col">
|
243 |
<div class="col">
|
244 |
-
<h4><?php _e( 'REST API
|
245 |
-
<p><?php _e( '
|
246 |
</div>
|
247 |
<div class="col">
|
248 |
-
<h4><?php _e( '
|
249 |
-
<p><?php _e( '
|
250 |
</div>
|
251 |
<div class="col">
|
252 |
-
<h4><?php _e( 'Customer
|
253 |
-
<p><?php _e( '
|
254 |
</div>
|
255 |
<div class="clear">
|
256 |
<div class="col">
|
257 |
-
<h4><?php _e( '
|
258 |
-
<p><?php _e( '
|
259 |
</div>
|
260 |
<div class="col">
|
261 |
-
<h4><?php _e( '
|
262 |
-
<p><?php _e( '
|
263 |
</div>
|
264 |
<div class="col">
|
265 |
-
<h4><?php _e( '
|
266 |
-
<p><?php _e( '
|
267 |
</div>
|
268 |
</div>
|
269 |
</div>
|
@@ -396,11 +393,11 @@ class EDD_Welcome {
|
|
396 |
<div class="feature-section two-col">
|
397 |
<div class="col">
|
398 |
<h4><?php _e( 'Get Notified of Extension Releases','easy-digital-downloads' );?></h4>
|
399 |
-
<p><?php _e( 'New extensions that make Easy Digital Downloads even more powerful are released nearly every single week. Subscribe to the newsletter to stay up to date with our latest releases. <a href="
|
400 |
</div>
|
401 |
<div class="col">
|
402 |
<h4><?php _e( 'Get Alerted About New Tutorials', 'easy-digital-downloads' );?></h4>
|
403 |
-
<p><?php _e( '<a href="
|
404 |
</div>
|
405 |
</div>
|
406 |
</div>
|
@@ -490,7 +487,7 @@ class EDD_Welcome {
|
|
490 |
|
491 |
foreach ( $contributors as $contributor ) {
|
492 |
$contributor_list .= '<li class="wp-person">';
|
493 |
-
$contributor_list .= sprintf( '<a href="%s"
|
494 |
esc_url( 'https://github.com/' . $contributor->login ),
|
495 |
esc_html( sprintf( __( 'View %s', 'easy-digital-downloads' ), $contributor->login ) )
|
496 |
);
|
183 |
$this->tabs();
|
184 |
?>
|
185 |
<div class="changelog">
|
186 |
+
<h3><?php _e( 'Additional Customer Emails', 'easy-digital-downloads' );?></h3>
|
187 |
<div class="feature-section">
|
188 |
<div class="feature-section-media">
|
189 |
+
<img src="<?php echo EDD_PLUGIN_URL . 'assets/images/screenshots/26-customer.png'; ?>"/>
|
190 |
</div>
|
191 |
<div class="feature-section-content">
|
192 |
+
<p><?php _e( 'To help keep track of customers that have multiple email addresses, Easy Digital Downloads now supports storing additional emails on customers. During checkout, customers can use any email address assigned to their account to complete their purchase.', 'easy-digital-downloads' );?></p>
|
193 |
|
194 |
+
<p><?php _e( 'Email addresses can be easily added by site administrators at anytime and will also be automatically registered when a customer makes a purchase with an additional email address.', 'easy-digital-downloads' );?></p>
|
|
|
195 |
|
196 |
+
<h4><?php _e( 'Improved Help Text', 'easy-digital-downloads' );?></h4>
|
197 |
+
<p><?php _e( 'While we strive to make Easy Digital Downloads live up to its name, there are always times when certain things are not quite clear. To help alleviate any uncertainty, we have introduced improved descriptions and help texts throughout the plugin. Along with the improved descriptions, we have also added tooltips in many places that offer verbose definitions of options.', 'easy-digital-downloads' );?></p>
|
198 |
|
199 |
+
<h4><?php _e( 'Better Mobile Checkout', 'easy-digital-downloads' );?></h4>
|
200 |
+
<p><?php _e( 'When purchasing with a debit or credit card from a mobile phone, the card number input field will now properly set the phone’s keyboard to a numerical keyboard.', 'easy-digital-downloads' );?></p>
|
201 |
</div>
|
202 |
</div>
|
203 |
</div>
|
204 |
|
205 |
<div class="changelog">
|
206 |
+
<h3><?php _e( 'Native Import Options', 'easy-digital-downloads' );?></h3>
|
207 |
<div class="feature-section">
|
208 |
<div class="feature-section-media">
|
209 |
+
<img src="<?php echo EDD_PLUGIN_URL . 'assets/images/screenshots/26-import.png'; ?>"/>
|
210 |
</div>
|
211 |
<div class="feature-section-content">
|
212 |
+
<p><?php _e( 'We believe you should own your data. We also believe that it should be easy to get data out of <em>and</em> into Easy Digital Downloads. 2.6 introduces native import options for payments and download products.', 'easy-digital-downloads' );?></p>
|
213 |
|
214 |
+
<h4><?php _e( 'Product Import', 'easy-digital-downloads' );?></h4>
|
215 |
+
<p><?php _e( 'With the new import options, Easy Digital Downloads now makes it easy to import products from a CSV file into your store. Whether you wish to import five products or 50,000, Easy Digital Downloads can now effortlessly handle the import for you.', 'easy-digital-downloads' );?></p>
|
216 |
|
217 |
+
<h4><?php _e( 'Payment Import', 'easy-digital-downloads' );?></h4>
|
218 |
+
<p><?php _e( 'Sometimes it is necessary to move purchase records from one location to another. Perhaps you are transitioning from another eCommerce system, or from a separate Easy Digital Downloads store; whatever the reason, Easy Digital Downloads now allows you to easily import purchase records from a CSV file.', 'easy-digital-downloads' );?></p>
|
219 |
</div>
|
220 |
</div>
|
221 |
</div>
|
222 |
|
223 |
<div class="changelog">
|
224 |
+
<h3><?php _e( 'Better Refunds', 'easy-digital-downloads' );?></h3>
|
225 |
<div class="feature-section">
|
226 |
<div class="feature-section-media">
|
227 |
+
<img src="<?php echo EDD_PLUGIN_URL . 'assets/images/screenshots/26-refund.png'; ?>" class="edd-welcome-screenshots alignleft"/>
|
228 |
</div>
|
229 |
<div class="feature-section-content">
|
230 |
+
<h4><?php _e( 'Refund Processing for PayPal Standard', 'easy-digital-downloads' );?></h4>
|
231 |
+
<p><?php _e( 'While not usually something store administrators take great pleasure in handling, refunds are a very real part of running an eCommerce store. As much as we would love to, we can’t make the actual refund more enjoyable, but we can make refunds easier to process.', 'easy-digital-downloads' );?></p>
|
232 |
+
<p><?php _e( 'In Easy Digital Downloads 2.6, we have added support for processing refunds directly from the View Order Details screen for purchases made through PayPal Standard.', 'easy-digital-downloads' );?></p>
|
|
|
|
|
233 |
</div>
|
234 |
</div>
|
235 |
</div>
|
238 |
<h3><?php _e( 'Additional Updates', 'easy-digital-downloads' );?></h3>
|
239 |
<div class="feature-section three-col">
|
240 |
<div class="col">
|
241 |
+
<h4><?php _e( 'REST API Version 2', 'easy-digital-downloads' );?></h4>
|
242 |
+
<p><?php _e( 'Version 2 of the REST API offers several improved endpoint options and better data standardization.', 'easy-digital-downloads' );?></p>
|
243 |
</div>
|
244 |
<div class="col">
|
245 |
+
<h4><?php _e( 'Prices on oEmbed', 'easy-digital-downloads' );?></h4>
|
246 |
+
<p><?php _e( 'When embedding a download product on another site, using WordPress core’s oEmbed feature, the product prices are now shown.', 'easy-digital-downloads' );?></p>
|
247 |
</div>
|
248 |
<div class="col">
|
249 |
+
<h4><?php _e( 'Customer Meta', 'easy-digital-downloads' );?></h4>
|
250 |
+
<p><?php _e( 'The customer database now includes a complete metadata API for storing additional information on customer records.' ,'easy-digital-downloads' );?></p>
|
251 |
</div>
|
252 |
<div class="clear">
|
253 |
<div class="col">
|
254 |
+
<h4><?php _e( 'Improved Accessibility', 'easy-digital-downloads' );?></h4>
|
255 |
+
<p><?php _e( 'Easy Digital Downloads is now more accessible to more users thanks to a member of the WordPress accessibility team who helped resolve accessibility issues throughout the administrative interfaces.', 'easy-digital-downloads' );?></p>
|
256 |
</div>
|
257 |
<div class="col">
|
258 |
+
<h4><?php _e( 'Resolved Schema Problems', 'easy-digital-downloads' );?></h4>
|
259 |
+
<p><?php _e( 'Invalid and missing schema microdata has been resolved.', 'easy-digital-downloads' );?></p>
|
260 |
</div>
|
261 |
<div class="col">
|
262 |
+
<h4><?php _e( 'More Actions and Filters', 'easy-digital-downloads' );?></h4>
|
263 |
+
<p><?php _e( 'Numerous new actions and filters have been added to help make Easy Digital Downloads more extensible for developers.' ,'easy-digital-downloads' );?></p>
|
264 |
</div>
|
265 |
</div>
|
266 |
</div>
|
393 |
<div class="feature-section two-col">
|
394 |
<div class="col">
|
395 |
<h4><?php _e( 'Get Notified of Extension Releases','easy-digital-downloads' );?></h4>
|
396 |
+
<p><?php _e( 'New extensions that make Easy Digital Downloads even more powerful are released nearly every single week. Subscribe to the newsletter to stay up to date with our latest releases. <a href="https://easydigitaldownloads.com/subscribe" target="_blank">Sign up now</a> to ensure you do not miss a release!', 'easy-digital-downloads' );?></p>
|
397 |
</div>
|
398 |
<div class="col">
|
399 |
<h4><?php _e( 'Get Alerted About New Tutorials', 'easy-digital-downloads' );?></h4>
|
400 |
+
<p><?php _e( '<a href="https://easydigitaldownloads.com/subscribe" target="_blank">Sign up now</a> to hear about the latest tutorial releases that explain how to take Easy Digital Downloads further.', 'easy-digital-downloads' );?></p>
|
401 |
</div>
|
402 |
</div>
|
403 |
</div>
|
487 |
|
488 |
foreach ( $contributors as $contributor ) {
|
489 |
$contributor_list .= '<li class="wp-person">';
|
490 |
+
$contributor_list .= sprintf( '<a href="%s">',
|
491 |
esc_url( 'https://github.com/' . $contributor->login ),
|
492 |
esc_html( sprintf( __( 'View %s', 'easy-digital-downloads' ), $contributor->login ) )
|
493 |
);
|
includes/ajax-functions.php
CHANGED
@@ -557,7 +557,7 @@ add_action( 'wp_ajax_edd_download_search', 'edd_ajax_download_search' );
|
|
557 |
add_action( 'wp_ajax_nopriv_edd_download_search', 'edd_ajax_download_search' );
|
558 |
|
559 |
/**
|
560 |
-
* Search the customers database via
|
561 |
*
|
562 |
* @since 2.2
|
563 |
* @return void
|
557 |
add_action( 'wp_ajax_nopriv_edd_download_search', 'edd_ajax_download_search' );
|
558 |
|
559 |
/**
|
560 |
+
* Search the customers database via AJAX
|
561 |
*
|
562 |
* @since 2.2
|
563 |
* @return void
|
includes/api/class-edd-api-v2.php
ADDED
@@ -0,0 +1,443 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Easy Digital Downloads API V1
|
4 |
+
*
|
5 |
+
* @package EDD
|
6 |
+
* @subpackage Classes/API
|
7 |
+
* @copyright Copyright (c) 2015, Pippin Williamson
|
8 |
+
* @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
|
9 |
+
* @since 2.6
|
10 |
+
*/
|
11 |
+
|
12 |
+
// Exit if accessed directly
|
13 |
+
if ( ! defined( 'ABSPATH' ) ) exit;
|
14 |
+
|
15 |
+
/**
|
16 |
+
* EDD_API_V2 Class
|
17 |
+
*
|
18 |
+
* The base version API class
|
19 |
+
*
|
20 |
+
* @since 2.6
|
21 |
+
*/
|
22 |
+
class EDD_API_V2 extends EDD_API_V1 {
|
23 |
+
|
24 |
+
/**
|
25 |
+
* Process Get Products API Request
|
26 |
+
*
|
27 |
+
* @access public
|
28 |
+
* @since 2.6
|
29 |
+
* @param array $args Query arguments
|
30 |
+
* @return array $customers Multidimensional array of the products
|
31 |
+
*/
|
32 |
+
public function get_products( $args = array() ) {
|
33 |
+
|
34 |
+
$products = array();
|
35 |
+
$error = array();
|
36 |
+
|
37 |
+
if ( empty( $args['product'] ) ) {
|
38 |
+
|
39 |
+
$products['products'] = array();
|
40 |
+
|
41 |
+
$query_args = array(
|
42 |
+
'post_type' => 'download',
|
43 |
+
'posts_per_page' => $this->per_page(),
|
44 |
+
'suppress_filters' => true,
|
45 |
+
'paged' => $this->get_paged(),
|
46 |
+
);
|
47 |
+
|
48 |
+
if( ! empty( $args['s'] ) ) {
|
49 |
+
$query_args['s'] = sanitize_text_field( $args['s'] );
|
50 |
+
}
|
51 |
+
|
52 |
+
if( ! empty( $args['category'] ) ) {
|
53 |
+
if ( strpos( $args['category'], ',' ) ) {
|
54 |
+
$args['category'] = explode( ',', $args['category'] );
|
55 |
+
}
|
56 |
+
|
57 |
+
if ( is_numeric( $args['category'] ) ) {
|
58 |
+
$query_args['tax_query'] = array(
|
59 |
+
array(
|
60 |
+
'taxonomy' => 'download_category',
|
61 |
+
'field' => 'ID',
|
62 |
+
'terms' => (int) $args['category']
|
63 |
+
),
|
64 |
+
);
|
65 |
+
} else if ( is_array( $args['category'] ) ) {
|
66 |
+
|
67 |
+
foreach ( $args['category'] as $category ) {
|
68 |
+
|
69 |
+
|
70 |
+
$field = is_numeric( $category ) ? 'ID': 'slug';
|
71 |
+
|
72 |
+
$query_args['tax_query'][] = array(
|
73 |
+
'taxonomy' => 'download_category',
|
74 |
+
'field' => $field,
|
75 |
+
'terms' => $category,
|
76 |
+
);
|
77 |
+
|
78 |
+
}
|
79 |
+
|
80 |
+
} else {
|
81 |
+
$query_args['download_category'] = $args['category'];
|
82 |
+
}
|
83 |
+
}
|
84 |
+
|
85 |
+
if( ! empty( $args['tag'] ) ) {
|
86 |
+
if ( strpos( $args['tag'], ',' ) ) {
|
87 |
+
$args['tag'] = explode( ',', $args['tag'] );
|
88 |
+
}
|
89 |
+
|
90 |
+
if ( is_numeric( $args['tag'] ) ) {
|
91 |
+
$query_args['tax_query'] = array(
|
92 |
+
array(
|
93 |
+
'taxonomy' => 'download_tag',
|
94 |
+
'field' => 'ID',
|
95 |
+
'terms' => (int) $args['tag']
|
96 |
+
),
|
97 |
+
);
|
98 |
+
} else if ( is_array( $args['tag'] ) ) {
|
99 |
+
|
100 |
+
foreach ( $args['tag'] as $tag ) {
|
101 |
+
|
102 |
+
|
103 |
+
$field = is_numeric( $tag ) ? 'ID': 'slug';
|
104 |
+
|
105 |
+
$query_args['tax_query'][] = array(
|
106 |
+
'taxonomy' => 'download_tag',
|
107 |
+
'field' => $field,
|
108 |
+
'terms' => $tag,
|
109 |
+
);
|
110 |
+
|
111 |
+
}
|
112 |
+
|
113 |
+
} else {
|
114 |
+
$query_args['download_tag'] = $args['tag'];
|
115 |
+
}
|
116 |
+
}
|
117 |
+
|
118 |
+
if ( ! empty( $query_args['tax_query'] ) ) {
|
119 |
+
|
120 |
+
$relation = ! empty( $args['term_relation'] ) ? sanitize_text_field( $args['term_relation'] ) : 'OR';
|
121 |
+
$query_args['tax_query']['relation'] = $relation;
|
122 |
+
|
123 |
+
}
|
124 |
+
|
125 |
+
$product_list = get_posts( $query_args );
|
126 |
+
|
127 |
+
if ( $product_list ) {
|
128 |
+
$i = 0;
|
129 |
+
foreach ( $product_list as $product_info ) {
|
130 |
+
$products['products'][$i] = $this->get_product_data( $product_info );
|
131 |
+
$i++;
|
132 |
+
}
|
133 |
+
}
|
134 |
+
|
135 |
+
} else {
|
136 |
+
|
137 |
+
if ( get_post_type( $args['product'] ) == 'download' ) {
|
138 |
+
$product_info = get_post( $args['product'] );
|
139 |
+
|
140 |
+
$products['products'][0] = $this->get_product_data( $product_info );
|
141 |
+
|
142 |
+
} else {
|
143 |
+
$error['error'] = sprintf( __( 'Product %s not found!', 'easy-digital-downloads' ), $args['product'] );
|
144 |
+
return $error;
|
145 |
+
}
|
146 |
+
}
|
147 |
+
|
148 |
+
return $products;
|
149 |
+
}
|
150 |
+
|
151 |
+
/**
|
152 |
+
* Given a download post object, generate the data for the API output
|
153 |
+
*
|
154 |
+
* @since 2.6
|
155 |
+
* @param object $product_info The Download Post Object
|
156 |
+
* @return array Array of post data to return back in the API
|
157 |
+
*/
|
158 |
+
public function get_product_data( $product_info ) {
|
159 |
+
|
160 |
+
// Use the parent's get_product_data to reduce code duplication
|
161 |
+
$product = parent::get_product_data( $product_info );
|
162 |
+
|
163 |
+
if ( edd_use_skus() ) {
|
164 |
+
$product['info']['sku'] = edd_get_download_sku( $product['info']['id'] );
|
165 |
+
}
|
166 |
+
|
167 |
+
return apply_filters( 'edd_api_products_product_v2', $product );
|
168 |
+
|
169 |
+
}
|
170 |
+
|
171 |
+
/**
|
172 |
+
* Process Get Customers API Request
|
173 |
+
*
|
174 |
+
* @access public
|
175 |
+
* @since 2.6
|
176 |
+
* @global object $wpdb Used to query the database using the WordPress Database API
|
177 |
+
* @param array $args Array of arguments for filters customers
|
178 |
+
* @return array $customers Multidimensional array of the customers
|
179 |
+
*/
|
180 |
+
public function get_customers( $args = array() ) {
|
181 |
+
global $wpdb;
|
182 |
+
|
183 |
+
$paged = $this->get_paged();
|
184 |
+
$per_page = $this->per_page();
|
185 |
+
$offset = $per_page * ( $paged - 1 );
|
186 |
+
|
187 |
+
$defaults = array(
|
188 |
+
'customer' => null,
|
189 |
+
'date' => null,
|
190 |
+
'startdate' => null,
|
191 |
+
'enddate' => null,
|
192 |
+
'number' => $per_page,
|
193 |
+
'offset' => $offset,
|
194 |
+
);
|
195 |
+
|
196 |
+
$args = wp_parse_args( $args, $defaults );
|
197 |
+
$customers = array();
|
198 |
+
$error = array();
|
199 |
+
|
200 |
+
if( ! user_can( $this->user_id, 'view_shop_sensitive_data' ) && ! $this->override ) {
|
201 |
+
return $customers;
|
202 |
+
}
|
203 |
+
|
204 |
+
if( is_numeric( $args['customer'] ) ) {
|
205 |
+
$field = 'id';
|
206 |
+
} else {
|
207 |
+
$field = 'email';
|
208 |
+
}
|
209 |
+
|
210 |
+
$args[ $field ] = $args['customer'];
|
211 |
+
|
212 |
+
$dates = $this->get_dates( $args );
|
213 |
+
|
214 |
+
if( $args['date'] === 'range' ) {
|
215 |
+
|
216 |
+
// Ensure the end date is later than the start date
|
217 |
+
if( ( ! empty( $args['enddate'] ) && ! empty( $args['enddate'] ) ) && $args['enddate'] < $args['startdate'] ) {
|
218 |
+
$error['error'] = __( 'The end date must be later than the start date!', 'easy-digital-downloads' );
|
219 |
+
}
|
220 |
+
|
221 |
+
$date_range = array();
|
222 |
+
if ( ! empty( $args['startdate'] ) ) {
|
223 |
+
$date_range['start'] = $dates['year'] . sprintf('%02d', $dates['m_start'] ) . $dates['day_start'];
|
224 |
+
}
|
225 |
+
|
226 |
+
if ( ! empty( $args['enddate'] ) ) {
|
227 |
+
$date_range['end'] = $dates['year_end'] . sprintf('%02d', $dates['m_end'] ) . $dates['day_end'];
|
228 |
+
}
|
229 |
+
|
230 |
+
$args['date'] = $date_range;
|
231 |
+
|
232 |
+
} elseif( ! empty( $args['date'] ) ) {
|
233 |
+
|
234 |
+
if( $args['date'] == 'this_quarter' || $args['date'] == 'last_quarter' ) {
|
235 |
+
|
236 |
+
$args['date'] = array(
|
237 |
+
'start' => $dates['year'] . sprintf('%02d', $dates['m_start'] ) . '01',
|
238 |
+
'end' => $dates['year'] . sprintf('%02d', $dates['m_end'] ) . cal_days_in_month( CAL_GREGORIAN, $dates['m_end'], $dates['year'] ),
|
239 |
+
);
|
240 |
+
|
241 |
+
} else if ( $args['date'] == 'this_month' || $args['date'] == 'last_month' ) {
|
242 |
+
$args['date'] = array(
|
243 |
+
'start' => $dates['year'] . sprintf( '%02d', $dates['m_start'] ) . '01',
|
244 |
+
'end' => $dates['year'] . sprintf( '%02d', $dates['m_end'] ). cal_days_in_month( CAL_GREGORIAN, $dates['m_end'], $dates['year'] ),
|
245 |
+
);
|
246 |
+
} else if ( $args['date'] == 'this_year' || $args['date'] == 'last_year' ) {
|
247 |
+
$args['date'] = array(
|
248 |
+
'start' => $dates['year'] . '0101',
|
249 |
+
'end' => $dates['year'] . '1231',
|
250 |
+
);
|
251 |
+
} else {
|
252 |
+
$args['date'] = $dates['year'] . sprintf('%02d', $dates['m_start'] ) . $dates['day'];
|
253 |
+
}
|
254 |
+
}
|
255 |
+
|
256 |
+
unset( $args['startdate'], $args['enddate'] );
|
257 |
+
|
258 |
+
$customer_query = EDD()->customers->get_customers( $args );
|
259 |
+
$customer_count = 0;
|
260 |
+
|
261 |
+
if( $customer_query ) {
|
262 |
+
|
263 |
+
foreach ( $customer_query as $customer_obj ) {
|
264 |
+
// Setup a new EDD_Customer object so additional details are defined (like additional emails)
|
265 |
+
$customer_obj = new EDD_Customer( $customer_obj->id );
|
266 |
+
|
267 |
+
$names = explode( ' ', $customer_obj->name );
|
268 |
+
$first_name = ! empty( $names[0] ) ? $names[0] : '';
|
269 |
+
$last_name = '';
|
270 |
+
if( ! empty( $names[1] ) ) {
|
271 |
+
unset( $names[0] );
|
272 |
+
$last_name = implode( ' ', $names );
|
273 |
+
}
|
274 |
+
|
275 |
+
$customers['customers'][ $customer_count ]['info']['customer_id'] = $customer_obj->id;
|
276 |
+
$customers['customers'][ $customer_count ]['info']['user_id'] = 0;
|
277 |
+
$customers['customers'][ $customer_count ]['info']['username'] = '';
|
278 |
+
$customers['customers'][ $customer_count ]['info']['display_name'] = '';
|
279 |
+
$customers['customers'][ $customer_count ]['info']['first_name'] = $first_name;
|
280 |
+
$customers['customers'][ $customer_count ]['info']['last_name'] = $last_name;
|
281 |
+
$customers['customers'][ $customer_count ]['info']['email'] = $customer_obj->email;
|
282 |
+
$customers['customers'][ $customer_count ]['info']['additional_emails'] = array();
|
283 |
+
$customers['customers'][ $customer_count ]['info']['date_created'] = $customer_obj->date_created;
|
284 |
+
|
285 |
+
if ( ! empty( $customer_obj->emails ) && count( $customer_obj->emails ) > 1 ) {
|
286 |
+
$additional_emails = $customer_obj->emails;
|
287 |
+
|
288 |
+
$primary_email_key = array_search( $customer_obj->email, $customer_obj->emails );
|
289 |
+
if ( false !== $primary_email_key ) {
|
290 |
+
unset( $additional_emails[ $primary_email_key ] );
|
291 |
+
}
|
292 |
+
|
293 |
+
$customers['customers'][ $customer_count ]['info']['additional_emails'] = $additional_emails;
|
294 |
+
}
|
295 |
+
|
296 |
+
if ( ! empty( $customer_obj->user_id ) && $customer_obj->user_id > 0 ) {
|
297 |
+
|
298 |
+
$user_data = get_userdata( $customer_obj->user_id );
|
299 |
+
|
300 |
+
// Customer with registered account
|
301 |
+
|
302 |
+
// id is going to get deprecated in the future, user user_id or customer_id instead
|
303 |
+
$customers['customers'][ $customer_count ]['info']['user_id'] = $customer_obj->user_id;
|
304 |
+
$customers['customers'][ $customer_count ]['info']['username'] = $user_data->user_login;
|
305 |
+
$customers['customers'][ $customer_count ]['info']['display_name'] = $user_data->display_name;
|
306 |
+
|
307 |
+
}
|
308 |
+
|
309 |
+
$customers['customers'][ $customer_count ]['stats']['total_purchases'] = $customer_obj->purchase_count;
|
310 |
+
$customers['customers'][ $customer_count ]['stats']['total_spent'] = $customer_obj->purchase_value;
|
311 |
+
$customers['customers'][ $customer_count ]['stats']['total_downloads'] = edd_count_file_downloads_of_user( $customer_obj->email );
|
312 |
+
|
313 |
+
$customer_count++;
|
314 |
+
|
315 |
+
}
|
316 |
+
|
317 |
+
} elseif( $args['customer'] ) {
|
318 |
+
|
319 |
+
$error['error'] = sprintf( __( 'Customer %s not found!', 'easy-digital-downloads' ), $customer );
|
320 |
+
return $error;
|
321 |
+
|
322 |
+
} else {
|
323 |
+
|
324 |
+
$error['error'] = __( 'No customers found!', 'easy-digital-downloads' );
|
325 |
+
return $error;
|
326 |
+
|
327 |
+
}
|
328 |
+
|
329 |
+
return $customers;
|
330 |
+
}
|
331 |
+
|
332 |
+
/**
|
333 |
+
* Retrieves Recent Sales
|
334 |
+
*
|
335 |
+
* @access public
|
336 |
+
* @since 2.6
|
337 |
+
* @return array
|
338 |
+
*/
|
339 |
+
public function get_recent_sales() {
|
340 |
+
global $wp_query;
|
341 |
+
|
342 |
+
$sales = array();
|
343 |
+
|
344 |
+
if( ! user_can( $this->user_id, 'view_shop_reports' ) && ! $this->override ) {
|
345 |
+
return $sales;
|
346 |
+
}
|
347 |
+
|
348 |
+
if( isset( $wp_query->query_vars['id'] ) ) {
|
349 |
+
$query = array();
|
350 |
+
$query[] = new EDD_Payment( $wp_query->query_vars['id'] );
|
351 |
+
} elseif( isset( $wp_query->query_vars['purchasekey'] ) ) {
|
352 |
+
$query = array();
|
353 |
+
$query[] = edd_get_payment_by( 'key', $wp_query->query_vars['purchasekey'] );
|
354 |
+
} elseif( isset( $wp_query->query_vars['email'] ) ) {
|
355 |
+
$query = edd_get_payments( array( 'fields' => 'ids', 'meta_key' => '_edd_payment_user_email', 'meta_value' => $wp_query->query_vars['email'], 'number' => $this->per_page(), 'page' => $this->get_paged(), 'status' => 'publish' ) );
|
356 |
+
} else {
|
357 |
+
$query = edd_get_payments( array( 'fields' => 'ids', 'number' => $this->per_page(), 'page' => $this->get_paged(), 'status' => 'publish' ) );
|
358 |
+
}
|
359 |
+
|
360 |
+
if ( $query ) {
|
361 |
+
$i = 0;
|
362 |
+
foreach ( $query as $payment ) {
|
363 |
+
if ( is_numeric( $payment ) ) {
|
364 |
+
$payment = new EDD_Payment( $payment );
|
365 |
+
}
|
366 |
+
|
367 |
+
$payment_meta = $payment->get_meta();
|
368 |
+
$user_info = $payment->user_info;
|
369 |
+
|
370 |
+
$sales['sales'][ $i ]['ID'] = $payment->number;
|
371 |
+
$sales['sales'][ $i ]['transaction_id'] = $payment->transaction_id;
|
372 |
+
$sales['sales'][ $i ]['key'] = $payment->key;
|
373 |
+
$sales['sales'][ $i ]['subtotal'] = $payment->subtotal;
|
374 |
+
$sales['sales'][ $i ]['tax'] = $payment->tax;
|
375 |
+
$sales['sales'][ $i ]['fees'] = $payment->fees;
|
376 |
+
$sales['sales'][ $i ]['total'] = $payment->total;
|
377 |
+
$sales['sales'][ $i ]['gateway'] = $payment->gateway;
|
378 |
+
$sales['sales'][ $i ]['email'] = $payment->email;
|
379 |
+
$sales['sales'][ $i ]['date'] = $payment->date;
|
380 |
+
|
381 |
+
$c = 0;
|
382 |
+
|
383 |
+
$discounts = ! empty( $payment->discounts ) ? explode( ',', $payment->discounts ) : array();
|
384 |
+
$discounts = array_map( 'trim', $discounts );
|
385 |
+
$discount_values = array();
|
386 |
+
|
387 |
+
foreach ( $discounts as $discount ) {
|
388 |
+
if ( 'none' === $discount ) { continue; }
|
389 |
+
|
390 |
+
$discount_values[ $discount ] = 0;
|
391 |
+
}
|
392 |
+
|
393 |
+
$cart_items = array();
|
394 |
+
|
395 |
+
foreach ( $payment->cart_details as $key => $item ) {
|
396 |
+
|
397 |
+
$item_id = isset( $item['id'] ) ? $item['id'] : $item;
|
398 |
+
$price = isset( $item['price'] ) ? $item['price'] : false; // The final price for the item
|
399 |
+
$item_price = isset( $item['item_price'] ) ? $item['item_price'] : false; // The price before discounts
|
400 |
+
|
401 |
+
$price_id = isset( $item['item_number']['options']['price_id'] ) ? $item['item_number']['options']['price_id'] : null;
|
402 |
+
$quantity = isset( $item['quantity'] ) && $item['quantity'] > 0 ? $item['quantity'] : 1;
|
403 |
+
|
404 |
+
if( ! $price ) {
|
405 |
+
// This function is only used on payments with near 1.0 cart data structure
|
406 |
+
$price = edd_get_download_final_price( $item_id, $user_info, null );
|
407 |
+
}
|
408 |
+
|
409 |
+
$price_name = '';
|
410 |
+
if ( isset( $item['item_number'] ) && isset( $item['item_number']['options'] ) ) {
|
411 |
+
$price_options = $item['item_number']['options'];
|
412 |
+
if ( isset( $price_options['price_id'] ) ) {
|
413 |
+
$price_name = edd_get_price_option_name( $item_id, $price_options['price_id'], $payment->ID );
|
414 |
+
}
|
415 |
+
}
|
416 |
+
|
417 |
+
$cart_items[ $c ]['id'] = $item_id;
|
418 |
+
$cart_items[ $c ]['quantity'] = $quantity;
|
419 |
+
$cart_items[ $c ]['name'] = get_the_title( $item_id );
|
420 |
+
$cart_items[ $c ]['price'] = $price;
|
421 |
+
$cart_items[ $c ]['price_name'] = $price_name;
|
422 |
+
|
423 |
+
// Determine the discount amount for the item, if there is one
|
424 |
+
foreach ( $discount_values as $discount => $amount ) {
|
425 |
+
|
426 |
+
$item_discount = edd_get_cart_item_discount_amount( $item, $discount );
|
427 |
+
$discount_values[ $discount ] += $item_discount;
|
428 |
+
|
429 |
+
}
|
430 |
+
|
431 |
+
$c++;
|
432 |
+
}
|
433 |
+
|
434 |
+
$sales['sales'][ $i ]['discounts'] = $discount_values;
|
435 |
+
$sales['sales'][ $i ]['products'] = $cart_items;
|
436 |
+
|
437 |
+
$i++;
|
438 |
+
}
|
439 |
+
}
|
440 |
+
return $sales;
|
441 |
+
}
|
442 |
+
|
443 |
+
}
|
includes/api/class-edd-api.php
CHANGED
@@ -140,6 +140,7 @@ class EDD_API {
|
|
140 |
|
141 |
$this->versions = array(
|
142 |
'v1' => 'EDD_API_V1',
|
|
|
143 |
);
|
144 |
|
145 |
foreach( $this->get_versions() as $version => $class ) {
|
@@ -149,10 +150,6 @@ class EDD_API {
|
|
149 |
add_action( 'init', array( $this, 'add_endpoint' ) );
|
150 |
add_action( 'wp', array( $this, 'process_query' ), -1 );
|
151 |
add_filter( 'query_vars', array( $this, 'query_vars' ) );
|
152 |
-
add_action( 'show_user_profile', array( $this, 'user_key_field' ) );
|
153 |
-
add_action( 'edit_user_profile', array( $this, 'user_key_field' ) );
|
154 |
-
add_action( 'personal_options_update', array( $this, 'update_key' ) );
|
155 |
-
add_action( 'edit_user_profile_update', array( $this, 'update_key' ) );
|
156 |
add_action( 'edd_process_api_key', array( $this, 'process_api_key' ) );
|
157 |
|
158 |
// Setup a backwards compatibilty check for user API Keys
|
@@ -197,6 +194,9 @@ class EDD_API {
|
|
197 |
$vars[] = 'query';
|
198 |
$vars[] = 'type';
|
199 |
$vars[] = 'product';
|
|
|
|
|
|
|
200 |
$vars[] = 'number';
|
201 |
$vars[] = 'date';
|
202 |
$vars[] = 'startdate';
|
@@ -311,7 +311,7 @@ class EDD_API {
|
|
311 |
$this->override = false;
|
312 |
|
313 |
// Make sure we have both user and api key
|
314 |
-
if ( ! empty( $wp_query->query_vars['edd-api'] ) && ( $
|
315 |
|
316 |
if ( empty( $wp_query->query_vars['token'] ) || empty( $wp_query->query_vars['key'] ) ) {
|
317 |
$this->missing_auth();
|
@@ -337,13 +337,31 @@ class EDD_API {
|
|
337 |
$this->invalid_auth();
|
338 |
}
|
339 |
}
|
340 |
-
} elseif ( ! empty( $wp_query->query_vars['edd-api'] ) && $
|
341 |
$this->is_valid_request = true;
|
342 |
$wp_query->set( 'key', 'public' );
|
343 |
}
|
344 |
|
345 |
}
|
346 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
347 |
/**
|
348 |
* Retrieve the user ID based on the public key provided
|
349 |
*
|
@@ -502,7 +520,6 @@ class EDD_API {
|
|
502 |
* Listens for the API and then processes the API requests
|
503 |
*
|
504 |
* @access public
|
505 |
-
* @author Daniel J Griffiths
|
506 |
* @global $wp_query
|
507 |
* @since 1.5
|
508 |
* @return void
|
@@ -550,24 +567,35 @@ class EDD_API {
|
|
550 |
'product' => isset( $wp_query->query_vars['product'] ) ? $wp_query->query_vars['product'] : null,
|
551 |
'date' => isset( $wp_query->query_vars['date'] ) ? $wp_query->query_vars['date'] : null,
|
552 |
'startdate' => isset( $wp_query->query_vars['startdate'] ) ? $wp_query->query_vars['startdate'] : null,
|
553 |
-
'enddate' => isset( $wp_query->query_vars['enddate'] ) ? $wp_query->query_vars['enddate'] : null
|
554 |
) );
|
555 |
|
556 |
break;
|
557 |
|
558 |
case 'products' :
|
559 |
|
560 |
-
$
|
|
|
|
|
|
|
|
|
|
|
|
|
561 |
|
562 |
-
$data = $this->routes->get_products( $
|
563 |
|
564 |
break;
|
565 |
|
566 |
case 'customers' :
|
567 |
|
568 |
-
$
|
|
|
|
|
|
|
|
|
|
|
569 |
|
570 |
-
$data = $this->routes->get_customers( $
|
571 |
|
572 |
break;
|
573 |
|
@@ -885,8 +913,10 @@ class EDD_API {
|
|
885 |
*/
|
886 |
public function get_customers( $customer = null ) {
|
887 |
|
|
|
888 |
$customers = array();
|
889 |
-
$error
|
|
|
890 |
if( ! user_can( $this->user_id, 'view_shop_sensitive_data' ) && ! $this->override ) {
|
891 |
return $customers;
|
892 |
}
|
@@ -973,12 +1003,13 @@ class EDD_API {
|
|
973 |
* @param int $product Product (Download) ID
|
974 |
* @return array $customers Multidimensional array of the products
|
975 |
*/
|
976 |
-
public function get_products( $
|
977 |
|
978 |
$products = array();
|
979 |
$error = array();
|
980 |
|
981 |
-
if ( $product
|
|
|
982 |
$products['products'] = array();
|
983 |
|
984 |
$product_list = get_posts( array(
|
@@ -996,13 +1027,14 @@ class EDD_API {
|
|
996 |
}
|
997 |
}
|
998 |
} else {
|
999 |
-
|
1000 |
-
|
|
|
1001 |
|
1002 |
$products['products'][0] = $this->get_product_data( $product_info );
|
1003 |
|
1004 |
} else {
|
1005 |
-
$error['error'] = sprintf( __( 'Product %s not found!', 'easy-digital-downloads' ), $product );
|
1006 |
return $error;
|
1007 |
}
|
1008 |
}
|
@@ -1017,7 +1049,7 @@ class EDD_API {
|
|
1017 |
* @param object $product_info The Download Post Object
|
1018 |
* @return array Array of post data to return back in the API
|
1019 |
*/
|
1020 |
-
|
1021 |
|
1022 |
$product = array();
|
1023 |
|
@@ -1940,23 +1972,7 @@ class EDD_API {
|
|
1940 |
* @return void
|
1941 |
*/
|
1942 |
public function update_key( $user_id ) {
|
1943 |
-
|
1944 |
-
|
1945 |
-
$user = get_userdata( $user_id );
|
1946 |
-
|
1947 |
-
$public_key = $this->get_user_public_key( $user_id );
|
1948 |
-
$secret_key = $this->get_user_secret_key( $user_id );
|
1949 |
-
|
1950 |
-
if ( empty( $public_key ) ) {
|
1951 |
-
$new_public_key = $this->generate_public_key( $user->user_email );
|
1952 |
-
$new_secret_key = $this->generate_private_key( $user->ID );
|
1953 |
-
|
1954 |
-
update_user_meta( $user_id, $new_public_key, 'edd_user_public_key' );
|
1955 |
-
update_user_meta( $user_id, $new_secret_key, 'edd_user_secret_key' );
|
1956 |
-
} else {
|
1957 |
-
$this->revoke_api_key( $user_id );
|
1958 |
-
}
|
1959 |
-
}
|
1960 |
}
|
1961 |
|
1962 |
/**
|
@@ -1967,7 +1983,7 @@ class EDD_API {
|
|
1967 |
* @param string $user_email
|
1968 |
* @return string
|
1969 |
*/
|
1970 |
-
|
1971 |
$auth_key = defined( 'AUTH_KEY' ) ? AUTH_KEY : '';
|
1972 |
$public = hash( 'md5', $user_email . $auth_key . date( 'U' ) );
|
1973 |
return $public;
|
@@ -1981,7 +1997,7 @@ class EDD_API {
|
|
1981 |
* @param int $user_id
|
1982 |
* @return string
|
1983 |
*/
|
1984 |
-
|
1985 |
$auth_key = defined( 'AUTH_KEY' ) ? AUTH_KEY : '';
|
1986 |
$secret = hash( 'md5', $user_id . $auth_key . date( 'U' ) );
|
1987 |
return $secret;
|
@@ -2072,4 +2088,26 @@ class EDD_API {
|
|
2072 |
|
2073 |
}
|
2074 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2075 |
}
|
140 |
|
141 |
$this->versions = array(
|
142 |
'v1' => 'EDD_API_V1',
|
143 |
+
'v2' => 'EDD_API_V2'
|
144 |
);
|
145 |
|
146 |
foreach( $this->get_versions() as $version => $class ) {
|
150 |
add_action( 'init', array( $this, 'add_endpoint' ) );
|
151 |
add_action( 'wp', array( $this, 'process_query' ), -1 );
|
152 |
add_filter( 'query_vars', array( $this, 'query_vars' ) );
|
|
|
|
|
|
|
|
|
153 |
add_action( 'edd_process_api_key', array( $this, 'process_api_key' ) );
|
154 |
|
155 |
// Setup a backwards compatibilty check for user API Keys
|
194 |
$vars[] = 'query';
|
195 |
$vars[] = 'type';
|
196 |
$vars[] = 'product';
|
197 |
+
$vars[] = 'category';
|
198 |
+
$vars[] = 'tag';
|
199 |
+
$vars[] = 'term_relation';
|
200 |
$vars[] = 'number';
|
201 |
$vars[] = 'date';
|
202 |
$vars[] = 'startdate';
|
311 |
$this->override = false;
|
312 |
|
313 |
// Make sure we have both user and api key
|
314 |
+
if ( ! empty( $wp_query->query_vars['edd-api'] ) && ( ! $this->is_public_query() || ! empty( $wp_query->query_vars['token'] ) ) ) {
|
315 |
|
316 |
if ( empty( $wp_query->query_vars['token'] ) || empty( $wp_query->query_vars['key'] ) ) {
|
317 |
$this->missing_auth();
|
337 |
$this->invalid_auth();
|
338 |
}
|
339 |
}
|
340 |
+
} elseif ( ! empty( $wp_query->query_vars['edd-api'] ) && $this->is_public_query() ) {
|
341 |
$this->is_valid_request = true;
|
342 |
$wp_query->set( 'key', 'public' );
|
343 |
}
|
344 |
|
345 |
}
|
346 |
|
347 |
+
/**
|
348 |
+
* Return whether this is a public query.
|
349 |
+
*
|
350 |
+
* @access private
|
351 |
+
* @global object $wp_query WordPress Query
|
352 |
+
* @since 2.6
|
353 |
+
* @return boolean
|
354 |
+
*/
|
355 |
+
private function is_public_query() {
|
356 |
+
global $wp_query;
|
357 |
+
|
358 |
+
$public_modes = apply_filters( 'edd_api_public_query_modes', array(
|
359 |
+
'products'
|
360 |
+
) );
|
361 |
+
|
362 |
+
return in_array( $wp_query->query_vars['edd-api'], $public_modes );
|
363 |
+
}
|
364 |
+
|
365 |
/**
|
366 |
* Retrieve the user ID based on the public key provided
|
367 |
*
|
520 |
* Listens for the API and then processes the API requests
|
521 |
*
|
522 |
* @access public
|
|
|
523 |
* @global $wp_query
|
524 |
* @since 1.5
|
525 |
* @return void
|
567 |
'product' => isset( $wp_query->query_vars['product'] ) ? $wp_query->query_vars['product'] : null,
|
568 |
'date' => isset( $wp_query->query_vars['date'] ) ? $wp_query->query_vars['date'] : null,
|
569 |
'startdate' => isset( $wp_query->query_vars['startdate'] ) ? $wp_query->query_vars['startdate'] : null,
|
570 |
+
'enddate' => isset( $wp_query->query_vars['enddate'] ) ? $wp_query->query_vars['enddate'] : null,
|
571 |
) );
|
572 |
|
573 |
break;
|
574 |
|
575 |
case 'products' :
|
576 |
|
577 |
+
$args = array(
|
578 |
+
'product' => isset( $wp_query->query_vars['product'] ) ? absint( $wp_query->query_vars['product'] ) : null,
|
579 |
+
'category' => isset( $wp_query->query_vars['category'] ) ? $this->sanitize_request_term( $wp_query->query_vars['category'] ) : null,
|
580 |
+
'tag' => isset( $wp_query->query_vars['tag'] ) ? $this->sanitize_request_term( $wp_query->query_vars['tag'] ) : null,
|
581 |
+
'term_relation' => isset( $wp_query->query_vars['term_relation'] ) ? $this->sanitize_request_term( $wp_query->query_vars['term_relation'] ) : null,
|
582 |
+
's' => isset( $wp_query->query_vars['s'] ) ? sanitize_text_field( $wp_query->query_vars['s'] ) : null,
|
583 |
+
);
|
584 |
|
585 |
+
$data = $this->routes->get_products( $args );
|
586 |
|
587 |
break;
|
588 |
|
589 |
case 'customers' :
|
590 |
|
591 |
+
$args = array(
|
592 |
+
'customer' => isset( $wp_query->query_vars['customer'] ) ? $wp_query->query_vars['customer'] : null,
|
593 |
+
'date' => isset( $wp_query->query_vars['date'] ) ? $wp_query->query_vars['date'] : null,
|
594 |
+
'startdate' => isset( $wp_query->query_vars['startdate'] ) ? $wp_query->query_vars['startdate'] : null,
|
595 |
+
'enddate' => isset( $wp_query->query_vars['enddate'] ) ? $wp_query->query_vars['enddate'] : null,
|
596 |
+
);
|
597 |
|
598 |
+
$data = $this->routes->get_customers( $args );
|
599 |
|
600 |
break;
|
601 |
|
913 |
*/
|
914 |
public function get_customers( $customer = null ) {
|
915 |
|
916 |
+
$customer = is_array( $customer ) ? $customer['customer'] : $customer;
|
917 |
$customers = array();
|
918 |
+
$error = array();
|
919 |
+
|
920 |
if( ! user_can( $this->user_id, 'view_shop_sensitive_data' ) && ! $this->override ) {
|
921 |
return $customers;
|
922 |
}
|
1003 |
* @param int $product Product (Download) ID
|
1004 |
* @return array $customers Multidimensional array of the products
|
1005 |
*/
|
1006 |
+
public function get_products( $args = array() ) {
|
1007 |
|
1008 |
$products = array();
|
1009 |
$error = array();
|
1010 |
|
1011 |
+
if ( empty( $args['product'] ) ) {
|
1012 |
+
|
1013 |
$products['products'] = array();
|
1014 |
|
1015 |
$product_list = get_posts( array(
|
1027 |
}
|
1028 |
}
|
1029 |
} else {
|
1030 |
+
|
1031 |
+
if ( get_post_type( $args['product'] ) == 'download' ) {
|
1032 |
+
$product_info = get_post( $args['product'] );
|
1033 |
|
1034 |
$products['products'][0] = $this->get_product_data( $product_info );
|
1035 |
|
1036 |
} else {
|
1037 |
+
$error['error'] = sprintf( __( 'Product %s not found!', 'easy-digital-downloads' ), $args['product'] );
|
1038 |
return $error;
|
1039 |
}
|
1040 |
}
|
1049 |
* @param object $product_info The Download Post Object
|
1050 |
* @return array Array of post data to return back in the API
|
1051 |
*/
|
1052 |
+
public function get_product_data( $product_info ) {
|
1053 |
|
1054 |
$product = array();
|
1055 |
|
1972 |
* @return void
|
1973 |
*/
|
1974 |
public function update_key( $user_id ) {
|
1975 |
+
edd_update_user_api_key( $user_id );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1976 |
}
|
1977 |
|
1978 |
/**
|
1983 |
* @param string $user_email
|
1984 |
* @return string
|
1985 |
*/
|
1986 |
+
public function generate_public_key( $user_email = '' ) {
|
1987 |
$auth_key = defined( 'AUTH_KEY' ) ? AUTH_KEY : '';
|
1988 |
$public = hash( 'md5', $user_email . $auth_key . date( 'U' ) );
|
1989 |
return $public;
|
1997 |
* @param int $user_id
|
1998 |
* @return string
|
1999 |
*/
|
2000 |
+
public function generate_private_key( $user_id = 0 ) {
|
2001 |
$auth_key = defined( 'AUTH_KEY' ) ? AUTH_KEY : '';
|
2002 |
$secret = hash( 'md5', $user_id . $auth_key . date( 'U' ) );
|
2003 |
return $secret;
|
2088 |
|
2089 |
}
|
2090 |
|
2091 |
+
/**
|
2092 |
+
* Sanitizes category and tag terms
|
2093 |
+
*
|
2094 |
+
* @access private
|
2095 |
+
* @since 2.6
|
2096 |
+
* @param mixed $term Request variable
|
2097 |
+
* @return mixed Sanitized term/s
|
2098 |
+
*/
|
2099 |
+
public function sanitize_request_term( $term ) {
|
2100 |
+
|
2101 |
+
if( is_array( $term ) ) {
|
2102 |
+
$term = array_map( 'sanitize_text_field', $term );
|
2103 |
+
} else if( is_int( $term ) ) {
|
2104 |
+
$term = absint( $term );
|
2105 |
+
} else {
|
2106 |
+
$term = sanitize_text_field( $term );
|
2107 |
+
}
|
2108 |
+
|
2109 |
+
return $term;
|
2110 |
+
|
2111 |
+
}
|
2112 |
+
|
2113 |
}
|
includes/cart/functions.php
CHANGED
@@ -54,12 +54,21 @@ function edd_get_cart_content_details() {
|
|
54 |
|
55 |
$item['quantity'] = edd_item_quantities_enabled() ? absint( $item['quantity'] ) : 1;
|
56 |
|
|
|
|
|
57 |
$item_price = edd_get_cart_item_price( $item['id'], $item['options'] );
|
58 |
$discount = edd_get_cart_item_discount_amount( $item );
|
59 |
$discount = apply_filters( 'edd_get_cart_content_details_item_discount_amount', $discount, $item );
|
60 |
$quantity = edd_get_cart_item_quantity( $item['id'], $item['options'] );
|
61 |
-
$fees = edd_get_cart_fees( 'fee', $item['id'] );
|
62 |
$subtotal = $item_price * $quantity;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
63 |
$tax = edd_get_cart_item_tax( $item['id'], $item['options'], $subtotal - $discount );
|
64 |
|
65 |
if( edd_prices_include_tax() ) {
|
@@ -477,11 +486,11 @@ function edd_get_cart_item_price( $download_id = 0, $options = array(), $remove_
|
|
477 |
// Get the standard Download price if not using variable prices
|
478 |
$price = edd_get_download_price( $download_id );
|
479 |
}
|
480 |
-
|
481 |
if ( $remove_tax_from_inclusive && edd_prices_include_tax() ) {
|
482 |
|
483 |
$price -= edd_get_cart_item_tax( $download_id, $options, $price );
|
484 |
-
}
|
485 |
|
486 |
return apply_filters( 'edd_cart_item_price', $price, $download_id, $options );
|
487 |
}
|
@@ -522,6 +531,8 @@ function edd_get_cart_item_tax( $download_id = 0, $options = array(), $subtotal
|
|
522 |
|
523 |
}
|
524 |
|
|
|
|
|
525 |
return apply_filters( 'edd_get_cart_item_tax', $tax, $download_id, $options, $subtotal );
|
526 |
}
|
527 |
|
@@ -702,14 +713,16 @@ function edd_get_cart_items_subtotal( $items ) {
|
|
702 |
* @return float Cart amount
|
703 |
*/
|
704 |
function edd_get_cart_total( $discounts = false ) {
|
705 |
-
$subtotal
|
706 |
-
$discounts
|
707 |
-
$
|
708 |
-
$
|
709 |
-
$
|
710 |
-
|
711 |
-
|
|
|
712 |
$total = 0.00;
|
|
|
713 |
|
714 |
return (float) apply_filters( 'edd_get_cart_total', $total );
|
715 |
}
|
@@ -763,8 +776,9 @@ function edd_cart_has_fees( $type = 'all' ) {
|
|
763 |
* @uses EDD()->fees->get_fees()
|
764 |
* @return array All the cart fees that have been applied
|
765 |
*/
|
766 |
-
function edd_get_cart_fees( $type = 'all', $download_id = 0 ) {
|
767 |
-
|
|
|
768 |
}
|
769 |
|
770 |
/**
|
@@ -777,7 +791,19 @@ function edd_get_cart_fees( $type = 'all', $download_id = 0 ) {
|
|
777 |
* @return float Total Cart Fees
|
778 |
*/
|
779 |
function edd_get_cart_fee_total() {
|
780 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
781 |
}
|
782 |
|
783 |
/**
|
@@ -796,7 +822,7 @@ function edd_get_cart_fee_tax() {
|
|
796 |
|
797 |
foreach ( $fees as $fee_id => $fee ) {
|
798 |
|
799 |
-
if( ! empty( $fee['no_tax'] ) ) {
|
800 |
continue;
|
801 |
}
|
802 |
|
@@ -851,8 +877,8 @@ function edd_get_purchase_summary( $purchase_data, $email = true ) {
|
|
851 |
*/
|
852 |
function edd_get_cart_tax() {
|
853 |
|
854 |
-
$cart_tax
|
855 |
-
$items
|
856 |
|
857 |
if( $items ) {
|
858 |
|
@@ -884,6 +910,8 @@ function edd_cart_tax( $echo = false ) {
|
|
884 |
$cart_tax = edd_currency_filter( edd_format_amount( $cart_tax ) );
|
885 |
}
|
886 |
|
|
|
|
|
887 |
$tax = apply_filters( 'edd_cart_tax', $cart_tax );
|
888 |
|
889 |
if ( ! $echo ) {
|
54 |
|
55 |
$item['quantity'] = edd_item_quantities_enabled() ? absint( $item['quantity'] ) : 1;
|
56 |
|
57 |
+
$price_id = isset( $item['options']['price_id'] ) ? $item['options']['price_id'] : NULL;
|
58 |
+
|
59 |
$item_price = edd_get_cart_item_price( $item['id'], $item['options'] );
|
60 |
$discount = edd_get_cart_item_discount_amount( $item );
|
61 |
$discount = apply_filters( 'edd_get_cart_content_details_item_discount_amount', $discount, $item );
|
62 |
$quantity = edd_get_cart_item_quantity( $item['id'], $item['options'] );
|
63 |
+
$fees = edd_get_cart_fees( 'fee', $item['id'], $price_id );
|
64 |
$subtotal = $item_price * $quantity;
|
65 |
+
|
66 |
+
foreach ( $fees as $fee ) {
|
67 |
+
if ( $fee['amount'] < 0 ) {
|
68 |
+
$subtotal += $fee['amount'];
|
69 |
+
}
|
70 |
+
}
|
71 |
+
|
72 |
$tax = edd_get_cart_item_tax( $item['id'], $item['options'], $subtotal - $discount );
|
73 |
|
74 |
if( edd_prices_include_tax() ) {
|
486 |
// Get the standard Download price if not using variable prices
|
487 |
$price = edd_get_download_price( $download_id );
|
488 |
}
|
489 |
+
|
490 |
if ( $remove_tax_from_inclusive && edd_prices_include_tax() ) {
|
491 |
|
492 |
$price -= edd_get_cart_item_tax( $download_id, $options, $price );
|
493 |
+
}
|
494 |
|
495 |
return apply_filters( 'edd_cart_item_price', $price, $download_id, $options );
|
496 |
}
|
531 |
|
532 |
}
|
533 |
|
534 |
+
$tax = max( $tax, 0 );
|
535 |
+
|
536 |
return apply_filters( 'edd_get_cart_item_tax', $tax, $download_id, $options, $subtotal );
|
537 |
}
|
538 |
|
713 |
* @return float Cart amount
|
714 |
*/
|
715 |
function edd_get_cart_total( $discounts = false ) {
|
716 |
+
$subtotal = (float) edd_get_cart_subtotal();
|
717 |
+
$discounts = (float) edd_get_cart_discounted_amount();
|
718 |
+
$fees = (float) edd_get_cart_fee_total();
|
719 |
+
$cart_tax = (float) edd_get_cart_tax();
|
720 |
+
$total_wo_tax = $subtotal - $discounts + $fees;
|
721 |
+
$total = $subtotal - $discounts + $cart_tax + $fees;
|
722 |
+
|
723 |
+
if( $total < 0 || ! $total_wo_tax > 0 ) {
|
724 |
$total = 0.00;
|
725 |
+
}
|
726 |
|
727 |
return (float) apply_filters( 'edd_get_cart_total', $total );
|
728 |
}
|
776 |
* @uses EDD()->fees->get_fees()
|
777 |
* @return array All the cart fees that have been applied
|
778 |
*/
|
779 |
+
function edd_get_cart_fees( $type = 'all', $download_id = 0, $price_id = NULL ) {
|
780 |
+
|
781 |
+
return EDD()->fees->get_fees( $type, $download_id, $price_id );
|
782 |
}
|
783 |
|
784 |
/**
|
791 |
* @return float Total Cart Fees
|
792 |
*/
|
793 |
function edd_get_cart_fee_total() {
|
794 |
+
$fees = EDD()->fees->get_fees( 'all' );
|
795 |
+
|
796 |
+
$fee_total = 0.00;
|
797 |
+
foreach ( $fees as $fee ) {
|
798 |
+
if ( ! empty( $fee['download_id'] ) && $fee['amount'] <= 0 ) {
|
799 |
+
continue;
|
800 |
+
}
|
801 |
+
|
802 |
+
$fee_total += $fee['amount'];
|
803 |
+
|
804 |
+
}
|
805 |
+
|
806 |
+
return apply_filters( 'edd_get_fee_total', $fee_total, $fees );
|
807 |
}
|
808 |
|
809 |
/**
|
822 |
|
823 |
foreach ( $fees as $fee_id => $fee ) {
|
824 |
|
825 |
+
if( ! empty( $fee['no_tax'] ) || $fee['amount'] < 0 ) {
|
826 |
continue;
|
827 |
}
|
828 |
|
877 |
*/
|
878 |
function edd_get_cart_tax() {
|
879 |
|
880 |
+
$cart_tax = 0;
|
881 |
+
$items = edd_get_cart_content_details();
|
882 |
|
883 |
if( $items ) {
|
884 |
|
910 |
$cart_tax = edd_currency_filter( edd_format_amount( $cart_tax ) );
|
911 |
}
|
912 |
|
913 |
+
$tax = max( $cart_tax, 0 );
|
914 |
+
|
915 |
$tax = apply_filters( 'edd_cart_tax', $cart_tax );
|
916 |
|
917 |
if ( ! $echo ) {
|
includes/checkout/functions.php
CHANGED
@@ -60,11 +60,17 @@ function edd_can_checkout() {
|
|
60 |
* @since 1.6
|
61 |
* @return string
|
62 |
*/
|
63 |
-
function edd_get_success_page_uri() {
|
64 |
$page_id = edd_get_option( 'success_page', 0 );
|
65 |
$page_id = absint( $page_id );
|
66 |
|
67 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
68 |
}
|
69 |
|
70 |
/**
|
@@ -166,26 +172,6 @@ function edd_send_back_to_checkout( $args = array() ) {
|
|
166 |
edd_die();
|
167 |
}
|
168 |
|
169 |
-
/**
|
170 |
-
* Get Success Page URL
|
171 |
-
*
|
172 |
-
* Gets the success page URL.
|
173 |
-
*
|
174 |
-
* @param string $query_string
|
175 |
-
* @access public
|
176 |
-
* @since 1.0
|
177 |
-
* @return string
|
178 |
-
*/
|
179 |
-
function edd_get_success_page_url( $query_string = null ) {
|
180 |
-
$success_page = edd_get_option( 'success_page', 0 );
|
181 |
-
$success_page = get_permalink( $success_page );
|
182 |
-
|
183 |
-
if ( $query_string )
|
184 |
-
$success_page .= $query_string;
|
185 |
-
|
186 |
-
return apply_filters( 'edd_success_page_url', $success_page );
|
187 |
-
}
|
188 |
-
|
189 |
/**
|
190 |
* Get the URL of the Transaction Failed page
|
191 |
*
|
60 |
* @since 1.6
|
61 |
* @return string
|
62 |
*/
|
63 |
+
function edd_get_success_page_uri( $query_string = null ) {
|
64 |
$page_id = edd_get_option( 'success_page', 0 );
|
65 |
$page_id = absint( $page_id );
|
66 |
|
67 |
+
$success_page = get_permalink( $page_id );
|
68 |
+
|
69 |
+
if ( $query_string ) {
|
70 |
+
$success_page .= $query_string;
|
71 |
+
}
|
72 |
+
|
73 |
+
return apply_filters( 'edd_get_success_page_uri', $success_page );
|
74 |
}
|
75 |
|
76 |
/**
|
172 |
edd_die();
|
173 |
}
|
174 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
175 |
/**
|
176 |
* Get the URL of the Transaction Failed page
|
177 |
*
|
includes/checkout/template.php
CHANGED
@@ -173,7 +173,7 @@ function edd_user_info_fields() {
|
|
173 |
$customer = array_map( 'sanitize_text_field', $customer );
|
174 |
?>
|
175 |
<fieldset id="edd_checkout_user_info">
|
176 |
-
<
|
177 |
<?php do_action( 'edd_purchase_form_before_email' ); ?>
|
178 |
<p id="edd-email-wrap">
|
179 |
<label class="edd-label" for="edd-email">
|
@@ -226,7 +226,7 @@ function edd_get_cc_form() {
|
|
226 |
<?php do_action( 'edd_before_cc_fields' ); ?>
|
227 |
|
228 |
<fieldset id="edd_cc_fields" class="edd-do-validate">
|
229 |
-
<
|
230 |
<?php if( is_ssl() ) : ?>
|
231 |
<div id="edd_secure_site_wrapper">
|
232 |
<span class="padlock"></span>
|
@@ -240,7 +240,7 @@ function edd_get_cc_form() {
|
|
240 |
<span class="card-type"></span>
|
241 |
</label>
|
242 |
<span class="edd-description"><?php _e( 'The (typically) 16 digits on the front of your credit card.', 'easy-digital-downloads' ); ?></span>
|
243 |
-
<input type="
|
244 |
</p>
|
245 |
<p id="edd-card-cvc-wrap">
|
246 |
<label for="card_cvc" class="edd-label">
|
@@ -248,7 +248,7 @@ function edd_get_cc_form() {
|
|
248 |
<span class="edd-required-indicator">*</span>
|
249 |
</label>
|
250 |
<span class="edd-description"><?php _e( 'The 3 digit (back) or 4 digit (front) value on your card.', 'easy-digital-downloads' ); ?></span>
|
251 |
-
<input type="
|
252 |
</p>
|
253 |
<p id="edd-card-name-wrap">
|
254 |
<label for="card_name" class="edd-label">
|
@@ -322,7 +322,7 @@ function edd_default_cc_address_fields() {
|
|
322 |
|
323 |
ob_start(); ?>
|
324 |
<fieldset id="edd_cc_address" class="cc-address">
|
325 |
-
<
|
326 |
<?php do_action( 'edd_cc_billing_top' ); ?>
|
327 |
<p id="edd-card-address-wrap">
|
328 |
<label for="card_address" class="edd-label">
|
@@ -459,7 +459,7 @@ function edd_get_register_fields() {
|
|
459 |
<?php do_action('edd_register_fields_before'); ?>
|
460 |
|
461 |
<fieldset id="edd_register_account_fields">
|
462 |
-
<
|
463 |
<?php do_action('edd_register_account_fields_before'); ?>
|
464 |
<p id="edd-user-login-wrap">
|
465 |
<label for="edd_user_login">
|
@@ -469,7 +469,7 @@ function edd_get_register_fields() {
|
|
469 |
<?php } ?>
|
470 |
</label>
|
471 |
<span class="edd-description"><?php _e( 'The username you will use to log into your account.', 'easy-digital-downloads' ); ?></span>
|
472 |
-
<input name="edd_user_login" id="edd_user_login" class="<?php if(edd_no_guest_checkout()) { echo 'required '; } ?>edd-input" type="text" placeholder="<?php _e( 'Username', 'easy-digital-downloads' ); ?>"
|
473 |
</p>
|
474 |
<p id="edd-user-pass-wrap">
|
475 |
<label for="edd_user_pass">
|
@@ -775,7 +775,7 @@ function edd_checkout_final_total() {
|
|
775 |
?>
|
776 |
<p id="edd_final_total_wrap">
|
777 |
<strong><?php _e( 'Purchase Total:', 'easy-digital-downloads' ); ?></strong>
|
778 |
-
<span class="edd_cart_amount" data-subtotal="<?php echo edd_get_cart_subtotal(); ?>" data-total="<?php echo
|
779 |
</p>
|
780 |
<?php
|
781 |
}
|
173 |
$customer = array_map( 'sanitize_text_field', $customer );
|
174 |
?>
|
175 |
<fieldset id="edd_checkout_user_info">
|
176 |
+
<legend><?php echo apply_filters( 'edd_checkout_personal_info_text', __( 'Personal Info', 'easy-digital-downloads' ) ); ?></legend>
|
177 |
<?php do_action( 'edd_purchase_form_before_email' ); ?>
|
178 |
<p id="edd-email-wrap">
|
179 |
<label class="edd-label" for="edd-email">
|
226 |
<?php do_action( 'edd_before_cc_fields' ); ?>
|
227 |
|
228 |
<fieldset id="edd_cc_fields" class="edd-do-validate">
|
229 |
+
<legend><?php _e( 'Credit Card Info', 'easy-digital-downloads' ); ?></legend>
|
230 |
<?php if( is_ssl() ) : ?>
|
231 |
<div id="edd_secure_site_wrapper">
|
232 |
<span class="padlock"></span>
|
240 |
<span class="card-type"></span>
|
241 |
</label>
|
242 |
<span class="edd-description"><?php _e( 'The (typically) 16 digits on the front of your credit card.', 'easy-digital-downloads' ); ?></span>
|
243 |
+
<input type="tel" pattern="[0-9]{13,16}" autocomplete="off" name="card_number" id="card_number" class="card-number edd-input required" placeholder="<?php _e( 'Card number', 'easy-digital-downloads' ); ?>" />
|
244 |
</p>
|
245 |
<p id="edd-card-cvc-wrap">
|
246 |
<label for="card_cvc" class="edd-label">
|
248 |
<span class="edd-required-indicator">*</span>
|
249 |
</label>
|
250 |
<span class="edd-description"><?php _e( 'The 3 digit (back) or 4 digit (front) value on your card.', 'easy-digital-downloads' ); ?></span>
|
251 |
+
<input type="tel" pattern="[0-9]{3,4}" size="4" maxlength="4" autocomplete="off" name="card_cvc" id="card_cvc" class="card-cvc edd-input required" placeholder="<?php _e( 'Security code', 'easy-digital-downloads' ); ?>" />
|
252 |
</p>
|
253 |
<p id="edd-card-name-wrap">
|
254 |
<label for="card_name" class="edd-label">
|
322 |
|
323 |
ob_start(); ?>
|
324 |
<fieldset id="edd_cc_address" class="cc-address">
|
325 |
+
<legend><?php _e( 'Billing Details', 'easy-digital-downloads' ); ?></legend>
|
326 |
<?php do_action( 'edd_cc_billing_top' ); ?>
|
327 |
<p id="edd-card-address-wrap">
|
328 |
<label for="card_address" class="edd-label">
|
459 |
<?php do_action('edd_register_fields_before'); ?>
|
460 |
|
461 |
<fieldset id="edd_register_account_fields">
|
462 |
+
<legend><?php _e( 'Create an account', 'easy-digital-downloads' ); if( !edd_no_guest_checkout() ) { echo ' ' . __( '(optional)', 'easy-digital-downloads' ); } ?></legend>
|
463 |
<?php do_action('edd_register_account_fields_before'); ?>
|
464 |
<p id="edd-user-login-wrap">
|
465 |
<label for="edd_user_login">
|
469 |
<?php } ?>
|
470 |
</label>
|
471 |
<span class="edd-description"><?php _e( 'The username you will use to log into your account.', 'easy-digital-downloads' ); ?></span>
|
472 |
+
<input name="edd_user_login" id="edd_user_login" class="<?php if(edd_no_guest_checkout()) { echo 'required '; } ?>edd-input" type="text" placeholder="<?php _e( 'Username', 'easy-digital-downloads' ); ?>"/>
|
473 |
</p>
|
474 |
<p id="edd-user-pass-wrap">
|
475 |
<label for="edd_user_pass">
|
775 |
?>
|
776 |
<p id="edd_final_total_wrap">
|
777 |
<strong><?php _e( 'Purchase Total:', 'easy-digital-downloads' ); ?></strong>
|
778 |
+
<span class="edd_cart_amount" data-subtotal="<?php echo edd_get_cart_subtotal(); ?>" data-total="<?php echo edd_get_cart_total(); ?>"><?php edd_cart_total(); ?></span>
|
779 |
</p>
|
780 |
<?php
|
781 |
}
|
includes/class-edd-cli.php
CHANGED
@@ -60,7 +60,7 @@ class EDD_CLI extends WP_CLI_Command {
|
|
60 |
|
61 |
WP_CLI::line( sprintf( __( 'You are running EDD version: %s', 'easy-digital-downloads' ), EDD_VERSION ) );
|
62 |
WP_CLI::line( "\n" . sprintf( __( 'Test mode is: %s', 'easy-digital-downloads' ), ( edd_is_test_mode() ? __( 'Enabled', 'easy-digital-downloads' ) : __( 'Disabled', 'easy-digital-downloads' ) ) ) );
|
63 |
-
WP_CLI::line( sprintf( __( '
|
64 |
WP_CLI::line( sprintf( __( 'Guest checkouts are: %s', 'easy-digital-downloads' ), ( edd_no_guest_checkout() ? __( 'Disabled', 'easy-digital-downloads' ) : __( 'Enabled', 'easy-digital-downloads' ) ) ) );
|
65 |
WP_CLI::line( sprintf( __( 'Symlinks are: %s', 'easy-digital-downloads' ), ( apply_filters( 'edd_symlink_file_downloads', isset( $symlink_file_downloads ) ) && function_exists( 'symlink' ) ? __( 'Enabled', 'easy-digital-downloads' ) : __( 'Disabled', 'easy-digital-downloads' ) ) ) );
|
66 |
WP_CLI::line( "\n" . sprintf( __( 'Checkout page is: %s', 'easy-digital-downloads' ), ( ! edd_get_option( 'purchase_page', false ) ) ? __( 'Valid', 'easy-digital-downloads' ) : __( 'Invalid', 'easy-digital-downloads' ) ) );
|
60 |
|
61 |
WP_CLI::line( sprintf( __( 'You are running EDD version: %s', 'easy-digital-downloads' ), EDD_VERSION ) );
|
62 |
WP_CLI::line( "\n" . sprintf( __( 'Test mode is: %s', 'easy-digital-downloads' ), ( edd_is_test_mode() ? __( 'Enabled', 'easy-digital-downloads' ) : __( 'Disabled', 'easy-digital-downloads' ) ) ) );
|
63 |
+
WP_CLI::line( sprintf( __( 'AJAX is: %s', 'easy-digital-downloads' ), ( edd_is_ajax_enabled() ? __( 'Enabled', 'easy-digital-downloads' ) : __( 'Disabled', 'easy-digital-downloads' ) ) ) );
|
64 |
WP_CLI::line( sprintf( __( 'Guest checkouts are: %s', 'easy-digital-downloads' ), ( edd_no_guest_checkout() ? __( 'Disabled', 'easy-digital-downloads' ) : __( 'Enabled', 'easy-digital-downloads' ) ) ) );
|
65 |
WP_CLI::line( sprintf( __( 'Symlinks are: %s', 'easy-digital-downloads' ), ( apply_filters( 'edd_symlink_file_downloads', isset( $symlink_file_downloads ) ) && function_exists( 'symlink' ) ? __( 'Enabled', 'easy-digital-downloads' ) : __( 'Disabled', 'easy-digital-downloads' ) ) ) );
|
66 |
WP_CLI::line( "\n" . sprintf( __( 'Checkout page is: %s', 'easy-digital-downloads' ), ( ! edd_get_option( 'purchase_page', false ) ) ? __( 'Valid', 'easy-digital-downloads' ) : __( 'Invalid', 'easy-digital-downloads' ) ) );
|
includes/class-edd-customer.php
CHANGED
@@ -41,12 +41,19 @@ class EDD_Customer {
|
|
41 |
public $purchase_value = 0;
|
42 |
|
43 |
/**
|
44 |
-
* The customer's email
|
45 |
*
|
46 |
* @since 2.3
|
47 |
*/
|
48 |
public $email;
|
49 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
50 |
/**
|
51 |
* The customer's name
|
52 |
*
|
@@ -113,6 +120,7 @@ class EDD_Customer {
|
|
113 |
$customer = $this->db->get_customer_by( $field, $_id_or_email );
|
114 |
|
115 |
if ( empty( $customer ) || ! is_object( $customer ) ) {
|
|
|
116 |
return false;
|
117 |
}
|
118 |
|
@@ -149,6 +157,9 @@ class EDD_Customer {
|
|
149 |
|
150 |
}
|
151 |
|
|
|
|
|
|
|
152 |
// Customer ID and email are the only things that are necessary, make sure they exist
|
153 |
if ( ! empty( $this->id ) && ! empty( $this->email ) ) {
|
154 |
return true;
|
@@ -270,6 +281,164 @@ class EDD_Customer {
|
|
270 |
return $updated;
|
271 |
}
|
272 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
273 |
|
274 |
/**
|
275 |
* Attach payment to the customer then triggers increasing stats
|
@@ -460,16 +629,17 @@ class EDD_Customer {
|
|
460 |
* @return mixed If successful, the new value, otherwise false
|
461 |
*/
|
462 |
public function increase_value( $value = 0.00 ) {
|
|
|
463 |
|
464 |
$new_value = floatval( $this->purchase_value ) + $value;
|
465 |
|
466 |
-
do_action( 'edd_customer_pre_increase_value', $value, $this->id );
|
467 |
|
468 |
if ( $this->update( array( 'purchase_value' => $new_value ) ) ) {
|
469 |
$this->purchase_value = $new_value;
|
470 |
}
|
471 |
|
472 |
-
do_action( 'edd_customer_post_increase_value', $this->purchase_value, $value, $this->id );
|
473 |
|
474 |
return $this->purchase_value;
|
475 |
}
|
@@ -482,6 +652,7 @@ class EDD_Customer {
|
|
482 |
* @return mixed If successful, the new value, otherwise false
|
483 |
*/
|
484 |
public function decrease_value( $value = 0.00 ) {
|
|
|
485 |
|
486 |
$new_value = floatval( $this->purchase_value ) - $value;
|
487 |
|
@@ -489,13 +660,13 @@ class EDD_Customer {
|
|
489 |
$new_value = 0.00;
|
490 |
}
|
491 |
|
492 |
-
do_action( 'edd_customer_pre_decrease_value', $value, $this->id );
|
493 |
|
494 |
if ( $this->update( array( 'purchase_value' => $new_value ) ) ) {
|
495 |
$this->purchase_value = $new_value;
|
496 |
}
|
497 |
|
498 |
-
do_action( 'edd_customer_post_decrease_value', $this->purchase_value, $value, $this->id );
|
499 |
|
500 |
return $this->purchase_value;
|
501 |
}
|
@@ -590,6 +761,64 @@ class EDD_Customer {
|
|
590 |
|
591 |
}
|
592 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
593 |
/**
|
594 |
* Sanitize the data for update/create
|
595 |
*
|
41 |
public $purchase_value = 0;
|
42 |
|
43 |
/**
|
44 |
+
* The customer's primary email
|
45 |
*
|
46 |
* @since 2.3
|
47 |
*/
|
48 |
public $email;
|
49 |
|
50 |
+
/**
|
51 |
+
* The customer's emails
|
52 |
+
*
|
53 |
+
* @since 2.6
|
54 |
+
*/
|
55 |
+
public $emails;
|
56 |
+
|
57 |
/**
|
58 |
* The customer's name
|
59 |
*
|
120 |
$customer = $this->db->get_customer_by( $field, $_id_or_email );
|
121 |
|
122 |
if ( empty( $customer ) || ! is_object( $customer ) ) {
|
123 |
+
|
124 |
return false;
|
125 |
}
|
126 |
|
157 |
|
158 |
}
|
159 |
|
160 |
+
$this->emails = (array) $this->get_meta( 'additional_email', false );
|
161 |
+
$this->emails[] = $this->email;
|
162 |
+
|
163 |
// Customer ID and email are the only things that are necessary, make sure they exist
|
164 |
if ( ! empty( $this->id ) && ! empty( $this->email ) ) {
|
165 |
return true;
|
281 |
return $updated;
|
282 |
}
|
283 |
|
284 |
+
/**
|
285 |
+
* Attach an email to the customer
|
286 |
+
*
|
287 |
+
* @since 2.6
|
288 |
+
* @param string $email The email address to remove from the customer
|
289 |
+
* @param bool $primary Allows setting the email added as the primary
|
290 |
+
* @return bool If the email was added successfully
|
291 |
+
*/
|
292 |
+
public function add_email( $email = '', $primary = false ) {
|
293 |
+
|
294 |
+
if( ! is_email( $email ) ) {
|
295 |
+
return false;
|
296 |
+
}
|
297 |
+
|
298 |
+
$existing = new EDD_Customer( $email );
|
299 |
+
|
300 |
+
if( $existing->id > 0 ) {
|
301 |
+
// Email address already belongs to a customer
|
302 |
+
return false;
|
303 |
+
}
|
304 |
+
|
305 |
+
if ( email_exists( $email ) ) {
|
306 |
+
$user = get_user_by( 'email', $email );
|
307 |
+
if ( $user->ID != $this->user_id ) {
|
308 |
+
return false;
|
309 |
+
}
|
310 |
+
}
|
311 |
+
|
312 |
+
do_action( 'edd_customer_pre_add_email', $email, $this->id, $this );
|
313 |
+
|
314 |
+
// Update is used to ensure duplicate emails are not added
|
315 |
+
$ret = (bool) $this->add_meta( 'additional_email', $email );
|
316 |
+
|
317 |
+
do_action( 'edd_customer_post_add_email', $email, $this->id, $this );
|
318 |
+
|
319 |
+
if ( $ret && true === $primary ) {
|
320 |
+
$this->set_primary_email( $email );
|
321 |
+
}
|
322 |
+
|
323 |
+
return $ret;
|
324 |
+
|
325 |
+
}
|
326 |
+
|
327 |
+
/**
|
328 |
+
* Remove an email from the customer
|
329 |
+
*
|
330 |
+
* @since 2.6
|
331 |
+
* @param string $email The email address to remove from the customer
|
332 |
+
* @return bool If the email was removeed successfully
|
333 |
+
*/
|
334 |
+
public function remove_email( $email = '' ) {
|
335 |
+
|
336 |
+
if( ! is_email( $email ) ) {
|
337 |
+
return false;
|
338 |
+
}
|
339 |
+
|
340 |
+
do_action( 'edd_customer_pre_remove_email', $email, $this->id, $this );
|
341 |
+
|
342 |
+
$ret = (bool) $this->delete_meta( 'additional_email', $email );
|
343 |
+
|
344 |
+
do_action( 'edd_customer_post_remove_email', $email, $this->id, $this );
|
345 |
+
|
346 |
+
return $ret;
|
347 |
+
|
348 |
+
}
|
349 |
+
|
350 |
+
/**
|
351 |
+
* Set an email address as the customer's primary email
|
352 |
+
*
|
353 |
+
* This will move the customer's previous primary email to an additional email
|
354 |
+
*
|
355 |
+
* @since 2.6
|
356 |
+
* @param string $new_primary_email The email address to remove from the customer
|
357 |
+
* @return bool If the email was set as primary successfully
|
358 |
+
*/
|
359 |
+
public function set_primary_email( $new_primary_email = '' ) {
|
360 |
+
|
361 |
+
if( ! is_email( $new_primary_email ) ) {
|
362 |
+
return false;
|
363 |
+
}
|
364 |
+
|
365 |
+
do_action( 'edd_customer_pre_set_primary_email', $new_primary_email, $this->id, $this );
|
366 |
+
|
367 |
+
$existing = new EDD_Customer( $new_primary_email );
|
368 |
+
|
369 |
+
if( $existing->id > 0 && (int) $existing->id !== (int) $this->id ) {
|
370 |
+
|
371 |
+
// This email belongs to another customer
|
372 |
+
return false;
|
373 |
+
}
|
374 |
+
|
375 |
+
$old_email = $this->email;
|
376 |
+
|
377 |
+
// Update customer record with new email
|
378 |
+
$update = $this->update( array( 'email' => $new_primary_email ) );
|
379 |
+
|
380 |
+
// Remove new primary from list of additional emails
|
381 |
+
$remove = $this->remove_email( $new_primary_email );
|
382 |
+
|
383 |
+
// Add old email to additional emails list
|
384 |
+
$add = $this->add_email( $old_email );
|
385 |
+
|
386 |
+
$ret = $update && $remove && $add;
|
387 |
+
|
388 |
+
if( $ret ) {
|
389 |
+
$this->email = $new_primary_email;
|
390 |
+
}
|
391 |
+
|
392 |
+
do_action( 'edd_customer_post_set_primary_email', $new_primary_email, $this->id, $this );
|
393 |
+
|
394 |
+
return $ret;
|
395 |
+
|
396 |
+
}
|
397 |
+
|
398 |
+
/*
|
399 |
+
* Get the payment ids of the customer in an array.
|
400 |
+
*
|
401 |
+
* @since 2.6
|
402 |
+
* @return array An array of payment IDs for the customer, or an empty array if none exist.
|
403 |
+
*/
|
404 |
+
public function get_payment_ids() {
|
405 |
+
|
406 |
+
$payment_ids = $this->payment_ids;
|
407 |
+
|
408 |
+
if ( ! empty( $payment_ids ) ) {
|
409 |
+
$payment_ids = array_map( 'absint', explode( ',', $payment_ids ) );
|
410 |
+
} else {
|
411 |
+
$payment_ids = array();
|
412 |
+
}
|
413 |
+
|
414 |
+
return $payment_ids;
|
415 |
+
|
416 |
+
}
|
417 |
+
|
418 |
+
/*
|
419 |
+
* Get an array of EDD_Payment objects from the payment_ids attached to the customer
|
420 |
+
*
|
421 |
+
* @since 2.6
|
422 |
+
* @param array|string $status A single status as a string or an array of statuses
|
423 |
+
* @return array An array of EDD_Payment objects or an empty array
|
424 |
+
*/
|
425 |
+
public function get_payments( $status = array() ) {
|
426 |
+
|
427 |
+
$payment_ids = $this->get_payment_ids();
|
428 |
+
|
429 |
+
$payments = array();
|
430 |
+
foreach ( $payment_ids as $payment_id ) {
|
431 |
+
|
432 |
+
$payment = new EDD_Payment( $payment_id );
|
433 |
+
if ( empty( $status ) || ( is_array( $status ) && in_array( $payment->status, $status ) ) || $status == $payment->status ) {
|
434 |
+
$payments[] = new EDD_Payment( $payment_id );
|
435 |
+
}
|
436 |
+
|
437 |
+
}
|
438 |
+
|
439 |
+
return $payments;
|
440 |
+
|
441 |
+
}
|
442 |
|
443 |
/**
|
444 |
* Attach payment to the customer then triggers increasing stats
|
629 |
* @return mixed If successful, the new value, otherwise false
|
630 |
*/
|
631 |
public function increase_value( $value = 0.00 ) {
|
632 |
+
$value = apply_filters( 'edd_customer_increase_value', $value, $this );
|
633 |
|
634 |
$new_value = floatval( $this->purchase_value ) + $value;
|
635 |
|
636 |
+
do_action( 'edd_customer_pre_increase_value', $value, $this->id, $this );
|
637 |
|
638 |
if ( $this->update( array( 'purchase_value' => $new_value ) ) ) {
|
639 |
$this->purchase_value = $new_value;
|
640 |
}
|
641 |
|
642 |
+
do_action( 'edd_customer_post_increase_value', $this->purchase_value, $value, $this->id, $this );
|
643 |
|
644 |
return $this->purchase_value;
|
645 |
}
|
652 |
* @return mixed If successful, the new value, otherwise false
|
653 |
*/
|
654 |
public function decrease_value( $value = 0.00 ) {
|
655 |
+
$value = apply_filters( 'edd_customer_decrease_value', $value, $this );
|
656 |
|
657 |
$new_value = floatval( $this->purchase_value ) - $value;
|
658 |
|
660 |
$new_value = 0.00;
|
661 |
}
|
662 |
|
663 |
+
do_action( 'edd_customer_pre_decrease_value', $value, $this->id, $this );
|
664 |
|
665 |
if ( $this->update( array( 'purchase_value' => $new_value ) ) ) {
|
666 |
$this->purchase_value = $new_value;
|
667 |
}
|
668 |
|
669 |
+
do_action( 'edd_customer_post_decrease_value', $this->purchase_value, $value, $this->id, $this );
|
670 |
|
671 |
return $this->purchase_value;
|
672 |
}
|
761 |
|
762 |
}
|
763 |
|
764 |
+
/**
|
765 |
+
* Retrieve customer meta field for a customer.
|
766 |
+
*
|
767 |
+
* @param string $meta_key The meta key to retrieve.
|
768 |
+
* @param bool $single Whether to return a single value.
|
769 |
+
* @return mixed Will be an array if $single is false. Will be value of meta data field if $single is true.
|
770 |
+
*
|
771 |
+
* @access public
|
772 |
+
* @since 2.6
|
773 |
+
*/
|
774 |
+
public function get_meta( $meta_key = '', $single = true ) {
|
775 |
+
return EDD()->customer_meta->get_meta( $this->id, $meta_key, $single );
|
776 |
+
}
|
777 |
+
|
778 |
+
/**
|
779 |
+
* Add meta data field to a customer.
|
780 |
+
*
|
781 |
+
* @param string $meta_key Metadata name.
|
782 |
+
* @param mixed $meta_value Metadata value.
|
783 |
+
* @param bool $unique Optional, default is false. Whether the same key should not be added.
|
784 |
+
* @return bool False for failure. True for success.
|
785 |
+
*
|
786 |
+
* @access public
|
787 |
+
* @since 2.6
|
788 |
+
*/
|
789 |
+
public function add_meta( $meta_key = '', $meta_value, $unique = false ) {
|
790 |
+
return EDD()->customer_meta->add_meta( $this->id, $meta_key, $meta_value, $unique );
|
791 |
+
}
|
792 |
+
|
793 |
+
/**
|
794 |
+
* Update customer meta field based on customer ID.
|
795 |
+
*
|
796 |
+
* @param string $meta_key Metadata key.
|
797 |
+
* @param mixed $meta_value Metadata value.
|
798 |
+
* @param mixed $prev_value Optional. Previous value to check before removing.
|
799 |
+
* @return bool False on failure, true if success.
|
800 |
+
*
|
801 |
+
* @access public
|
802 |
+
* @since 2.6
|
803 |
+
*/
|
804 |
+
public function update_meta( $meta_key = '', $meta_value, $prev_value = '' ) {
|
805 |
+
return EDD()->customer_meta->update_meta( $this->id, $meta_key, $meta_value, $prev_value );
|
806 |
+
}
|
807 |
+
|
808 |
+
/**
|
809 |
+
* Remove metadata matching criteria from a customer.
|
810 |
+
*
|
811 |
+
* @param string $meta_key Metadata name.
|
812 |
+
* @param mixed $meta_value Optional. Metadata value.
|
813 |
+
* @return bool False for failure. True for success.
|
814 |
+
*
|
815 |
+
* @access public
|
816 |
+
* @since 2.6
|
817 |
+
*/
|
818 |
+
public function delete_meta( $meta_key = '', $meta_value = '' ) {
|
819 |
+
return EDD()->customer_meta->delete_meta( $this->id, $meta_key, $meta_value );
|
820 |
+
}
|
821 |
+
|
822 |
/**
|
823 |
* Sanitize the data for update/create
|
824 |
*
|
includes/class-edd-db-customer-meta.php
ADDED
@@ -0,0 +1,208 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/**
|
3 |
+
* Customer Meta DB class
|
4 |
+
*
|
5 |
+
* This class is for interacting with the customer meta database table
|
6 |
+
*
|
7 |
+
* @package EDD
|
8 |
+
* @subpackage Classes/DB Customer Meta
|
9 |
+
* @copyright Copyright (c) 2015, Pippin Williamson
|
10 |
+
* @license http://opensource.org/licenses/gpl-2.0.php GNU Public License
|
11 |
+
* @since 2.6
|
12 |
+
*/
|
13 |
+
|
14 |
+
// Exit if accessed directly
|
15 |
+
if ( ! defined( 'ABSPATH' ) ) exit;
|
16 |
+
|
17 |
+
class EDD_DB_Customer_Meta extends EDD_DB {
|
18 |
+
|
19 |
+
/**
|
20 |
+
* Get things started
|
21 |
+
*
|
22 |
+
* @access public
|
23 |
+
* @since 2.6
|
24 |
+
*/
|
25 |
+
public function __construct() {
|
26 |
+
global $wpdb;
|
27 |
+
|
28 |
+
$this->table_name = $wpdb->prefix . 'edd_customermeta';
|
29 |
+
$this->primary_key = 'meta_id';
|
30 |
+
$this->version = '1.0';
|
31 |
+
|
32 |
+
add_action( 'plugins_loaded', array( $this, 'register_table' ), 11 );
|
33 |
+
|
34 |
+
}
|
35 |
+
|
36 |
+
/**
|
37 |
+
* Get table columns and data types
|
38 |
+
*
|
39 |
+
* @access public
|
40 |
+
* @since 1.7.18
|
41 |
+
*/
|
42 |
+
public function get_columns() {
|
43 |
+
return array(
|
44 |
+
'meta_id' => '%d',
|
45 |
+
'customer_id' => '%d',
|
46 |
+
'meta_key' => '%s',
|
47 |
+
'meta_value' => '%s',
|
48 |
+
);
|
49 |
+
}
|
50 |
+
|
51 |
+
/**
|
52 |
+
* Register the table with $wpdb so the metadata api can find it
|
53 |
+
*
|
54 |
+
* @access public
|
55 |
+
* @since 2.6
|
56 |
+
*/
|
57 |
+
public function register_table() {
|
58 |
+
global $wpdb;
|
59 |
+
$wpdb->customermeta = $this->table_name;
|
60 |
+
}
|
61 |
+
|
62 |
+
/**
|
63 |
+
* Retrieve customer meta field for a customer.
|
64 |
+
*
|
65 |
+
* For internal use only. Use EDD_Customer->get_meta() for public usage.
|
66 |
+
*
|
67 |
+
* @param int $customer_id Customer ID.
|
68 |
+
* @param string $meta_key The meta key to retrieve.
|
69 |
+
* @param bool $single Whether to return a single value.
|
70 |
+
* @return mixed Will be an array if $single is false. Will be value of meta data field if $single is true.
|
71 |
+
*
|
72 |
+
* @access private
|
73 |
+
* @since 2.6
|
74 |
+
*/
|
75 |
+
public function get_meta( $customer_id = 0, $meta_key = '', $single = false ) {
|
76 |
+
$customer_id = $this->sanitize_customer_id( $customer_id );
|
77 |
+
if ( false === $customer_id ) {
|
78 |
+
return false;
|
79 |
+
}
|
80 |
+
|
81 |
+
return get_metadata( 'customer', $customer_id, $meta_key, $single );
|
82 |
+
}
|
83 |
+
|
84 |
+
/**
|
85 |
+
* Add meta data field to a customer.
|
86 |
+
*
|
87 |
+
* For internal use only. Use EDD_Customer->add_meta() for public usage.
|
88 |
+
*
|
89 |
+
* @param int $customer_id Customer ID.
|
90 |
+
* @param string $meta_key Metadata name.
|
91 |
+
* @param mixed $meta_value Metadata value.
|
92 |
+
* @param bool $unique Optional, default is false. Whether the same key should not be added.
|
93 |
+
* @return bool False for failure. True for success.
|
94 |
+
*
|
95 |
+
* @access private
|
96 |
+
* @since 2.6
|
97 |
+
*/
|
98 |
+
public function add_meta( $customer_id = 0, $meta_key = '', $meta_value, $unique = false ) {
|
99 |
+
$customer_id = $this->sanitize_customer_id( $customer_id );
|
100 |
+
if ( false === $customer_id ) {
|
101 |
+
return false;
|
102 |
+
}
|
103 |
+
|
104 |
+
return add_metadata( 'customer', $customer_id, $meta_key, $meta_value, $unique );
|
105 |
+
}
|
106 |
+
|
107 |
+
/**
|
108 |
+
* Update customer meta field based on Customer ID.
|
109 |
+
*
|
110 |
+
* For internal use only. Use EDD_Customer->update_meta() for public usage.
|
111 |
+
*
|
112 |
+
* Use the $prev_value parameter to differentiate between meta fields with the
|
113 |
+
* same key and Customer ID.
|
114 |
+
*
|
115 |
+
* If the meta field for the customer does not exist, it will be added.
|
116 |
+
*
|
117 |
+
* @param int $customer_id Customer ID.
|
118 |
+
* @param string $meta_key Metadata key.
|
119 |
+
* @param mixed $meta_value Metadata value.
|
120 |
+
* @param mixed $prev_value Optional. Previous value to check before removing.
|
121 |
+
* @return bool False on failure, true if success.
|
122 |
+
*
|
123 |
+
* @access private
|
124 |
+
* @since 2.6
|
125 |
+
*/
|
126 |
+
public function update_meta( $customer_id = 0, $meta_key = '', $meta_value, $prev_value = '' ) {
|
127 |
+
$customer_id = $this->sanitize_customer_id( $customer_id );
|
128 |
+
if ( false === $customer_id ) {
|
129 |
+
return false;
|
130 |
+
}
|
131 |
+
|
132 |
+
return update_metadata( 'customer', $customer_id, $meta_key, $meta_value, $prev_value );
|
133 |
+
}
|
134 |
+
|
135 |
+
/**
|
136 |
+
* Remove metadata matching criteria from a customer.
|
137 |
+
*
|
138 |
+
* For internal use only. Use EDD_Customer->delete_meta() for public usage.
|
139 |
+
*
|
140 |
+
* You can match based on the key, or key and value. Removing based on key and
|
141 |
+
* value, will keep from removing duplicate metadata with the same key. It also
|
142 |
+
* allows removing all metadata matching key, if needed.
|
143 |
+
*
|
144 |
+
* @param int $customer_id Customer ID.
|
145 |
+
* @param string $meta_key Metadata name.
|
146 |
+
* @param mixed $meta_value Optional. Metadata value.
|
147 |
+
* @return bool False for failure. True for success.
|
148 |
+
*
|
149 |
+
* @access private
|
150 |
+
* @since 2.6
|
151 |
+
*/
|
152 |
+
public function delete_meta( $customer_id = 0, $meta_key = '', $meta_value = '' ) {
|
153 |
+
return delete_metadata( 'customer', $customer_id, $meta_key, $meta_value );
|
154 |
+
}
|
155 |
+
|
156 |
+
/**
|
157 |
+
* Create the table
|
158 |
+
*
|
159 |
+
* @access public
|
160 |
+
* @since 2.6
|
161 |
+
*/
|
162 |
+
public function create_table() {
|
163 |
+
|
164 |
+
require_once( ABSPATH . 'wp-admin/includes/upgrade.php' );
|
165 |
+
|
166 |
+
$sql = "CREATE TABLE {$this->table_name} (
|
167 |
+
meta_id bigint(20) NOT NULL AUTO_INCREMENT,
|
168 |
+
customer_id bigint(20) NOT NULL,
|
169 |
+
meta_key varchar(255) DEFAULT NULL,
|
170 |
+
meta_value longtext,
|
171 |
+
PRIMARY KEY (meta_id),
|
172 |
+
KEY customer_id (customer_id),
|
173 |
+
KEY meta_key (meta_key)
|
174 |
+
) CHARACTER SET utf8 COLLATE utf8_general_ci;";
|
175 |
+
|
176 |
+
dbDelta( $sql );
|
177 |
+
|
178 |
+
update_option( $this->table_name . '_db_version', $this->version );
|
179 |
+
}
|
180 |
+
|
181 |
+
/**
|
182 |
+
* Given a customer ID, make sure it's a positive number, greater than zero before inserting or adding.
|
183 |
+
*
|
184 |
+
* @since 2.6
|
185 |
+
* @param int|stirng $customer_id A passed customer ID.
|
186 |
+
* @return int|bool The normalized customer ID or false if it's found to not be valid.
|
187 |
+
*/
|
188 |
+
private function sanitize_customer_id( $customer_id ) {
|
189 |
+
if ( ! is_numeric( $customer_id ) ) {
|
190 |
+
return false;
|
191 |
+
}
|
192 |
+
|
193 |
+
$customer_id = (int) $customer_id;
|
194 |
+
|
195 |
+
// We were given a non positive number
|
196 |
+
if ( absint( $customer_id ) !== $customer_id ) {
|
197 |
+
return false;
|
198 |
+
}
|
199 |
+
|
200 |
+
if ( empty( $customer_id ) ) {
|
201 |
+
return false;
|
202 |
+
}
|
203 |
+
|
204 |
+
return absint( $customer_id );
|
205 |
+
|
206 |
+
}
|
207 |
+
|
208 |
+
}
|
includes/class-edd-db-customers.php
CHANGED
@@ -367,6 +367,20 @@ class EDD_DB_Customers extends EDD_DB {
|
|
367 |
}
|
368 |
|
369 |
if ( ! $customer = $wpdb->get_row( $wpdb->prepare( "SELECT * FROM $this->table_name WHERE $db_field = %s LIMIT 1", $value ) ) ) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
370 |
return false;
|
371 |
}
|
372 |
|
@@ -388,7 +402,7 @@ class EDD_DB_Customers extends EDD_DB {
|
|
388 |
'offset' => 0,
|
389 |
'user_id' => 0,
|
390 |
'orderby' => 'id',
|
391 |
-
'order' => 'DESC'
|
392 |
);
|
393 |
|
394 |
$args = wp_parse_args( $args, $defaults );
|
@@ -397,6 +411,7 @@ class EDD_DB_Customers extends EDD_DB {
|
|
397 |
$args['number'] = 999999999999;
|
398 |
}
|
399 |
|
|
|
400 |
$where = ' WHERE 1=1 ';
|
401 |
|
402 |
// specific customers
|
@@ -436,7 +451,11 @@ class EDD_DB_Customers extends EDD_DB {
|
|
436 |
|
437 |
$where .= $wpdb->prepare( " AND `email` IN( $emails ) ", $args['email'] );
|
438 |
} else {
|
439 |
-
$
|
|
|
|
|
|
|
|
|
440 |
}
|
441 |
}
|
442 |
|
@@ -452,16 +471,14 @@ class EDD_DB_Customers extends EDD_DB {
|
|
452 |
|
453 |
if( ! empty( $args['date']['start'] ) ) {
|
454 |
|
455 |
-
$start = date( 'Y-m-d
|
456 |
-
|
457 |
$where .= " AND `date_created` >= '{$start}'";
|
458 |
|
459 |
}
|
460 |
|
461 |
if( ! empty( $args['date']['end'] ) ) {
|
462 |
|
463 |
-
$end = date( 'Y-m-d
|
464 |
-
|
465 |
$where .= " AND `date_created` <= '{$end}'";
|
466 |
|
467 |
}
|
@@ -490,8 +507,11 @@ class EDD_DB_Customers extends EDD_DB {
|
|
490 |
$args['orderby'] = esc_sql( $args['orderby'] );
|
491 |
$args['order'] = esc_sql( $args['order'] );
|
492 |
|
|
|
|
|
493 |
if( $customers === false ) {
|
494 |
-
$
|
|
|
495 |
wp_cache_set( $cache_key, $customers, 'customers', 3600 );
|
496 |
}
|
497 |
|
@@ -510,16 +530,77 @@ class EDD_DB_Customers extends EDD_DB {
|
|
510 |
|
511 |
global $wpdb;
|
512 |
|
|
|
513 |
$where = ' WHERE 1=1 ';
|
514 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
515 |
if( ! empty( $args['date'] ) ) {
|
516 |
|
517 |
if( is_array( $args['date'] ) ) {
|
518 |
|
519 |
-
|
520 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
521 |
|
522 |
-
|
|
|
|
|
|
|
523 |
|
524 |
} else {
|
525 |
|
@@ -532,13 +613,13 @@ class EDD_DB_Customers extends EDD_DB {
|
|
532 |
|
533 |
}
|
534 |
|
535 |
-
|
536 |
$cache_key = md5( 'edd_customers_count' . serialize( $args ) );
|
537 |
|
538 |
$count = wp_cache_get( $cache_key, 'customers' );
|
539 |
|
540 |
if( $count === false ) {
|
541 |
-
$
|
|
|
542 |
wp_cache_set( $cache_key, $count, 'customers', 3600 );
|
543 |
}
|
544 |
|
@@ -578,13 +659,4 @@ class EDD_DB_Customers extends EDD_DB {
|
|
578 |
update_option( $this->table_name . '_db_version', $this->version );
|
579 |
}
|
580 |
|
581 |
-
/**
|
582 |
-
* Check if the Customers table was ever installed
|
583 |
-
*
|
584 |
-
* @since 2.4
|
585 |
-
* @return bool Returns if the customers table was installed and upgrade routine run
|
586 |
-
*/
|
587 |
-
public function installed() {
|
588 |
-
return $this->table_exists( $this->table_name );
|
589 |
-
}
|
590 |
}
|
367 |
}
|
368 |
|
369 |
if ( ! $customer = $wpdb->get_row( $wpdb->prepare( "SELECT * FROM $this->table_name WHERE $db_field = %s LIMIT 1", $value ) ) ) {
|
370 |
+
|
371 |
+
// Look for customer from an additional email
|
372 |
+
if( 'email' === $field ) {
|
373 |
+
|
374 |
+
$meta_table = EDD()->customer_meta->table_name;
|
375 |
+
$customer_id = $wpdb->get_var( $wpdb->prepare( "SELECT customer_id FROM $meta_table WHERE meta_key = 'additional_email' AND meta_value = '%s' LIMIT 1", $value ) );
|
376 |
+
|
377 |
+
if( ! empty( $customer_id ) ) {
|
378 |
+
return $this->get( $customer_id );
|
379 |
+
}
|
380 |
+
|
381 |
+
}
|
382 |
+
|
383 |
+
|
384 |
return false;
|
385 |
}
|
386 |
|
402 |
'offset' => 0,
|
403 |
'user_id' => 0,
|
404 |
'orderby' => 'id',
|
405 |
+
'order' => 'DESC',
|
406 |
);
|
407 |
|
408 |
$args = wp_parse_args( $args, $defaults );
|
411 |
$args['number'] = 999999999999;
|
412 |
}
|
413 |
|
414 |
+
$join = '';
|
415 |
$where = ' WHERE 1=1 ';
|
416 |
|
417 |
// specific customers
|
451 |
|
452 |
$where .= $wpdb->prepare( " AND `email` IN( $emails ) ", $args['email'] );
|
453 |
} else {
|
454 |
+
$meta_table = $wpdb->prefix . 'edd_customermeta';
|
455 |
+
$customers_table = $this->table_name;
|
456 |
+
|
457 |
+
$join .= " LEFT JOIN $meta_table ON $customers_table.id = $meta_table.customer_id";
|
458 |
+
$where .= $wpdb->prepare( " AND ( ( `meta_key` = 'additional_email' AND `meta_value` = %s ) OR `email` = %s )", $args['email'], $args['email'] );
|
459 |
}
|
460 |
}
|
461 |
|
471 |
|
472 |
if( ! empty( $args['date']['start'] ) ) {
|
473 |
|
474 |
+
$start = date( 'Y-m-d 00:00:00', strtotime( $args['date']['start'] ) );
|
|
|
475 |
$where .= " AND `date_created` >= '{$start}'";
|
476 |
|
477 |
}
|
478 |
|
479 |
if( ! empty( $args['date']['end'] ) ) {
|
480 |
|
481 |
+
$end = date( 'Y-m-d 23:59:59', strtotime( $args['date']['end'] ) );
|
|
|
482 |
$where .= " AND `date_created` <= '{$end}'";
|
483 |
|
484 |
}
|
507 |
$args['orderby'] = esc_sql( $args['orderby'] );
|
508 |
$args['order'] = esc_sql( $args['order'] );
|
509 |
|
510 |
+
$customers = false;
|
511 |
+
|
512 |
if( $customers === false ) {
|
513 |
+
$query = $wpdb->prepare( "SELECT * FROM $this->table_name $join $where GROUP BY $this->primary_key ORDER BY {$args['orderby']} {$args['order']} LIMIT %d,%d;", absint( $args['offset'] ), absint( $args['number'] ) );
|
514 |
+
$customers = $wpdb->get_results( $query );
|
515 |
wp_cache_set( $cache_key, $customers, 'customers', 3600 );
|
516 |
}
|
517 |
|
530 |
|
531 |
global $wpdb;
|
532 |
|
533 |
+
$join = '';
|
534 |
$where = ' WHERE 1=1 ';
|
535 |
|
536 |
+
// specific customers
|
537 |
+
if( ! empty( $args['id'] ) ) {
|
538 |
+
|
539 |
+
if( is_array( $args['id'] ) ) {
|
540 |
+
$ids = implode( ',', array_map('intval', $args['id'] ) );
|
541 |
+
} else {
|
542 |
+
$ids = intval( $args['id'] );
|
543 |
+
}
|
544 |
+
|
545 |
+
$where .= " AND `id` IN( {$ids} ) ";
|
546 |
+
|
547 |
+
}
|
548 |
+
|
549 |
+
// customers for specific user accounts
|
550 |
+
if( ! empty( $args['user_id'] ) ) {
|
551 |
+
|
552 |
+
if( is_array( $args['user_id'] ) ) {
|
553 |
+
$user_ids = implode( ',', array_map('intval', $args['user_id'] ) );
|
554 |
+
} else {
|
555 |
+
$user_ids = intval( $args['user_id'] );
|
556 |
+
}
|
557 |
+
|
558 |
+
$where .= " AND `user_id` IN( {$user_ids} ) ";
|
559 |
+
|
560 |
+
}
|
561 |
+
|
562 |
+
//specific customers by email
|
563 |
+
if( ! empty( $args['email'] ) ) {
|
564 |
+
|
565 |
+
if( is_array( $args['email'] ) ) {
|
566 |
+
|
567 |
+
$emails_count = count( $args['email'] );
|
568 |
+
$emails_placeholder = array_fill( 0, $emails_count, '%s' );
|
569 |
+
$emails = implode( ', ', $emails_placeholder );
|
570 |
+
|
571 |
+
$where .= $wpdb->prepare( " AND `email` IN( $emails ) ", $args['email'] );
|
572 |
+
} else {
|
573 |
+
$meta_table = $wpdb->prefix . 'edd_customermeta';
|
574 |
+
$customers_table = $this->table_name;
|
575 |
+
|
576 |
+
$join .= " LEFT JOIN $meta_table ON $customers_table.id = $meta_table.customer_id";
|
577 |
+
$where .= $wpdb->prepare( " AND ( ( `meta_key` = 'additional_email' AND `meta_value` = %s ) OR `email` = %s )", $args['email'], $args['email'] );
|
578 |
+
}
|
579 |
+
}
|
580 |
+
|
581 |
+
// specific customers by name
|
582 |
+
if( ! empty( $args['name'] ) ) {
|
583 |
+
$where .= $wpdb->prepare( " AND `name` LIKE '%%%%" . '%s' . "%%%%' ", $args['name'] );
|
584 |
+
}
|
585 |
+
|
586 |
+
// Customers created for a specific date or in a date range
|
587 |
if( ! empty( $args['date'] ) ) {
|
588 |
|
589 |
if( is_array( $args['date'] ) ) {
|
590 |
|
591 |
+
if( ! empty( $args['date']['start'] ) ) {
|
592 |
+
|
593 |
+
$start = date( 'Y-m-d 00:00:00', strtotime( $args['date']['start'] ) );
|
594 |
+
$where .= " AND `date_created` >= '{$start}'";
|
595 |
+
|
596 |
+
}
|
597 |
+
|
598 |
+
if( ! empty( $args['date']['end'] ) ) {
|
599 |
|
600 |
+
$end = date( 'Y-m-d 23:59:59', strtotime( $args['date']['end'] ) );
|
601 |
+
$where .= " AND `date_created` <= '{$end}'";
|
602 |
+
|
603 |
+
}
|
604 |
|
605 |
} else {
|
606 |
|
613 |
|
614 |
}
|
615 |
|
|
|
616 |
$cache_key = md5( 'edd_customers_count' . serialize( $args ) );
|
617 |
|
618 |
$count = wp_cache_get( $cache_key, 'customers' );
|
619 |
|
620 |
if( $count === false ) {
|
621 |
+
$query = "SELECT COUNT($this->primary_key) FROM " . $this->table_name . "{$join} {$where};";
|
622 |
+
$count = $wpdb->get_var( $query);
|
623 |
wp_cache_set( $cache_key, $count, 'customers', 3600 );
|
624 |
}
|
625 |
|
659 |
update_option( $this->table_name . '_db_version', $this->version );
|
660 |
}
|
661 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
662 |
}
|
includes/class-edd-db.php
CHANGED
@@ -236,4 +236,14 @@ abstract class EDD_DB {
|
|
236 |
return $wpdb->get_var( $wpdb->prepare( "SHOW TABLES LIKE '%s'", $table ) ) === $table;
|
237 |
}
|
238 |
|
239 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
236 |
return $wpdb->get_var( $wpdb->prepare( "SHOW TABLES LIKE '%s'", $table ) ) === $table;
|
237 |
}
|
238 |
|
239 |
+
/**
|
240 |
+
* Check if the table was ever installed
|
241 |
+
*
|
242 |
+
* @since 2.4
|
243 |
+
* @return bool Returns if the customers table was installed and upgrade routine run
|
244 |
+
*/
|
245 |
+
public function installed() {
|
246 |
+
return $this->table_exists( $this->table_name );
|
247 |
+
}
|
248 |
+
|
249 |
+
}
|
includes/class-edd-download.php
CHANGED
@@ -466,7 +466,7 @@ class EDD_Download {
|
|
466 |
*/
|
467 |
public function get_file_price_condition( $file_key = 0 ) {
|
468 |
|
469 |
-
$files =
|
470 |
$condition = isset( $files[ $file_key ]['condition']) ? $files[ $file_key ]['condition'] : 'all';
|
471 |
|
472 |
return apply_filters( 'edd_get_file_price_condition', $condition, $this->ID, $files );
|
@@ -599,14 +599,12 @@ class EDD_Download {
|
|
599 |
|
600 |
if ( '' == get_post_meta( $this->ID, '_edd_download_sales', true ) ) {
|
601 |
add_post_meta( $this->ID, '_edd_download_sales', 0 );
|
602 |
-
}
|
603 |
|
604 |
$this->sales = get_post_meta( $this->ID, '_edd_download_sales', true );
|
605 |
|
606 |
-
|
607 |
-
|
608 |
-
$this->sales = 0;
|
609 |
-
}
|
610 |
|
611 |
}
|
612 |
|
@@ -623,13 +621,15 @@ class EDD_Download {
|
|
623 |
*/
|
624 |
public function increase_sales( $quantity = 1 ) {
|
625 |
|
626 |
-
$sales = edd_get_download_sales_stats( $this->ID );
|
627 |
$quantity = absint( $quantity );
|
628 |
-
$total_sales = $
|
629 |
|
630 |
if ( $this->update_meta( '_edd_download_sales', $total_sales ) ) {
|
631 |
|
632 |
$this->sales = $total_sales;
|
|
|
|
|
|
|
633 |
return $this->sales;
|
634 |
|
635 |
}
|
@@ -646,17 +646,18 @@ class EDD_Download {
|
|
646 |
*/
|
647 |
public function decrease_sales( $quantity = 1 ) {
|
648 |
|
649 |
-
$sales = edd_get_download_sales_stats( $this->ID );
|
650 |
-
|
651 |
// Only decrease if not already zero
|
652 |
-
if ( $
|
653 |
|
654 |
$quantity = absint( $quantity );
|
655 |
-
$total_sales = $
|
656 |
|
657 |
if ( $this->update_meta( '_edd_download_sales', $total_sales ) ) {
|
658 |
|
659 |
$this->sales = $total_sales;
|
|
|
|
|
|
|
660 |
return $this->sales;
|
661 |
|
662 |
}
|
@@ -683,10 +684,8 @@ class EDD_Download {
|
|
683 |
|
684 |
$this->earnings = get_post_meta( $this->ID, '_edd_download_earnings', true );
|
685 |
|
686 |
-
|
687 |
-
|
688 |
-
$this->earnings = 0;
|
689 |
-
}
|
690 |
|
691 |
}
|
692 |
|
@@ -703,12 +702,15 @@ class EDD_Download {
|
|
703 |
*/
|
704 |
public function increase_earnings( $amount = 0 ) {
|
705 |
|
706 |
-
$
|
707 |
-
$new_amount = $
|
708 |
|
709 |
if ( $this->update_meta( '_edd_download_earnings', $new_amount ) ) {
|
710 |
|
711 |
$this->earnings = $new_amount;
|
|
|
|
|
|
|
712 |
return $this->earnings;
|
713 |
|
714 |
}
|
@@ -726,16 +728,18 @@ class EDD_Download {
|
|
726 |
*/
|
727 |
public function decrease_earnings( $amount ) {
|
728 |
|
729 |
-
|
|
|
730 |
|
731 |
-
|
732 |
-
|
733 |
-
// Only decrease if greater than zero
|
734 |
-
$new_amount = $earnings - (float) $amount;
|
735 |
|
736 |
if ( $this->update_meta( '_edd_download_earnings', $new_amount ) ) {
|
737 |
|
738 |
$this->earnings = $new_amount;
|
|
|
|
|
|
|
739 |
return $this->earnings;
|
740 |
|
741 |
}
|
466 |
*/
|
467 |
public function get_file_price_condition( $file_key = 0 ) {
|
468 |
|
469 |
+
$files = $this->get_files();
|
470 |
$condition = isset( $files[ $file_key ]['condition']) ? $files[ $file_key ]['condition'] : 'all';
|
471 |
|
472 |
return apply_filters( 'edd_get_file_price_condition', $condition, $this->ID, $files );
|
599 |
|
600 |
if ( '' == get_post_meta( $this->ID, '_edd_download_sales', true ) ) {
|
601 |
add_post_meta( $this->ID, '_edd_download_sales', 0 );
|
602 |
+
}
|
603 |
|
604 |
$this->sales = get_post_meta( $this->ID, '_edd_download_sales', true );
|
605 |
|
606 |
+
// Never let sales be less than zero
|
607 |
+
$this->sales = max( $this->sales, 0 );
|
|
|
|
|
608 |
|
609 |
}
|
610 |
|
621 |
*/
|
622 |
public function increase_sales( $quantity = 1 ) {
|
623 |
|
|
|
624 |
$quantity = absint( $quantity );
|
625 |
+
$total_sales = $this->get_sales() + $quantity;
|
626 |
|
627 |
if ( $this->update_meta( '_edd_download_sales', $total_sales ) ) {
|
628 |
|
629 |
$this->sales = $total_sales;
|
630 |
+
|
631 |
+
do_action( 'edd_download_increase_sales', $this->ID, $this->sales, $this );
|
632 |
+
|
633 |
return $this->sales;
|
634 |
|
635 |
}
|
646 |
*/
|
647 |
public function decrease_sales( $quantity = 1 ) {
|
648 |
|
|
|
|
|
649 |
// Only decrease if not already zero
|
650 |
+
if ( $this->get_sales() > 0 ) {
|
651 |
|
652 |
$quantity = absint( $quantity );
|
653 |
+
$total_sales = $this->get_sales() - $quantity;
|
654 |
|
655 |
if ( $this->update_meta( '_edd_download_sales', $total_sales ) ) {
|
656 |
|
657 |
$this->sales = $total_sales;
|
658 |
+
|
659 |
+
do_action( 'edd_download_decrease_sales', $this->ID, $this->sales, $this );
|
660 |
+
|
661 |
return $this->sales;
|
662 |
|
663 |
}
|
684 |
|
685 |
$this->earnings = get_post_meta( $this->ID, '_edd_download_earnings', true );
|
686 |
|
687 |
+
// Never let earnings be less than zero
|
688 |
+
$this->earnings = max( $this->earnings, 0 );
|
|
|
|
|
689 |
|
690 |
}
|
691 |
|
702 |
*/
|
703 |
public function increase_earnings( $amount = 0 ) {
|
704 |
|
705 |
+
$current_earnings = $this->get_earnings();
|
706 |
+
$new_amount = apply_filters( 'edd_download_increase_earnings_amount', $current_earnings + (float) $amount, $current_earnings, $amount, $this );
|
707 |
|
708 |
if ( $this->update_meta( '_edd_download_earnings', $new_amount ) ) {
|
709 |
|
710 |
$this->earnings = $new_amount;
|
711 |
+
|
712 |
+
do_action( 'edd_download_increase_earnings', $this->ID, $this->earnings, $this );
|
713 |
+
|
714 |
return $this->earnings;
|
715 |
|
716 |
}
|
728 |
*/
|
729 |
public function decrease_earnings( $amount ) {
|
730 |
|
731 |
+
// Only decrease if greater than zero
|
732 |
+
if ( $this->get_earnings() > 0 ) {
|
733 |
|
734 |
+
$current_earnings = $this->get_earnings();
|
735 |
+
$new_amount = apply_filters( 'edd_download_decrease_earnings_amount', $current_earnings - (float) $amount, $current_earnings, $amount, $this );
|
|
|
|
|
736 |
|
737 |
if ( $this->update_meta( '_edd_download_earnings', $new_amount ) ) {
|
738 |
|
739 |
$this->earnings = $new_amount;
|
740 |
+
|
741 |
+
do_action( 'edd_download_decrease_earnings', $this->ID, $this->earnings, $this );
|
742 |
+
|
743 |
return $this->earnings;
|
744 |
|
745 |
}
|
includes/class-edd-fees.php
CHANGED
@@ -40,18 +40,18 @@ class EDD_Fees {
|
|
40 |
* @uses EDD_Fees::get_fees()
|
41 |
* @uses EDD_Session::set()
|
42 |
*
|
43 |
-
* @return
|
44 |
*/
|
45 |
public function add_fee( $args = array() ) {
|
46 |
|
47 |
-
// Backwards
|
48 |
if ( func_num_args() > 1 ) {
|
49 |
|
50 |
-
$args
|
51 |
-
$amount
|
52 |
-
$label
|
53 |
-
$id
|
54 |
-
$type
|
55 |
|
56 |
$args = array(
|
57 |
'amount' => $amount,
|
@@ -59,7 +59,8 @@ class EDD_Fees {
|
|
59 |
'id' => $id,
|
60 |
'type' => $type,
|
61 |
'no_tax' => false,
|
62 |
-
'download_id' => 0
|
|
|
63 |
);
|
64 |
|
65 |
} else {
|
@@ -70,7 +71,8 @@ class EDD_Fees {
|
|
70 |
'id' => '',
|
71 |
'no_tax' => false,
|
72 |
'type' => 'fee',
|
73 |
-
'download_id' => 0
|
|
|
74 |
);
|
75 |
|
76 |
$args = wp_parse_args( $args, $defaults );
|
@@ -81,8 +83,10 @@ class EDD_Fees {
|
|
81 |
|
82 |
}
|
83 |
|
|
|
84 |
if( 'item' === $args['type'] && ! empty( $args['download_id'] ) ) {
|
85 |
unset( $args['download_id'] );
|
|
|
86 |
}
|
87 |
|
88 |
$fees = $this->get_fees( 'all' );
|
@@ -96,8 +100,16 @@ class EDD_Fees {
|
|
96 |
// Sanitize the amount
|
97 |
$args['amount'] = edd_sanitize_amount( $args['amount'] );
|
98 |
|
|
|
|
|
|
|
|
|
|
|
99 |
// Set the fee
|
100 |
-
$fees[ $key ] = $args;
|
|
|
|
|
|
|
101 |
|
102 |
// Update fees
|
103 |
EDD()->session->set( 'edd_cart_fees', $fees );
|
@@ -113,7 +125,7 @@ class EDD_Fees {
|
|
113 |
* @param string $id Fee ID
|
114 |
* @uses EDD_Fees::get_fees()
|
115 |
* @uses EDD_Session::set()
|
116 |
-
* @return array
|
117 |
*/
|
118 |
public function remove_fee( $id = '' ) {
|
119 |
|
@@ -134,7 +146,7 @@ class EDD_Fees {
|
|
134 |
* @since 1.5
|
135 |
* @param string $type Fee type, "fee" or "item"
|
136 |
* @uses EDD_Fees::get_fees()
|
137 |
-
* @return bool
|
138 |
*/
|
139 |
public function has_fees( $type = 'fee' ) {
|
140 |
|
@@ -156,10 +168,11 @@ class EDD_Fees {
|
|
156 |
* @since 1.5
|
157 |
* @param string $type Fee type, "fee" or "item"
|
158 |
* @param int $download_id The download ID whose fees to retrieve
|
|
|
159 |
* @uses EDD_Session::get()
|
160 |
-
* @return
|
161 |
*/
|
162 |
-
public function get_fees( $type = 'fee', $download_id = 0 ) {
|
163 |
|
164 |
$fees = EDD()->session->get( 'edd_cart_fees' );
|
165 |
|
@@ -197,6 +210,22 @@ class EDD_Fees {
|
|
197 |
|
198 |
}
|
199 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
200 |
if( ! empty( $fees ) ) {
|
201 |
|
202 |
// Remove fees that belong to a specific download but are not in the cart
|
@@ -216,7 +245,8 @@ class EDD_Fees {
|
|
216 |
|
217 |
}
|
218 |
|
219 |
-
|
|
|
220 |
}
|
221 |
|
222 |
/**
|
@@ -224,8 +254,8 @@ class EDD_Fees {
|
|
224 |
*
|
225 |
* @since 1.5
|
226 |
*
|
227 |
-
* @param string $id
|
228 |
-
* @return bool
|
229 |
*/
|
230 |
public function get_fee( $id = '' ) {
|
231 |
$fees = $this->get_fees( 'all' );
|
@@ -246,7 +276,7 @@ class EDD_Fees {
|
|
246 |
* @param string $type Fee type, "fee" or "item"
|
247 |
* @uses EDD_Fees::get_fees()
|
248 |
* @uses EDD_Fees::has_fees()
|
249 |
-
* @return float
|
250 |
*/
|
251 |
public function type_total( $type = 'fee' ) {
|
252 |
$fees = $this->get_fees( $type );
|
@@ -271,7 +301,7 @@ class EDD_Fees {
|
|
271 |
* @uses EDD_Fees::get_fees()
|
272 |
* @uses EDD_Fees::has_fees()
|
273 |
* @param int $download_id The download ID whose fees to retrieve
|
274 |
-
* @return float
|
275 |
*/
|
276 |
public function total( $download_id = 0 ) {
|
277 |
$fees = $this->get_fees( 'all', $download_id );
|
@@ -294,7 +324,7 @@ class EDD_Fees {
|
|
294 |
* @uses EDD_Session::set()
|
295 |
* @param array $payment_meta The meta data to store with the payment
|
296 |
* @param array $payment_data The info sent from process-purchase.php
|
297 |
-
* @return array
|
298 |
*/
|
299 |
public function record_fees( $payment_meta, $payment_data ) {
|
300 |
if ( $this->has_fees( 'all' ) ) {
|
40 |
* @uses EDD_Fees::get_fees()
|
41 |
* @uses EDD_Session::set()
|
42 |
*
|
43 |
+
* @return array The fees.
|
44 |
*/
|
45 |
public function add_fee( $args = array() ) {
|
46 |
|
47 |
+
// Backwards compatibility with pre 2.0
|
48 |
if ( func_num_args() > 1 ) {
|
49 |
|
50 |
+
$args = func_get_args();
|
51 |
+
$amount = $args[0];
|
52 |
+
$label = isset( $args[1] ) ? $args[1] : '';
|
53 |
+
$id = isset( $args[2] ) ? $args[2] : '';
|
54 |
+
$type = 'fee';
|
55 |
|
56 |
$args = array(
|
57 |
'amount' => $amount,
|
59 |
'id' => $id,
|
60 |
'type' => $type,
|
61 |
'no_tax' => false,
|
62 |
+
'download_id' => 0,
|
63 |
+
'price_id' => NULL
|
64 |
);
|
65 |
|
66 |
} else {
|
71 |
'id' => '',
|
72 |
'no_tax' => false,
|
73 |
'type' => 'fee',
|
74 |
+
'download_id' => 0,
|
75 |
+
'price_id' => NULL
|
76 |
);
|
77 |
|
78 |
$args = wp_parse_args( $args, $defaults );
|
83 |
|
84 |
}
|
85 |
|
86 |
+
//If the fee is for an "item" but we passed in a download id
|
87 |
if( 'item' === $args['type'] && ! empty( $args['download_id'] ) ) {
|
88 |
unset( $args['download_id'] );
|
89 |
+
unset( $args['price_id'] );
|
90 |
}
|
91 |
|
92 |
$fees = $this->get_fees( 'all' );
|
100 |
// Sanitize the amount
|
101 |
$args['amount'] = edd_sanitize_amount( $args['amount'] );
|
102 |
|
103 |
+
// Force no_tax to true if the amount is negative
|
104 |
+
if( $args['amount'] < 0 ) {
|
105 |
+
$args['no_tax'] = true;
|
106 |
+
}
|
107 |
+
|
108 |
// Set the fee
|
109 |
+
$fees[ $key ] = apply_filters( 'edd_fees_add_fee', $args, $this );
|
110 |
+
|
111 |
+
// Allow 3rd parties to process the fees before storing them in the session
|
112 |
+
$fees = apply_filters( 'edd_fees_set_fees', $fees, $this );
|
113 |
|
114 |
// Update fees
|
115 |
EDD()->session->set( 'edd_cart_fees', $fees );
|
125 |
* @param string $id Fee ID
|
126 |
* @uses EDD_Fees::get_fees()
|
127 |
* @uses EDD_Session::set()
|
128 |
+
* @return array Remaining fees
|
129 |
*/
|
130 |
public function remove_fee( $id = '' ) {
|
131 |
|
146 |
* @since 1.5
|
147 |
* @param string $type Fee type, "fee" or "item"
|
148 |
* @uses EDD_Fees::get_fees()
|
149 |
+
* @return bool True if there are fees, false otherwise
|
150 |
*/
|
151 |
public function has_fees( $type = 'fee' ) {
|
152 |
|
168 |
* @since 1.5
|
169 |
* @param string $type Fee type, "fee" or "item"
|
170 |
* @param int $download_id The download ID whose fees to retrieve
|
171 |
+
* @param int $price_id The variable price ID whose fees to retrieve
|
172 |
* @uses EDD_Session::get()
|
173 |
+
* @return array|bool List of fees when available, false when there are no fees
|
174 |
*/
|
175 |
+
public function get_fees( $type = 'fee', $download_id = 0, $price_id = NULL ) {
|
176 |
|
177 |
$fees = EDD()->session->get( 'edd_cart_fees' );
|
178 |
|
210 |
|
211 |
}
|
212 |
|
213 |
+
// Now that we've removed any fees that are for other Downloads, lets also remove any fees that don't match this price id
|
214 |
+
if( ! empty( $fees ) && ! empty( $download_id ) && ! is_null( $price_id ) ) {
|
215 |
+
|
216 |
+
// Remove fees that don't belong to the specified Download AND Price ID
|
217 |
+
foreach( $fees as $key => $fee ) {
|
218 |
+
|
219 |
+
if ( (int) $price_id !== (int) $fee['price_id'] ){
|
220 |
+
|
221 |
+
unset( $fees[ $key ] );
|
222 |
+
|
223 |
+
}
|
224 |
+
|
225 |
+
}
|
226 |
+
|
227 |
+
}
|
228 |
+
|
229 |
if( ! empty( $fees ) ) {
|
230 |
|
231 |
// Remove fees that belong to a specific download but are not in the cart
|
245 |
|
246 |
}
|
247 |
|
248 |
+
// Allow 3rd parties to process the fees before returning them
|
249 |
+
return apply_filters( 'edd_fees_get_fees', ! empty( $fees ) ? $fees : array(), $this );
|
250 |
}
|
251 |
|
252 |
/**
|
254 |
*
|
255 |
* @since 1.5
|
256 |
*
|
257 |
+
* @param string $id ID of the fee to get
|
258 |
+
* @return array|bool The fee array when available, false otherwise
|
259 |
*/
|
260 |
public function get_fee( $id = '' ) {
|
261 |
$fees = $this->get_fees( 'all' );
|
276 |
* @param string $type Fee type, "fee" or "item"
|
277 |
* @uses EDD_Fees::get_fees()
|
278 |
* @uses EDD_Fees::has_fees()
|
279 |
+
* @return float Total fee amount
|
280 |
*/
|
281 |
public function type_total( $type = 'fee' ) {
|
282 |
$fees = $this->get_fees( $type );
|
301 |
* @uses EDD_Fees::get_fees()
|
302 |
* @uses EDD_Fees::has_fees()
|
303 |
* @param int $download_id The download ID whose fees to retrieve
|
304 |
+
* @return float Total fee amount
|
305 |
*/
|
306 |
public function total( $download_id = 0 ) {
|
307 |
$fees = $this->get_fees( 'all', $download_id );
|
324 |
* @uses EDD_Session::set()
|
325 |
* @param array $payment_meta The meta data to store with the payment
|
326 |
* @param array $payment_data The info sent from process-purchase.php
|
327 |
+
* @return array Return the payment meta with the fees added
|
328 |
*/
|
329 |
public function record_fees( $payment_meta, $payment_data ) {
|
330 |
if ( $this->has_fees( 'all' ) ) {
|
includes/class-edd-html-elements.php
CHANGED
@@ -406,7 +406,7 @@ class EDD_HTML_Elements {
|
|
406 |
*
|
407 |
* @param array $args
|
408 |
*
|
409 |
-
* @return string
|
410 |
*/
|
411 |
public function checkbox( $args = array() ) {
|
412 |
$defaults = array(
|
@@ -443,7 +443,7 @@ class EDD_HTML_Elements {
|
|
443 |
* @return string Text field
|
444 |
*/
|
445 |
public function text( $args = array() ) {
|
446 |
-
// Backwards
|
447 |
if ( func_num_args() > 1 ) {
|
448 |
$args = func_get_args();
|
449 |
|
@@ -583,7 +583,7 @@ class EDD_HTML_Elements {
|
|
583 |
|
584 |
$output = '<span class="edd_user_search_wrap">';
|
585 |
$output .= $this->text( $args );
|
586 |
-
$output .= '<span class="edd_user_search_results hidden"><a class="edd-ajax-user-cancel"
|
587 |
$output .= '</span>';
|
588 |
|
589 |
return $output;
|
406 |
*
|
407 |
* @param array $args
|
408 |
*
|
409 |
+
* @return string Checkbox HTML code
|
410 |
*/
|
411 |
public function checkbox( $args = array() ) {
|
412 |
$defaults = array(
|
443 |
* @return string Text field
|
444 |
*/
|
445 |
public function text( $args = array() ) {
|
446 |
+
// Backwards compatibility
|
447 |
if ( func_num_args() > 1 ) {
|
448 |
$args = func_get_args();
|
449 |
|
583 |
|
584 |
$output = '<span class="edd_user_search_wrap">';
|
585 |
$output .= $this->text( $args );
|
586 |
+
$output .= '<span class="edd_user_search_results hidden"><a class="edd-ajax-user-cancel" aria-label="' . __( 'Cancel', 'easy-digital-downloads' ) . '" href="#">x</a><span></span></span>';
|
587 |
$output .= '</span>';
|
588 |
|
589 |
return $output;
|
includes/class-edd-license-handler.php
CHANGED
@@ -30,7 +30,7 @@ class EDD_License {
|
|
30 |
* Class constructor
|
31 |
*
|
32 |
* @param string $_file
|
33 |
-
* @param string $
|
34 |
* @param string $_version
|
35 |
* @param string $_author
|
36 |
* @param string $_optname
|
@@ -160,7 +160,7 @@ class EDD_License {
|
|
160 |
$edd_license_settings = array(
|
161 |
array(
|
162 |
'id' => $this->item_shortname . '_license_key',
|
163 |
-
'name' => sprintf( __( '%1$s
|
164 |
'desc' => '',
|
165 |
'type' => 'license_key',
|
166 |
'options' => array( 'is_valid_license_option' => $this->item_shortname . '_license_active' ),
|
@@ -193,7 +193,7 @@ class EDD_License {
|
|
193 |
}
|
194 |
|
195 |
echo '<p>' . sprintf(
|
196 |
-
__( 'Enter your extension license keys here to receive updates for purchased extensions. If your license key has expired, please <a href="%s" target="_blank"
|
197 |
'http://docs.easydigitaldownloads.com/article/1000-license-renewal'
|
198 |
) . '</p>';
|
199 |
|
@@ -418,7 +418,7 @@ class EDD_License {
|
|
418 |
if( empty( $_GET['tab'] ) || 'licenses' !== $_GET['tab'] ) {
|
419 |
|
420 |
$messages[] = sprintf(
|
421 |
-
__( 'You have invalid or expired license keys for Easy Digital Downloads. Please go to the <a href="%s"
|
422 |
admin_url( 'edit.php?post_type=download&page=edd-settings&tab=licenses' )
|
423 |
);
|
424 |
|
30 |
* Class constructor
|
31 |
*
|
32 |
* @param string $_file
|
33 |
+
* @param string $_item
|
34 |
* @param string $_version
|
35 |
* @param string $_author
|
36 |
* @param string $_optname
|
160 |
$edd_license_settings = array(
|
161 |
array(
|
162 |
'id' => $this->item_shortname . '_license_key',
|
163 |
+
'name' => sprintf( __( '%1$s', 'easy-digital-downloads' ), $this->item_name ),
|
164 |
'desc' => '',
|
165 |
'type' => 'license_key',
|
166 |
'options' => array( 'is_valid_license_option' => $this->item_shortname . '_license_active' ),
|
193 |
}
|
194 |
|
195 |
echo '<p>' . sprintf(
|
196 |
+
__( 'Enter your extension license keys here to receive updates for purchased extensions. If your license key has expired, please <a href="%s" target="_blank">renew your license</a>.', 'easy-digital-downloads' ),
|
197 |
'http://docs.easydigitaldownloads.com/article/1000-license-renewal'
|
198 |
) . '</p>';
|
199 |
|
418 |
if( empty( $_GET['tab'] ) || 'licenses' !== $_GET['tab'] ) {
|
419 |
|
420 |
$messages[] = sprintf(
|
421 |
+
__( 'You have invalid or expired license keys for Easy Digital Downloads. Please go to the <a href="%s">Licenses page</a> to correct this issue.', 'easy-digital-downloads' ),
|
422 |
admin_url( 'edit.php?post_type=download&page=edd-settings&tab=licenses' )
|
423 |
);
|
424 |
|
includes/class-edd-roles.php
CHANGED
@@ -187,7 +187,8 @@ class EDD_Roles {
|
|
187 |
"assign_{$capability_type}_terms",
|
188 |
|
189 |
// Custom
|
190 |
-
"view_{$capability_type}_stats"
|
|
|
191 |
);
|
192 |
}
|
193 |
|
187 |
"assign_{$capability_type}_terms",
|
188 |
|
189 |
// Custom
|
190 |
+
"view_{$capability_type}_stats",
|
191 |
+
"import_{$capability_type}s",
|
192 |
);
|
193 |
}
|
194 |
|
includes/class-edd-session.php
CHANGED
@@ -197,7 +197,7 @@ class EDD_Session {
|
|
197 |
*
|
198 |
* @access public
|
199 |
* @since 1.8
|
200 |
-
* @param
|
201 |
* @return void
|
202 |
*/
|
203 |
public function set_cart_cookie( $set = true ) {
|
@@ -230,7 +230,7 @@ class EDD_Session {
|
|
230 |
* @access public
|
231 |
* @since 1.9
|
232 |
* @param int $exp Default expiration (1 hour)
|
233 |
-
* @return int
|
234 |
*/
|
235 |
public function set_expiration_time( $exp ) {
|
236 |
return ( 30 * 60 * 24 );
|
@@ -378,4 +378,4 @@ class EDD_Session {
|
|
378 |
}
|
379 |
}
|
380 |
|
381 |
-
}
|
197 |
*
|
198 |
* @access public
|
199 |
* @since 1.8
|
200 |
+
* @param bool $set Whether to set or destroy
|
201 |
* @return void
|
202 |
*/
|
203 |
public function set_cart_cookie( $set = true ) {
|
230 |
* @access public
|
231 |
* @since 1.9
|
232 |
* @param int $exp Default expiration (1 hour)
|
233 |
+
* @return int Cookie expiration time
|
234 |
*/
|
235 |
public function set_expiration_time( $exp ) {
|
236 |
return ( 30 * 60 * 24 );
|
378 |
}
|
379 |
}
|
380 |
|
381 |
+
}
|
includes/deprecated-functions.php
CHANGED
@@ -543,4 +543,22 @@ function edd_verify_download_link( $download_id = 0, $key = '', $email = '', $ex
|
|
543 |
}
|
544 |
// Payment not verified
|
545 |
return false;
|
546 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
543 |
}
|
544 |
// Payment not verified
|
545 |
return false;
|
546 |
+
}
|
547 |
+
|
548 |
+
/**
|
549 |
+
* Get Success Page URL
|
550 |
+
*
|
551 |
+
* @param string $query_string
|
552 |
+
* @access public
|
553 |
+
* @since 1.0
|
554 |
+
* @deprecated 2.6 Please avoid usage of this function in favor of edd_get_success_page_uri()
|
555 |
+
* @return string
|
556 |
+
*/
|
557 |
+
function edd_get_success_page_url( $query_string = null ) {
|
558 |
+
|
559 |
+
$backtrace = debug_backtrace();
|
560 |
+
|
561 |
+
_edd_deprecated_function( __FUNCTION__, '2.6', 'edd_get_success_page_uri()', $backtrace );
|
562 |
+
|
563 |
+
return apply_filters( 'edd_success_page_url', edd_get_success_page_uri( $query_string ) );
|
564 |
+
}
|
includes/discount-functions.php
CHANGED
@@ -594,6 +594,7 @@ function edd_is_discount_expired( $code_id = null ) {
|
|
594 |
if ( $expiration < current_time( 'timestamp' ) ) {
|
595 |
// Discount is expired
|
596 |
edd_update_discount_status( $code_id, 'inactive' );
|
|
|
597 |
$return = true;
|
598 |
}
|
599 |
}
|
@@ -1026,6 +1027,12 @@ function edd_increase_discount_usage( $code ) {
|
|
1026 |
|
1027 |
update_post_meta( $id, '_edd_discount_uses', $uses );
|
1028 |
|
|
|
|
|
|
|
|
|
|
|
|
|
1029 |
do_action( 'edd_discount_increase_use_count', $uses, $id, $code );
|
1030 |
|
1031 |
return $uses;
|
@@ -1061,6 +1068,12 @@ function edd_decrease_discount_usage( $code ) {
|
|
1061 |
|
1062 |
update_post_meta( $id, '_edd_discount_uses', $uses );
|
1063 |
|
|
|
|
|
|
|
|
|
|
|
|
|
1064 |
do_action( 'edd_discount_decrease_use_count', $uses, $id, $code );
|
1065 |
|
1066 |
return $uses;
|
@@ -1207,9 +1220,10 @@ function edd_get_cart_discounted_amount( $discounts = false ) {
|
|
1207 |
*
|
1208 |
* @since 1.9
|
1209 |
* @param array $item Cart item array
|
|
|
1210 |
* @return float The discounted amount
|
1211 |
*/
|
1212 |
-
function edd_get_cart_item_discount_amount( $item = array() ) {
|
1213 |
|
1214 |
global $edd_is_last_cart_item, $edd_flat_discount_total;
|
1215 |
|
@@ -1231,8 +1245,7 @@ function edd_get_cart_item_discount_amount( $item = array() ) {
|
|
1231 |
$price = edd_get_cart_item_price( $item['id'], $item['options'] );
|
1232 |
$discounted_price = $price;
|
1233 |
|
1234 |
-
|
1235 |
-
$discounts = edd_get_cart_discounts();
|
1236 |
|
1237 |
if( $discounts ) {
|
1238 |
|
@@ -1256,7 +1269,9 @@ function edd_get_cart_item_discount_amount( $item = array() ) {
|
|
1256 |
foreach ( $reqs as $download_id ) {
|
1257 |
|
1258 |
if ( $download_id == $item['id'] && ! in_array( $item['id'], $excluded_products ) ) {
|
|
|
1259 |
$discounted_price -= $price - edd_get_discounted_amount( $discount, $price );
|
|
|
1260 |
}
|
1261 |
|
1262 |
}
|
@@ -1297,12 +1312,17 @@ function edd_get_cart_item_discount_amount( $item = array() ) {
|
|
1297 |
} else {
|
1298 |
|
1299 |
$discounted_price -= $price - edd_get_discounted_amount( $discount, $price );
|
|
|
1300 |
}
|
1301 |
|
1302 |
}
|
1303 |
|
1304 |
}
|
1305 |
|
|
|
|
|
|
|
|
|
1306 |
}
|
1307 |
|
1308 |
$amount = ( $price - apply_filters( 'edd_get_cart_item_discounted_amount', $discounted_price, $discounts, $item, $price ) );
|
@@ -1497,3 +1517,106 @@ function edd_apply_preset_discount() {
|
|
1497 |
EDD()->session->set( 'preset_discount', null );
|
1498 |
}
|
1499 |
add_action( 'init', 'edd_apply_preset_discount', 999 );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
594 |
if ( $expiration < current_time( 'timestamp' ) ) {
|
595 |
// Discount is expired
|
596 |
edd_update_discount_status( $code_id, 'inactive' );
|
597 |
+
update_post_meta( $code_id, '_edd_discount_status', 'expired' );
|
598 |
$return = true;
|
599 |
}
|
600 |
}
|
1027 |
|
1028 |
update_post_meta( $id, '_edd_discount_uses', $uses );
|
1029 |
|
1030 |
+
$max_uses = edd_get_discount_max_uses( $id );
|
1031 |
+
if ( $max_uses == $uses ) {
|
1032 |
+
edd_update_discount_status( $id, 'inactive' );
|
1033 |
+
update_post_meta( $id, '_edd_discount_status', 'inactive' );
|
1034 |
+
}
|
1035 |
+
|
1036 |
do_action( 'edd_discount_increase_use_count', $uses, $id, $code );
|
1037 |
|
1038 |
return $uses;
|
1068 |
|
1069 |
update_post_meta( $id, '_edd_discount_uses', $uses );
|
1070 |
|
1071 |
+
$max_uses = edd_get_discount_max_uses( $id );
|
1072 |
+
if ( $max_uses > $uses ) {
|
1073 |
+
edd_update_discount_status( $id, 'active' );
|
1074 |
+
update_post_meta( $id, '_edd_discount_status', 'active' );
|
1075 |
+
}
|
1076 |
+
|
1077 |
do_action( 'edd_discount_decrease_use_count', $uses, $id, $code );
|
1078 |
|
1079 |
return $uses;
|
1220 |
*
|
1221 |
* @since 1.9
|
1222 |
* @param array $item Cart item array
|
1223 |
+
* @param bool|string $discount False to use the cart discounts or a string to check with a discount code
|
1224 |
* @return float The discounted amount
|
1225 |
*/
|
1226 |
+
function edd_get_cart_item_discount_amount( $item = array(), $discount = false ) {
|
1227 |
|
1228 |
global $edd_is_last_cart_item, $edd_flat_discount_total;
|
1229 |
|
1245 |
$price = edd_get_cart_item_price( $item['id'], $item['options'] );
|
1246 |
$discounted_price = $price;
|
1247 |
|
1248 |
+
$discounts = false === $discount ? edd_get_cart_discounts() : array( $discount );
|
|
|
1249 |
|
1250 |
if( $discounts ) {
|
1251 |
|
1269 |
foreach ( $reqs as $download_id ) {
|
1270 |
|
1271 |
if ( $download_id == $item['id'] && ! in_array( $item['id'], $excluded_products ) ) {
|
1272 |
+
|
1273 |
$discounted_price -= $price - edd_get_discounted_amount( $discount, $price );
|
1274 |
+
|
1275 |
}
|
1276 |
|
1277 |
}
|
1312 |
} else {
|
1313 |
|
1314 |
$discounted_price -= $price - edd_get_discounted_amount( $discount, $price );
|
1315 |
+
|
1316 |
}
|
1317 |
|
1318 |
}
|
1319 |
|
1320 |
}
|
1321 |
|
1322 |
+
if( $discounted_price < 0 ) {
|
1323 |
+
$discounted_price = 0;
|
1324 |
+
}
|
1325 |
+
|
1326 |
}
|
1327 |
|
1328 |
$amount = ( $price - apply_filters( 'edd_get_cart_item_discounted_amount', $discounted_price, $discounts, $item, $price ) );
|
1517 |
EDD()->session->set( 'preset_discount', null );
|
1518 |
}
|
1519 |
add_action( 'init', 'edd_apply_preset_discount', 999 );
|
1520 |
+
|
1521 |
+
/**
|
1522 |
+
* Updates discounts that are expired or at max use (that aren't already marked as so) as inactive or expired
|
1523 |
+
*
|
1524 |
+
* @since 2.6
|
1525 |
+
* @return void
|
1526 |
+
*/
|
1527 |
+
function edd_discount_status_cleanup() {
|
1528 |
+
global $wpdb;
|
1529 |
+
|
1530 |
+
// We only want to get 25 active discounts to check their status per step here
|
1531 |
+
$cron_discount_number = apply_filters( 'edd_discount_status_cleanup_count', 25 );
|
1532 |
+
$discount_ids_to_update = array();
|
1533 |
+
$needs_inactive_meta = array();
|
1534 |
+
$needs_expired_meta = array();
|
1535 |
+
|
1536 |
+
// start by getting the last 25 that hit their maximum usage
|
1537 |
+
$args = array(
|
1538 |
+
'post_status' => array( 'active' ),
|
1539 |
+
'posts_per_page' => $cron_discount_number,
|
1540 |
+
'order' => 'ASC',
|
1541 |
+
'meta_query' => array(
|
1542 |
+
'relation' => 'AND',
|
1543 |
+
array(
|
1544 |
+
'key' => '_edd_discount_uses',
|
1545 |
+
'value' => 'mt1.meta_value',
|
1546 |
+
'compare' => '>=',
|
1547 |
+
'type' => 'NUMERIC',
|
1548 |
+
),
|
1549 |
+
array(
|
1550 |
+
'key' => '_edd_discount_max_uses',
|
1551 |
+
'value' => array( '', 0 ),
|
1552 |
+
'compare' => 'NOT IN',
|
1553 |
+
),
|
1554 |
+
array(
|
1555 |
+
'key' => '_edd_discount_uses',
|
1556 |
+
'value' => '',
|
1557 |
+
'compare' => '!=',
|
1558 |
+
),
|
1559 |
+
),
|
1560 |
+
);
|
1561 |
+
|
1562 |
+
$discounts = edd_get_discounts( $args );
|
1563 |
+
|
1564 |
+
if ( $discounts ) {
|
1565 |
+
foreach ( $discounts as $discount ) {
|
1566 |
+
|
1567 |
+
$discount_ids_to_update[] = (int) $discount->ID;
|
1568 |
+
$needs_inactive_meta[] = (int) $discount->ID;
|
1569 |
+
|
1570 |
+
}
|
1571 |
+
}
|
1572 |
+
|
1573 |
+
// Now lets look at the last 25 that hit their expiration without hitting their limit
|
1574 |
+
$args = array(
|
1575 |
+
'post_status' => array( 'active' ),
|
1576 |
+
'posts_per_page' => $cron_discount_number,
|
1577 |
+
'order' => 'ASC',
|
1578 |
+
'meta_query' => array(
|
1579 |
+
'relation' => 'AND',
|
1580 |
+
array(
|
1581 |
+
'key' => '_edd_discount_expiration',
|
1582 |
+
'value' => '',
|
1583 |
+
'compare' => '!=',
|
1584 |
+
),
|
1585 |
+
array(
|
1586 |
+
'key' => '_edd_discount_expiration',
|
1587 |
+
'value' => current_time( 'mysql' ),
|
1588 |
+
'compare' => '<',
|
1589 |
+
),
|
1590 |
+
),
|
1591 |
+
);
|
1592 |
+
|
1593 |
+
$discounts = edd_get_discounts( $args );
|
1594 |
+
|
1595 |
+
if ( $discounts ) {
|
1596 |
+
foreach ( $discounts as $discount ) {
|
1597 |
+
|
1598 |
+
$discount_ids_to_update[] = (int) $discount->ID;
|
1599 |
+
if ( ! in_array( $discount->ID, $needs_inactive_meta ) ) {
|
1600 |
+
$needs_expired_meta[] = (int) $discount->ID;
|
1601 |
+
}
|
1602 |
+
|
1603 |
+
}
|
1604 |
+
}
|
1605 |
+
|
1606 |
+
$discount_ids_to_update = array_unique( $discount_ids_to_update );
|
1607 |
+
$discount_ids_string = "'" . implode( "','", $discount_ids_to_update ) . "'";
|
1608 |
+
$sql = "UPDATE $wpdb->posts SET post_status = 'inactive' WHERE ID IN ($discount_ids_string)";
|
1609 |
+
$wpdb->query( $sql );
|
1610 |
+
|
1611 |
+
$needs_inactive_meta = array_unique( $needs_inactive_meta );
|
1612 |
+
$inactive_ids = "'" . implode( "','", $needs_inactive_meta ) . "'";
|
1613 |
+
$sql = "UPDATE $wpdb->postmeta SET meta_value = 'inactive' WHERE meta_key = '_edd_discount_status' AND post_id IN ($inactive_ids)";
|
1614 |
+
$wpdb->query( $sql );
|
1615 |
+
|
1616 |
+
$needs_expired_meta = array_unique( $needs_expired_meta );
|
1617 |
+
$expired_ids = "'" . implode( "','", $needs_expired_meta ) . "'";
|
1618 |
+
$sql = "UPDATE $wpdb->postmeta SET meta_value = 'inactive' WHERE meta_key = '_edd_discount_status' AND post_id IN ($expired_ids)";
|
1619 |
+
$wpdb->query( $sql );
|
1620 |
+
|
1621 |
+
}
|
1622 |
+
add_action( 'edd_daily_scheduled_events', 'edd_discount_status_cleanup' );
|
includes/download-functions.php
CHANGED
@@ -132,7 +132,7 @@ function edd_is_free_download( $download_id = 0, $price_id = false ) {
|
|
132 |
*
|
133 |
* @since 1.0
|
134 |
* @param int $download_id ID number of the download to retrieve a price for
|
135 |
-
* @return mixed
|
136 |
*/
|
137 |
function edd_get_download_price( $download_id = 0 ) {
|
138 |
|
@@ -312,7 +312,7 @@ function edd_get_price_option_name( $download_id = 0, $price_id = 0, $payment_id
|
|
312 |
* @since 1.8.2
|
313 |
* @param int $download_id ID of the download
|
314 |
* @param int $price_id ID of the price option
|
315 |
-
* @param int
|
316 |
* @return float $amount Amount of the price option
|
317 |
*/
|
318 |
function edd_get_price_option_amount( $download_id = 0, $price_id = 0 ) {
|
132 |
*
|
133 |
* @since 1.0
|
134 |
* @param int $download_id ID number of the download to retrieve a price for
|
135 |
+
* @return mixed|string|int Price of the download
|
136 |
*/
|
137 |
function edd_get_download_price( $download_id = 0 ) {
|
138 |
|
312 |
* @since 1.8.2
|
313 |
* @param int $download_id ID of the download
|
314 |
* @param int $price_id ID of the price option
|
315 |
+
* @param int $payment_id ID of the payment
|
316 |
* @return float $amount Amount of the price option
|
317 |
*/
|
318 |
function edd_get_price_option_amount( $download_id = 0, $price_id = 0 ) {
|
includes/emails/class-edd-email-tags.php
CHANGED
@@ -843,7 +843,7 @@ function edd_email_tag_receipt_link( $payment_id ) {
|
|
843 |
'payment_key' => edd_get_payment_key( $payment_id ),
|
844 |
'edd_action' => 'view_receipt'
|
845 |
), home_url() ) );
|
846 |
-
$formatted = sprintf( __( '%1$sView it in your browser %2$s', '
|
847 |
|
848 |
if ( edd_get_option( 'email_template' ) !== 'none' ) {
|
849 |
return $formatted;
|
@@ -857,7 +857,7 @@ function edd_email_tag_receipt_link( $payment_id ) {
|
|
857 |
* Adds a list of any discount codes applied to this purchase
|
858 |
*
|
859 |
* @since 2.0
|
860 |
-
* @param
|
861 |
* @return string $discount_codes
|
862 |
*/
|
863 |
function edd_email_tag_discount_codes( $payment_id ) {
|
843 |
'payment_key' => edd_get_payment_key( $payment_id ),
|
844 |
'edd_action' => 'view_receipt'
|
845 |
), home_url() ) );
|
846 |
+
$formatted = sprintf( __( '%1$sView it in your browser %2$s', 'easy-digital-downloads' ), '<a href="' . $receipt_url . '">', '»</a>' );
|
847 |
|
848 |
if ( edd_get_option( 'email_template' ) !== 'none' ) {
|
849 |
return $formatted;
|
857 |
* Adds a list of any discount codes applied to this purchase
|
858 |
*
|
859 |
* @since 2.0
|
860 |
+
* @param int $payment_id
|
861 |
* @return string $discount_codes
|
862 |
*/
|
863 |
function edd_email_tag_discount_codes( $payment_id ) {
|
includes/emails/template.php
CHANGED
@@ -62,7 +62,7 @@ function edd_email_preview_template_tags( $message ) {
|
|
62 |
|
63 |
$price = edd_currency_filter( edd_format_amount( 10.50 ) );
|
64 |
|
65 |
-
$gateway =
|
66 |
|
67 |
$receipt_id = strtolower( md5( uniqid() ) );
|
68 |
|
@@ -90,7 +90,7 @@ function edd_email_preview_template_tags( $message ) {
|
|
90 |
$message = str_replace( '{sitename}', get_bloginfo( 'name' ), $message );
|
91 |
$message = str_replace( '{product_notes}', $notes, $message );
|
92 |
$message = str_replace( '{payment_id}', $payment_id, $message );
|
93 |
-
$message = str_replace( '{receipt_link}',
|
94 |
|
95 |
$message = apply_filters( 'edd_email_preview_template_tags', $message );
|
96 |
|
@@ -110,7 +110,7 @@ function edd_email_template_preview() {
|
|
110 |
|
111 |
ob_start();
|
112 |
?>
|
113 |
-
<a href="<?php echo esc_url( add_query_arg( array( 'edd_action' => 'preview_email' ), home_url() ) ); ?>" class="button-secondary" target="_blank"
|
114 |
<a href="<?php echo wp_nonce_url( add_query_arg( array( 'edd_action' => 'send_test_email' ) ), 'edd-test-email' ); ?>" class="button-secondary"><?php _e( 'Send Test Email', 'easy-digital-downloads' ); ?></a>
|
115 |
<?php
|
116 |
echo ob_get_clean();
|
@@ -275,4 +275,4 @@ function edd_render_receipt_in_browser() {
|
|
275 |
echo ob_get_clean();
|
276 |
die();
|
277 |
}
|
278 |
-
add_action( 'edd_view_receipt', 'edd_render_receipt_in_browser' );
|
62 |
|
63 |
$price = edd_currency_filter( edd_format_amount( 10.50 ) );
|
64 |
|
65 |
+
$gateway = edd_get_gateway_admin_label( edd_get_default_gateway() );
|
66 |
|
67 |
$receipt_id = strtolower( md5( uniqid() ) );
|
68 |
|
90 |
$message = str_replace( '{sitename}', get_bloginfo( 'name' ), $message );
|
91 |
$message = str_replace( '{product_notes}', $notes, $message );
|
92 |
$message = str_replace( '{payment_id}', $payment_id, $message );
|
93 |
+
$message = str_replace( '{receipt_link}', edd_email_tag_receipt_link( $payment_id ), $message );
|
94 |
|
95 |
$message = apply_filters( 'edd_email_preview_template_tags', $message );
|
96 |
|
110 |
|
111 |
ob_start();
|
112 |
?>
|
113 |
+
<a href="<?php echo esc_url( add_query_arg( array( 'edd_action' => 'preview_email' ), home_url() ) ); ?>" class="button-secondary" target="_blank"><?php _e( 'Preview Purchase Receipt', 'easy-digital-downloads' ); ?></a>
|
114 |
<a href="<?php echo wp_nonce_url( add_query_arg( array( 'edd_action' => 'send_test_email' ) ), 'edd-test-email' ); ?>" class="button-secondary"><?php _e( 'Send Test Email', 'easy-digital-downloads' ); ?></a>
|
115 |
<?php
|
116 |
echo ob_get_clean();
|
275 |
echo ob_get_clean();
|
276 |
die();
|
277 |
}
|
278 |
+
add_action( 'edd_view_receipt', 'edd_render_receipt_in_browser' );
|
includes/gateways/actions.php
CHANGED
@@ -50,9 +50,9 @@ add_action( 'wp_ajax_nopriv_edd_load_gateway', 'edd_load_ajax_gateway' );
|
|
50 |
function edd_no_gateway_error() {
|
51 |
$gateways = edd_get_enabled_payment_gateways();
|
52 |
|
53 |
-
if ( empty( $gateways ) )
|
54 |
edd_set_error( 'no_gateways', __( 'You must enable a payment gateway to use Easy Digital Downloads', 'easy-digital-downloads' ) );
|
55 |
else
|
56 |
edd_unset_error( 'no_gateways' );
|
57 |
}
|
58 |
-
add_action( 'init', 'edd_no_gateway_error' );
|
50 |
function edd_no_gateway_error() {
|
51 |
$gateways = edd_get_enabled_payment_gateways();
|
52 |
|
53 |
+
if ( empty( $gateways ) && edd_get_cart_total() > 0 )
|
54 |
edd_set_error( 'no_gateways', __( 'You must enable a payment gateway to use Easy Digital Downloads', 'easy-digital-downloads' ) );
|
55 |
else
|
56 |
edd_unset_error( 'no_gateways' );
|
57 |
}
|
58 |
+
add_action( 'init', 'edd_no_gateway_error' );
|
includes/gateways/amazon-payments.php
CHANGED
@@ -634,8 +634,8 @@ final class EDD_Amazon_Payments {
|
|
634 |
<?php endif; ?>
|
635 |
<div id="edd-amazon-wallet-box"></div>
|
636 |
<script>
|
637 |
-
var
|
638 |
-
if( '1' ==
|
639 |
new OffAmazonPayments.Widgets.AddressBook({
|
640 |
sellerId: edd_amazon.sellerId,
|
641 |
amazonOrderReferenceId: edd_amazon.referenceID,
|
@@ -650,7 +650,7 @@ final class EDD_Amazon_Payments {
|
|
650 |
reference_id : edd_amazon.referenceID
|
651 |
},
|
652 |
dataType: "json",
|
653 |
-
url:
|
654 |
xhrFields: {
|
655 |
withCredentials: true
|
656 |
},
|
634 |
<?php endif; ?>
|
635 |
<div id="edd-amazon-wallet-box"></div>
|
636 |
<script>
|
637 |
+
var edd_global_vars;
|
638 |
+
if( '1' == edd_global_vars.taxes_enabled ) {
|
639 |
new OffAmazonPayments.Widgets.AddressBook({
|
640 |
sellerId: edd_amazon.sellerId,
|
641 |
amazonOrderReferenceId: edd_amazon.referenceID,
|
650 |
reference_id : edd_amazon.referenceID
|
651 |
},
|
652 |
dataType: "json",
|
653 |
+
url: edd_global_vars.ajaxurl,
|
654 |
xhrFields: {
|
655 |
withCredentials: true
|
656 |
},
|
includes/gateways/paypal-standard.php
CHANGED
@@ -22,6 +22,127 @@ if ( ! defined( 'ABSPATH' ) ) exit;
|
|
22 |
*/
|
23 |
add_action( 'edd_paypal_cc_form', '__return_false' );
|
24 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
25 |
/**
|
26 |
* Process PayPal Purchase
|
27 |
*
|
@@ -280,14 +401,14 @@ function edd_process_paypal_ipn() {
|
|
280 |
);
|
281 |
|
282 |
// Get response
|
283 |
-
$api_response = wp_remote_post( edd_get_paypal_redirect(), $remote_post_vars );
|
284 |
|
285 |
if ( is_wp_error( $api_response ) ) {
|
286 |
edd_record_gateway_error( __( 'IPN Error', 'easy-digital-downloads' ), sprintf( __( 'Invalid IPN verification response. IPN data: %s', 'easy-digital-downloads' ), json_encode( $api_response ) ) );
|
287 |
return; // Something went wrong
|
288 |
}
|
289 |
|
290 |
-
if ( $api_response
|
291 |
edd_record_gateway_error( __( 'IPN Error', 'easy-digital-downloads' ), sprintf( __( 'Invalid IPN verification response. IPN data: %s', 'easy-digital-downloads' ), json_encode( $api_response ) ) );
|
292 |
return; // Response not okay
|
293 |
}
|
@@ -295,8 +416,9 @@ function edd_process_paypal_ipn() {
|
|
295 |
}
|
296 |
|
297 |
// Check if $post_data_array has been populated
|
298 |
-
if ( ! is_array( $encoded_data_array ) && !empty( $encoded_data_array ) )
|
299 |
return;
|
|
|
300 |
|
301 |
$defaults = array(
|
302 |
'txn_type' => '',
|
@@ -334,16 +456,17 @@ function edd_process_paypal_web_accept_and_cart( $data, $payment_id ) {
|
|
334 |
return;
|
335 |
}
|
336 |
|
|
|
|
|
337 |
// Collect payment details
|
338 |
$purchase_key = isset( $data['invoice'] ) ? $data['invoice'] : $data['item_number'];
|
339 |
$paypal_amount = $data['mc_gross'];
|
340 |
$payment_status = strtolower( $data['payment_status'] );
|
341 |
$currency_code = strtolower( $data['mc_currency'] );
|
342 |
$business_email = isset( $data['business'] ) && is_email( $data['business'] ) ? trim( $data['business'] ) : trim( $data['receiver_email'] );
|
343 |
-
$payment_meta = edd_get_payment_meta( $payment_id );
|
344 |
|
345 |
|
346 |
-
if (
|
347 |
return; // this isn't a PayPal standard IPN
|
348 |
}
|
349 |
|
@@ -356,7 +479,7 @@ function edd_process_paypal_web_accept_and_cart( $data, $payment_id ) {
|
|
356 |
}
|
357 |
|
358 |
// Verify payment currency
|
359 |
-
if ( $currency_code != strtolower( $
|
360 |
|
361 |
edd_record_gateway_error( __( 'IPN Error', 'easy-digital-downloads' ), sprintf( __( 'Invalid currency in IPN response. IPN data: %s', 'easy-digital-downloads' ), json_encode( $data ) ), $payment_id );
|
362 |
edd_update_payment_status( $payment_id, 'failed' );
|
@@ -364,32 +487,41 @@ function edd_process_paypal_web_accept_and_cart( $data, $payment_id ) {
|
|
364 |
return;
|
365 |
}
|
366 |
|
367 |
-
if (
|
368 |
|
369 |
// This runs when a Buy Now purchase was made. It bypasses checkout so no personal info is collected until PayPal
|
370 |
|
371 |
-
// No email associated with purchase, so store from PayPal
|
372 |
-
edd_update_payment_meta( $payment_id, '_edd_payment_user_email', $data['payer_email'] );
|
373 |
-
|
374 |
// Setup and store the customers's details
|
375 |
$address = array();
|
376 |
-
$address['line1']
|
377 |
-
$address['city']
|
378 |
-
$address['state']
|
379 |
-
$address['country']
|
380 |
-
$address['zip']
|
381 |
-
|
382 |
-
$
|
383 |
-
|
384 |
-
|
385 |
-
|
386 |
-
|
387 |
-
|
388 |
-
|
389 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
390 |
|
391 |
-
$payment_meta['user_info'] = $user_info;
|
392 |
-
edd_update_payment_meta( $payment_id, '_edd_payment_meta', $payment_meta );
|
393 |
}
|
394 |
|
395 |
if ( $payment_status == 'refunded' || $payment_status == 'reversed' ) {
|
@@ -545,19 +677,18 @@ function edd_process_paypal_refund( $data, $payment_id = 0 ) {
|
|
545 |
* @return string
|
546 |
*/
|
547 |
function edd_get_paypal_redirect( $ssl_check = false ) {
|
|
|
548 |
if ( is_ssl() || ! $ssl_check ) {
|
549 |
-
$
|
550 |
-
} else {
|
551 |
-
$protocal = 'http://';
|
552 |
}
|
553 |
|
554 |
// Check the current payment mode
|
555 |
if ( edd_is_test_mode() ) {
|
556 |
// Test mode
|
557 |
-
$paypal_uri = $
|
558 |
} else {
|
559 |
// Live mode
|
560 |
-
$paypal_uri = $
|
561 |
}
|
562 |
|
563 |
return apply_filters( 'edd_paypal_uri', $paypal_uri );
|
@@ -653,3 +784,201 @@ function edd_paypal_link_transaction_id( $transaction_id, $payment_id ) {
|
|
653 |
|
654 |
}
|
655 |
add_filter( 'edd_payment_details_transaction_id-paypal', 'edd_paypal_link_transaction_id', 10, 2 );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
22 |
*/
|
23 |
add_action( 'edd_paypal_cc_form', '__return_false' );
|
24 |
|
25 |
+
/**
|
26 |
+
* Register the PayPal Standard gateway subsection
|
27 |
+
*
|
28 |
+
* @since 2.6
|
29 |
+
* @param array $gateway_sections Current Gateway Tab subsections
|
30 |
+
* @return array Gateway subsections with PayPal Standard
|
31 |
+
*/
|
32 |
+
function edd_register_paypal_gateway_section( $gateway_sections ) {
|
33 |
+
$gateway_sections['paypal'] = __( 'PayPal Standard', 'easy-digital-downloads' );
|
34 |
+
|
35 |
+
return $gateway_sections;
|
36 |
+
}
|
37 |
+
add_filter( 'edd_settings_sections_gateways', 'edd_register_paypal_gateway_section', 1, 1 );
|
38 |
+
|
39 |
+
/**
|
40 |
+
* Registers the PayPal Standard settings for the PayPal Standard subsection
|
41 |
+
*
|
42 |
+
* @since 2.6
|
43 |
+
* @param array $gateway_settings Gateway tab settings
|
44 |
+
* @return array Gateway tab settings with the PayPal Standard settings
|
45 |
+
*/
|
46 |
+
function edd_register_paypal_gateway_settings( $gateway_settings ) {
|
47 |
+
|
48 |
+
$paypal_settings = array (
|
49 |
+
'paypal_settings' => array(
|
50 |
+
'id' => 'paypal_settings',
|
51 |
+
'name' => '<strong>' . __( 'PayPal Standard Settings', 'easy-digital-downloads' ) . '</strong>',
|
52 |
+
'type' => 'header',
|
53 |
+
),
|
54 |
+
'paypal_email' => array(
|
55 |
+
'id' => 'paypal_email',
|
56 |
+
'name' => __( 'PayPal Email', 'easy-digital-downloads' ),
|
57 |
+
'desc' => __( 'Enter your PayPal account\'s email', 'easy-digital-downloads' ),
|
58 |
+
'type' => 'text',
|
59 |
+
'size' => 'regular',
|
60 |
+
),
|
61 |
+
'paypal_page_style' => array(
|
62 |
+
'id' => 'paypal_page_style',
|
63 |
+
'name' => __( 'PayPal Page Style', 'easy-digital-downloads' ),
|
64 |
+
'desc' => __( 'Enter the name of the page style to use, or leave blank for default', 'easy-digital-downloads' ),
|
65 |
+
'type' => 'text',
|
66 |
+
'size' => 'regular',
|
67 |
+
),
|
68 |
+
);
|
69 |
+
|
70 |
+
$disable_ipn_desc = sprintf(
|
71 |
+
__( 'If payments are not getting marked as complete, then check this box. This forces the site to use a slightly less secure method of verifying purchases. See our <a href="%s" target="_blank">FAQ</a> for further information.', 'easy-digital-downloads' ),
|
72 |
+
'http://docs.easydigitaldownloads.com/article/190-payments-not-marked-as-complete'
|
73 |
+
);
|
74 |
+
|
75 |
+
$paypal_settings['disable_paypal_verification'] = array(
|
76 |
+
'id' => 'disable_paypal_verification',
|
77 |
+
'name' => __( 'Disable PayPal IPN Verification', 'easy-digital-downloads' ),
|
78 |
+
'desc' => $disable_ipn_desc,
|
79 |
+
'type' => 'checkbox',
|
80 |
+
);
|
81 |
+
|
82 |
+
$api_key_settings = array(
|
83 |
+
'paypal_api_keys_desc' => array(
|
84 |
+
'id' => 'paypal_api_keys_desc',
|
85 |
+
'name' => __( 'API Credentials', 'easy-digital-downloads' ),
|
86 |
+
'type' => 'descriptive_text',
|
87 |
+
'desc' => sprintf(
|
88 |
+
__( 'API credentials are necessary to process PayPal refunds from inside WordPress. These can be obtained from <a href="%s" target="_blank">your PayPal account</a>.', 'easy-digital-downloads' ),
|
89 |
+
'https://developer.paypal.com/docs/classic/api/apiCredentials/#creating-an-api-signature'
|
90 |
+
)
|
91 |
+
),
|
92 |
+
'paypal_live_api_username' => array(
|
93 |
+
'id' => 'paypal_live_api_username',
|
94 |
+
'name' => __( 'Live API Username', 'easy-digital-downloads' ),
|
95 |
+
'desc' => __( 'Your PayPal live API username. ', 'easy-digital-downloads' ),
|
96 |
+
'type' => 'text',
|
97 |
+
'size' => 'regular'
|
98 |
+
),
|
99 |
+
'paypal_live_api_password' => array(
|
100 |
+
'id' => 'paypal_live_api_password',
|
101 |
+
'name' => __( 'Live API Password', 'easy-digital-downloads' ),
|
102 |
+
'desc' => __( 'Your PayPal live API password.', 'easy-digital-downloads' ),
|
103 |
+
'type' => 'text',
|
104 |
+
'size' => 'regular'
|
105 |
+
),
|
106 |
+
'paypal_live_api_signature' => array(
|
107 |
+
'id' => 'paypal_live_api_signature',
|
108 |
+
'name' => __( 'Live API Signature', 'easy-digital-downloads' ),
|
109 |
+
'desc' => __( 'Your PayPal live API signature.', 'easy-digital-downloads' ),
|
110 |
+
'type' => 'text',
|
111 |
+
'size' => 'regular'
|
112 |
+
),
|
113 |
+
'paypal_test_api_username' => array(
|
114 |
+
'id' => 'paypal_test_api_username',
|
115 |
+
'name' => __( 'Test API Username', 'easy-digital-downloads' ),
|
116 |
+
'desc' => __( 'Your PayPal test API username.', 'easy-digital-downloads' ),
|
117 |
+
'type' => 'text',
|
118 |
+
'size' => 'regular'
|
119 |
+
),
|
120 |
+
'paypal_test_api_password' => array(
|
121 |
+
'id' => 'paypal_test_api_password',
|
122 |
+
'name' => __( 'Test API Password', 'easy-digital-downloads' ),
|
123 |
+
'desc' => __( 'Your PayPal test API password.', 'easy-digital-downloads' ),
|
124 |
+
'type' => 'text',
|
125 |
+
'size' => 'regular'
|
126 |
+
),
|
127 |
+
'paypal_test_api_signature' => array(
|
128 |
+
'id' => 'paypal_test_api_signature',
|
129 |
+
'name' => __( 'Test API Signature', 'easy-digital-downloads' ),
|
130 |
+
'desc' => __( 'Your PayPal test API signature.', 'easy-digital-downloads' ),
|
131 |
+
'type' => 'text',
|
132 |
+
'size' => 'regular'
|
133 |
+
)
|
134 |
+
);
|
135 |
+
|
136 |
+
$paypal_settings = array_merge( $paypal_settings, $api_key_settings );
|
137 |
+
|
138 |
+
$paypal_settings = apply_filters( 'edd_paypal_settings', $paypal_settings );
|
139 |
+
$gateway_settings['paypal'] = $paypal_settings;
|
140 |
+
|
141 |
+
return $gateway_settings;
|
142 |
+
}
|
143 |
+
add_filter( 'edd_settings_gateways', 'edd_register_paypal_gateway_settings', 1, 1 );
|
144 |
+
|
145 |
+
|
146 |
/**
|
147 |
* Process PayPal Purchase
|
148 |
*
|
401 |
);
|
402 |
|
403 |
// Get response
|
404 |
+
$api_response = wp_remote_post( edd_get_paypal_redirect( true ), $remote_post_vars );
|
405 |
|
406 |
if ( is_wp_error( $api_response ) ) {
|
407 |
edd_record_gateway_error( __( 'IPN Error', 'easy-digital-downloads' ), sprintf( __( 'Invalid IPN verification response. IPN data: %s', 'easy-digital-downloads' ), json_encode( $api_response ) ) );
|
408 |
return; // Something went wrong
|
409 |
}
|
410 |
|
411 |
+
if ( wp_remote_retrieve_body( $api_response ) !== 'VERIFIED' && edd_get_option( 'disable_paypal_verification', false ) ) {
|
412 |
edd_record_gateway_error( __( 'IPN Error', 'easy-digital-downloads' ), sprintf( __( 'Invalid IPN verification response. IPN data: %s', 'easy-digital-downloads' ), json_encode( $api_response ) ) );
|
413 |
return; // Response not okay
|
414 |
}
|
416 |
}
|
417 |
|
418 |
// Check if $post_data_array has been populated
|
419 |
+
if ( ! is_array( $encoded_data_array ) && !empty( $encoded_data_array ) ) {
|
420 |
return;
|
421 |
+
}
|
422 |
|
423 |
$defaults = array(
|
424 |
'txn_type' => '',
|
456 |
return;
|
457 |
}
|
458 |
|
459 |
+
$payment = new EDD_Payment( $payment_id );
|
460 |
+
|
461 |
// Collect payment details
|
462 |
$purchase_key = isset( $data['invoice'] ) ? $data['invoice'] : $data['item_number'];
|
463 |
$paypal_amount = $data['mc_gross'];
|
464 |
$payment_status = strtolower( $data['payment_status'] );
|
465 |
$currency_code = strtolower( $data['mc_currency'] );
|
466 |
$business_email = isset( $data['business'] ) && is_email( $data['business'] ) ? trim( $data['business'] ) : trim( $data['receiver_email'] );
|
|
|
467 |
|
468 |
|
469 |
+
if ( $payment->gateway != 'paypal' ) {
|
470 |
return; // this isn't a PayPal standard IPN
|
471 |
}
|
472 |
|
479 |
}
|
480 |
|
481 |
// Verify payment currency
|
482 |
+
if ( $currency_code != strtolower( $payment->currency ) ) {
|
483 |
|
484 |
edd_record_gateway_error( __( 'IPN Error', 'easy-digital-downloads' ), sprintf( __( 'Invalid currency in IPN response. IPN data: %s', 'easy-digital-downloads' ), json_encode( $data ) ), $payment_id );
|
485 |
edd_update_payment_status( $payment_id, 'failed' );
|
487 |
return;
|
488 |
}
|
489 |
|
490 |
+
if ( empty( $payment->email ) ) {
|
491 |
|
492 |
// This runs when a Buy Now purchase was made. It bypasses checkout so no personal info is collected until PayPal
|
493 |
|
|
|
|
|
|
|
494 |
// Setup and store the customers's details
|
495 |
$address = array();
|
496 |
+
$address['line1'] = ! empty( $data['address_street'] ) ? sanitize_text_field( $data['address_street'] ) : false;
|
497 |
+
$address['city'] = ! empty( $data['address_city'] ) ? sanitize_text_field( $data['address_city'] ) : false;
|
498 |
+
$address['state'] = ! empty( $data['address_state'] ) ? sanitize_text_field( $data['address_state'] ) : false;
|
499 |
+
$address['country'] = ! empty( $data['address_country_code'] ) ? sanitize_text_field( $data['address_country_code'] ) : false;
|
500 |
+
$address['zip'] = ! empty( $data['address_zip'] ) ? sanitize_text_field( $data['address_zip'] ) : false;
|
501 |
+
|
502 |
+
$payment->email = sanitize_text_field( $data['payer_email'] );
|
503 |
+
$payment->first_name = sanitize_text_field( $data['first_name'] );
|
504 |
+
$payment->last_name = sanitize_text_field( $data['last_name'] );
|
505 |
+
$payment->address = $address;
|
506 |
+
|
507 |
+
if( empty( $payment->customer_id ) ) {
|
508 |
+
|
509 |
+
$customer = new EDD_Customer( $payment->email );
|
510 |
+
if( ! $customer || $customer->id < 1 ) {
|
511 |
+
|
512 |
+
$customer->create( array(
|
513 |
+
'email' => $payment->email,
|
514 |
+
'name' => $payment->first_name . ' ' . $payment->last_name,
|
515 |
+
'user_id' => $payment->user_id
|
516 |
+
) );
|
517 |
+
|
518 |
+
}
|
519 |
+
|
520 |
+
$payment->customer_id = $customer->id;
|
521 |
+
}
|
522 |
+
|
523 |
+
$payment->save();
|
524 |
|
|
|
|
|
525 |
}
|
526 |
|
527 |
if ( $payment_status == 'refunded' || $payment_status == 'reversed' ) {
|
677 |
* @return string
|
678 |
*/
|
679 |
function edd_get_paypal_redirect( $ssl_check = false ) {
|
680 |
+
$protocol = 'http://';
|
681 |
if ( is_ssl() || ! $ssl_check ) {
|
682 |
+
$protocol = 'https://';
|
|
|
|
|
683 |
}
|
684 |
|
685 |
// Check the current payment mode
|
686 |
if ( edd_is_test_mode() ) {
|
687 |
// Test mode
|
688 |
+
$paypal_uri = $protocol . 'www.sandbox.paypal.com/cgi-bin/webscr';
|
689 |
} else {
|
690 |
// Live mode
|
691 |
+
$paypal_uri = $protocol . 'www.paypal.com/cgi-bin/webscr';
|
692 |
}
|
693 |
|
694 |
return apply_filters( 'edd_paypal_uri', $paypal_uri );
|
784 |
|
785 |
}
|
786 |
add_filter( 'edd_payment_details_transaction_id-paypal', 'edd_paypal_link_transaction_id', 10, 2 );
|
787 |
+
|
788 |
+
/**
|
789 |
+
* Shows checkbox to automatically refund payments made in PayPal.
|
790 |
+
*
|
791 |
+
* @access public
|
792 |
+
* @since 2.6.0
|
793 |
+
*
|
794 |
+
* @param int $payment_id The current payment ID.
|
795 |
+
* @return void
|
796 |
+
*/
|
797 |
+
function edd_paypal_refund_admin_js( $payment_id = 0 ) {
|
798 |
+
|
799 |
+
// If not the proper gateway, return early.
|
800 |
+
if ( 'paypal' !== edd_get_payment_gateway( $payment_id ) ) {
|
801 |
+
return;
|
802 |
+
}
|
803 |
+
|
804 |
+
// If our credentials are not set, return early.
|
805 |
+
$key = edd_get_payment_meta( $payment_id, '_edd_payment_mode', true );
|
806 |
+
$username = edd_get_option( 'paypal_' . $key . '_api_username' );
|
807 |
+
$password = edd_get_option( 'paypal_' . $key . '_api_password' );
|
808 |
+
$signature = edd_get_option( 'paypal_' . $key . '_api_signature' );
|
809 |
+
|
810 |
+
if ( empty( $username ) || empty( $password ) || empty( $signature ) ) {
|
811 |
+
return;
|
812 |
+
}
|
813 |
+
|
814 |
+
// Localize the refund checkbox label.
|
815 |
+
$label = __( 'Refund Payment in PayPal', 'easy-digital-downloads' );
|
816 |
+
|
817 |
+
?>
|
818 |
+
<script type="text/javascript">
|
819 |
+
jQuery(document).ready(function($) {
|
820 |
+
$('select[name=edd-payment-status]').change(function() {
|
821 |
+
if ( 'refunded' == $(this).val() ) {
|
822 |
+
$(this).parent().parent().append('<input type="checkbox" id="edd-paypal-refund" name="edd-paypal-refund" value="1" style="margin-top:0">');
|
823 |
+
$(this).parent().parent().append('<label for="edd-paypal-refund"><?php echo $label; ?></label>');
|
824 |
+
} else {
|
825 |
+
$('#edd-paypal-refund').remove();
|
826 |
+
$('label[for="edd-paypal-refund"]').remove();
|
827 |
+
}
|
828 |
+
});
|
829 |
+
});
|
830 |
+
</script>
|
831 |
+
<?php
|
832 |
+
}
|
833 |
+
add_action( 'edd_view_order_details_before', 'edd_paypal_refund_admin_js', 100 );
|
834 |
+
|
835 |
+
/**
|
836 |
+
* Possibly refunds a payment made with PayPal Standard or PayPal Express.
|
837 |
+
*
|
838 |
+
* @access public
|
839 |
+
* @since 2.6.0
|
840 |
+
*
|
841 |
+
* @param int $payment_id The current payment ID.
|
842 |
+
* @return void
|
843 |
+
*/
|
844 |
+
function edd_maybe_refund_paypal_purchase( EDD_Payment $payment ) {
|
845 |
+
|
846 |
+
|
847 |
+
if( ! current_user_can( 'edit_shop_payments', $payment->ID ) ) {
|
848 |
+
return;
|
849 |
+
}
|
850 |
+
|
851 |
+
if( empty( $_POST['edd-paypal-refund'] ) ) {
|
852 |
+
return;
|
853 |
+
}
|
854 |
+
|
855 |
+
$processed = $payment->get_meta( '_edd_paypal_refunded', true );
|
856 |
+
|
857 |
+
// If the status is not set to "refunded", return early.
|
858 |
+
if ( 'publish' !== $payment->old_status && 'revoked' !== $payment->old_status ) {
|
859 |
+
return;
|
860 |
+
}
|
861 |
+
|
862 |
+
// If not PayPal/PayPal Express, return early.
|
863 |
+
if ( 'paypal' !== $payment->gateway ) {
|
864 |
+
return;
|
865 |
+
}
|
866 |
+
|
867 |
+
// If the payment has already been refunded in the past, return early.
|
868 |
+
if ( $processed ) {
|
869 |
+
return;
|
870 |
+
}
|
871 |
+
|
872 |
+
// Process the refund in PayPal.
|
873 |
+
edd_refund_paypal_purchase( $payment );
|
874 |
+
|
875 |
+
}
|
876 |
+
add_action( 'edd_pre_refund_payment', 'edd_maybe_refund_paypal_purchase', 999 );
|
877 |
+
|
878 |
+
/**
|
879 |
+
* Refunds a purchase made via PayPal.
|
880 |
+
*
|
881 |
+
* @access public
|
882 |
+
* @since 2.6.0
|
883 |
+
*
|
884 |
+
* @param object|int $payment The payment ID or object to refund.
|
885 |
+
* @return void
|
886 |
+
*/
|
887 |
+
function edd_refund_paypal_purchase( $payment ) {
|
888 |
+
|
889 |
+
if( ! is_a( $payment, 'EDD_Payment' ) && is_numeric( $payment ) ) {
|
890 |
+
$payment = new EDD_Payment( $payment );
|
891 |
+
}
|
892 |
+
|
893 |
+
// Set PayPal API key credentials.
|
894 |
+
$credentials = array(
|
895 |
+
'api_endpoint' => 'test' == $payment->mode ? 'https://api-3t.sandbox.paypal.com/nvp' : 'https://api-3t.paypal.com/nvp',
|
896 |
+
'api_username' => edd_get_option( 'paypal_' . $payment->mode . '_api_username' ),
|
897 |
+
'api_password' => edd_get_option( 'paypal_' . $payment->mode . '_api_password' ),
|
898 |
+
'api_signature' => edd_get_option( 'paypal_' . $payment->mode . '_api_signature' )
|
899 |
+
);
|
900 |
+
|
901 |
+
$credentials = apply_filters( 'edd_paypal_refund_api_credentials', $credentials, $payment );
|
902 |
+
|
903 |
+
$body = array(
|
904 |
+
'USER' => $credentials['api_username'],
|
905 |
+
'PWD' => $credentials['api_password'],
|
906 |
+
'SIGNATURE' => $credentials['api_signature'],
|
907 |
+
'VERSION' => '124',
|
908 |
+
'METHOD' => 'RefundTransaction',
|
909 |
+
'TRANSACTIONID' => $payment->transaction_id,
|
910 |
+
'REFUNDTYPE' => 'Full'
|
911 |
+
);
|
912 |
+
|
913 |
+
$body = apply_filters( 'edd_paypal_refund_body_args', $body, $payment );
|
914 |
+
|
915 |
+
// Prepare the headers of the refund request.
|
916 |
+
$headers = array(
|
917 |
+
'Content-Type' => 'application/x-www-form-urlencoded',
|
918 |
+
'Cache-Control' => 'no-cache'
|
919 |
+
);
|
920 |
+
|
921 |
+
$headers = apply_filters( 'edd_paypal_refund_header_args', $headers, $payment );
|
922 |
+
|
923 |
+
// Prepare args of the refund request.
|
924 |
+
$args = array(
|
925 |
+
'body' => $body,
|
926 |
+
'headers' => $headers,
|
927 |
+
'httpversion' => '1.1'
|
928 |
+
);
|
929 |
+
|
930 |
+
$args = apply_filters( 'edd_paypal_refund_request_args', $args, $payment );
|
931 |
+
|
932 |
+
$error_msg = '';
|
933 |
+
$request = wp_remote_post( $credentials['api_endpoint'], $args );
|
934 |
+
|
935 |
+
if ( is_wp_error( $request ) ) {
|
936 |
+
|
937 |
+
$success = false;
|
938 |
+
$error_msg = $request->get_error_message();
|
939 |
+
|
940 |
+
} else {
|
941 |
+
|
942 |
+
$body = wp_remote_retrieve_body( $request );
|
943 |
+
$code = wp_remote_retrieve_response_code( $request );
|
944 |
+
$message = wp_remote_retrieve_response_message( $request );
|
945 |
+
if( is_string( $body ) ) {
|
946 |
+
wp_parse_str( $body, $body );
|
947 |
+
}
|
948 |
+
|
949 |
+
if( empty( $code ) || 200 !== (int) $code ) {
|
950 |
+
$success = false;
|
951 |
+
}
|
952 |
+
|
953 |
+
if( empty( $message ) || 'OK' !== $message ) {
|
954 |
+
$success = false;
|
955 |
+
}
|
956 |
+
|
957 |
+
if( isset( $body['ACK'] ) && 'success' === strtolower( $body['ACK'] ) ) {
|
958 |
+
$success = true;
|
959 |
+
} else {
|
960 |
+
$success = false;
|
961 |
+
if( isset( $body['L_LONGMESSAGE0'] ) ) {
|
962 |
+
$error_msg = $body['L_LONGMESSAGE0'];
|
963 |
+
} else {
|
964 |
+
$error_msg = __( 'PayPal refund failed for unknown reason.', 'easy-digital-downloads' );
|
965 |
+
}
|
966 |
+
}
|
967 |
+
|
968 |
+
}
|
969 |
+
|
970 |
+
if( $success ) {
|
971 |
+
|
972 |
+
// Prevents the PayPal Express one-time gateway from trying to process the refundl
|
973 |
+
$payment->update_meta( '_edd_paypal_refunded', true );
|
974 |
+
$payment->add_note( sprintf( __( 'PayPal refund transaction ID: %s', 'easy-digital-downloads' ), $body['REFUNDTRANSACTIONID'] ) );
|
975 |
+
|
976 |
+
} else {
|
977 |
+
|
978 |
+
$payment->add_note( sprintf( __( 'PayPal refund failed: %s', 'easy-digital-downloads' ), $error_msg ) );
|
979 |
+
|
980 |
+
}
|
981 |
+
|
982 |
+
// Run hook letting people know the payment has been refunded successfully.
|
983 |
+
do_action( 'edd_paypal_refund_purchase', $payment );
|
984 |
+
}
|
includes/install.php
CHANGED
@@ -24,7 +24,6 @@ if ( ! defined( 'ABSPATH' ) ) exit;
|
|
24 |
* @since 1.0
|
25 |
* @global $wpdb
|
26 |
* @global $edd_options
|
27 |
-
* @global $wp_version
|
28 |
* @param bool $network_side If the plugin is being network-activated
|
29 |
* @return void
|
30 |
*/
|
@@ -57,7 +56,7 @@ register_activation_hook( EDD_PLUGIN_FILE, 'edd_install' );
|
|
57 |
* @return void
|
58 |
*/
|
59 |
function edd_run_install() {
|
60 |
-
global $wpdb, $edd_options
|
61 |
|
62 |
if( ! function_exists( 'edd_create_protection_files' ) ) {
|
63 |
require_once EDD_PLUGIN_DIR . 'includes/admin/upload-functions.php';
|
@@ -184,8 +183,9 @@ function edd_run_install() {
|
|
184 |
$api = new EDD_API;
|
185 |
update_option( 'edd_default_api_version', 'v' . $api->get_version() );
|
186 |
|
187 |
-
// Create the
|
188 |
@EDD()->customers->create_table();
|
|
|
189 |
|
190 |
// Check for PHP Session support, and enable if available
|
191 |
EDD()->session->use_php_sessions();
|
@@ -255,9 +255,11 @@ add_action( 'wpmu_new_blog', 'edd_new_blog_created', 10, 6 );
|
|
255 |
function edd_wpmu_drop_tables( $tables, $blog_id ) {
|
256 |
|
257 |
switch_to_blog( $blog_id );
|
258 |
-
$customers_db
|
|
|
259 |
if ( $customers_db->installed() ) {
|
260 |
$tables[] = $customers_db->table_name;
|
|
|
261 |
}
|
262 |
restore_current_blog();
|
263 |
|
@@ -286,9 +288,17 @@ function edd_after_install() {
|
|
286 |
|
287 |
if ( false === $edd_table_check || current_time( 'timestamp' ) > $edd_table_check ) {
|
288 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
289 |
if ( ! @EDD()->customers->installed() ) {
|
290 |
// Create the customers database (this ensures it creates it on multisite instances where it is network activated)
|
291 |
@EDD()->customers->create_table();
|
|
|
292 |
|
293 |
do_action( 'edd_after_install', $edd_options );
|
294 |
}
|
@@ -322,7 +332,7 @@ function edd_install_roles_on_network() {
|
|
322 |
return;
|
323 |
}
|
324 |
|
325 |
-
if( !
|
326 |
|
327 |
// Create EDD shop roles
|
328 |
$roles = new EDD_Roles;
|
24 |
* @since 1.0
|
25 |
* @global $wpdb
|
26 |
* @global $edd_options
|
|
|
27 |
* @param bool $network_side If the plugin is being network-activated
|
28 |
* @return void
|
29 |
*/
|
56 |
* @return void
|
57 |
*/
|
58 |
function edd_run_install() {
|
59 |
+
global $wpdb, $edd_options;
|
60 |
|
61 |
if( ! function_exists( 'edd_create_protection_files' ) ) {
|
62 |
require_once EDD_PLUGIN_DIR . 'includes/admin/upload-functions.php';
|
183 |
$api = new EDD_API;
|
184 |
update_option( 'edd_default_api_version', 'v' . $api->get_version() );
|
185 |
|
186 |
+
// Create the customer databases
|
187 |
@EDD()->customers->create_table();
|
188 |
+
@EDD()->customer_meta->create_table();
|
189 |
|
190 |
// Check for PHP Session support, and enable if available
|
191 |
EDD()->session->use_php_sessions();
|
255 |
function edd_wpmu_drop_tables( $tables, $blog_id ) {
|
256 |
|
257 |
switch_to_blog( $blog_id );
|
258 |
+
$customers_db = new EDD_DB_Customers();
|
259 |
+
$customer_meta_db = new EDD_DB_Customer_Meta();
|
260 |
if ( $customers_db->installed() ) {
|
261 |
$tables[] = $customers_db->table_name;
|
262 |
+
$tables[] = $customer_meta_db->table_name;
|
263 |
}
|
264 |
restore_current_blog();
|
265 |
|
288 |
|
289 |
if ( false === $edd_table_check || current_time( 'timestamp' ) > $edd_table_check ) {
|
290 |
|
291 |
+
if ( ! @EDD()->customer_meta->installed() ) {
|
292 |
+
|
293 |
+
// Create the customer meta database (this ensures it creates it on multisite instances where it is network activated)
|
294 |
+
@EDD()->customer_meta->create_table();
|
295 |
+
|
296 |
+
}
|
297 |
+
|
298 |
if ( ! @EDD()->customers->installed() ) {
|
299 |
// Create the customers database (this ensures it creates it on multisite instances where it is network activated)
|
300 |
@EDD()->customers->create_table();
|
301 |
+
@EDD()->customer_meta->create_table();
|
302 |
|
303 |
do_action( 'edd_after_install', $edd_options );
|
304 |
}
|
332 |
return;
|
333 |
}
|
334 |
|
335 |
+
if( ! array_key_exists( 'shop_manager', $wp_roles->roles ) ) {
|
336 |
|
337 |
// Create EDD shop roles
|
338 |
$roles = new EDD_Roles;
|
includes/libraries/parsecsv.lib.php
ADDED
@@ -0,0 +1,1163 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
class parseCSV {
|
4 |
+
|
5 |
+
/*
|
6 |
+
Class: parseCSV v0.4.3 beta
|
7 |
+
https://github.com/parsecsv/parsecsv-for-php
|
8 |
+
|
9 |
+
Fully conforms to the specifications lined out on wikipedia:
|
10 |
+
- http://en.wikipedia.org/wiki/Comma-separated_values
|
11 |
+
|
12 |
+
Based on the concept of Ming Hong Ng's CsvFileParser class:
|
13 |
+
- http://minghong.blogspot.com/2006/07/csv-parser-for-php.html
|
14 |
+
|
15 |
+
|
16 |
+
(The MIT license)
|
17 |
+
|
18 |
+
Copyright (c) 2014 Jim Myhrberg.
|
19 |
+
|
20 |
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
21 |
+
of this software and associated documentation files (the "Software"), to deal
|
22 |
+
in the Software without restriction, including without limitation the rights
|
23 |
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
24 |
+
copies of the Software, and to permit persons to whom the Software is
|
25 |
+
furnished to do so, subject to the following conditions:
|
26 |
+
|
27 |
+
The above copyright notice and this permission notice shall be included in
|
28 |
+
all copies or substantial portions of the Software.
|
29 |
+
|
30 |
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
31 |
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
32 |
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
33 |
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
34 |
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
35 |
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
36 |
+
THE SOFTWARE.
|
37 |
+
|
38 |
+
|
39 |
+
Code Examples
|
40 |
+
----------------
|
41 |
+
# general usage
|
42 |
+
$csv = new parseCSV('data.csv');
|
43 |
+
print_r($csv->data);
|
44 |
+
----------------
|
45 |
+
# tab delimited, and encoding conversion
|
46 |
+
$csv = new parseCSV();
|
47 |
+
$csv->encoding('UTF-16', 'UTF-8');
|
48 |
+
$csv->delimiter = "\t";
|
49 |
+
$csv->parse('data.tsv');
|
50 |
+
print_r($csv->data);
|
51 |
+
----------------
|
52 |
+
# auto-detect delimiter character
|
53 |
+
$csv = new parseCSV();
|
54 |
+
$csv->auto('data.csv');
|
55 |
+
print_r($csv->data);
|
56 |
+
----------------
|
57 |
+
# modify data in a csv file
|
58 |
+
$csv = new parseCSV();
|
59 |
+
$csv->sort_by = 'id';
|
60 |
+
$csv->parse('data.csv');
|
61 |
+
# "4" is the value of the "id" column of the CSV row
|
62 |
+
$csv->data[4] = array('firstname' => 'John', 'lastname' => 'Doe', 'email' => 'john@doe.com');
|
63 |
+
$csv->save();
|
64 |
+
----------------
|
65 |
+
# add row/entry to end of CSV file
|
66 |
+
# - only recommended when you know the extact sctructure of the file
|
67 |
+
$csv = new parseCSV();
|
68 |
+
$csv->save('data.csv', array(array('1986', 'Home', 'Nowhere', '')), true);
|
69 |
+
----------------
|
70 |
+
# convert 2D array to csv data and send headers
|
71 |
+
# to browser to treat output as a file and download it
|
72 |
+
$csv = new parseCSV();
|
73 |
+
$csv->output('movies.csv', $array, array('field 1', 'field 2'), ',');
|
74 |
+
----------------
|
75 |
+
*/
|
76 |
+
|
77 |
+
/**
|
78 |
+
* Configuration
|
79 |
+
* - set these options with $object->var_name = 'value';
|
80 |
+
*/
|
81 |
+
|
82 |
+
/**
|
83 |
+
* Heading
|
84 |
+
* Use first line/entry as field names
|
85 |
+
*
|
86 |
+
* @access public
|
87 |
+
* @var bool
|
88 |
+
*/
|
89 |
+
public $heading = true;
|
90 |
+
|
91 |
+
/**
|
92 |
+
* Fields
|
93 |
+
* Override field names
|
94 |
+
*
|
95 |
+
* @access public
|
96 |
+
* @var array
|
97 |
+
*/
|
98 |
+
public $fields = array();
|
99 |
+
|
100 |
+
/**
|
101 |
+
* Sort By
|
102 |
+
* Sort csv by this field
|
103 |
+
*
|
104 |
+
* @access public
|
105 |
+
* @var string
|
106 |
+
*/
|
107 |
+
public $sort_by = null;
|
108 |
+
|
109 |
+
/**
|
110 |
+
* Sort Reverse
|
111 |
+
* Reverse the sort function
|
112 |
+
*
|
113 |
+
* @access public
|
114 |
+
* @var bool
|
115 |
+
*/
|
116 |
+
public $sort_reverse = false;
|
117 |
+
|
118 |
+
/**
|
119 |
+
* Sort Type
|
120 |
+
* Sort behavior passed to sort methods
|
121 |
+
*
|
122 |
+
* regular = SORT_REGULAR
|
123 |
+
* numeric = SORT_NUMERIC
|
124 |
+
* string = SORT_STRING
|
125 |
+
*
|
126 |
+
* @access public
|
127 |
+
* @var string
|
128 |
+
*/
|
129 |
+
public $sort_type = null;
|
130 |
+
|
131 |
+
/**
|
132 |
+
* Delimiter
|
133 |
+
* Delimiter character
|
134 |
+
*
|
135 |
+
* @access public
|
136 |
+
* @var string
|
137 |
+
*/
|
138 |
+
public $delimiter = ',';
|
139 |
+
|
140 |
+
/**
|
141 |
+
* Enclosure
|
142 |
+
* Enclosure character
|
143 |
+
*
|
144 |
+
* @access public
|
145 |
+
* @var string
|
146 |
+
*/
|
147 |
+
public $enclosure = '"';
|
148 |
+
|
149 |
+
/**
|
150 |
+
* Enclose All
|
151 |
+
* Force enclosing all columns
|
152 |
+
*
|
153 |
+
* @access public
|
154 |
+
* @var bool
|
155 |
+
*/
|
156 |
+
public $enclose_all = false;
|
157 |
+
|
158 |
+
/**
|
159 |
+
* Conditions
|
160 |
+
* Basic SQL-Like conditions for row matching
|
161 |
+
*
|
162 |
+
* @access public
|
163 |
+
* @var string
|
164 |
+
*/
|
165 |
+
public $conditions = null;
|
166 |
+
|
167 |
+
/**
|
168 |
+
* Offset
|
169 |
+
* Number of rows to ignore from beginning of data
|
170 |
+
*
|
171 |
+
* @access public
|
172 |
+
* @var int
|
173 |
+
*/
|
174 |
+
public $offset = null;
|
175 |
+
|
176 |
+
/**
|
177 |
+
* Limit
|
178 |
+
* Limits the number of returned rows to the specified amount
|
179 |
+
*
|
180 |
+
* @access public
|
181 |
+
* @var int
|
182 |
+
*/
|
183 |
+
public $limit = null;
|
184 |
+
|
185 |
+
/**
|
186 |
+
* Auto Depth
|
187 |
+
* Number of rows to analyze when attempting to auto-detect delimiter
|
188 |
+
*
|
189 |
+
* @access public
|
190 |
+
* @var int
|
191 |
+
*/
|
192 |
+
public $auto_depth = 15;
|
193 |
+
|
194 |
+
/**
|
195 |
+
* Auto Non Charts
|
196 |
+
* Characters that should be ignored when attempting to auto-detect delimiter
|
197 |
+
*
|
198 |
+
* @access public
|
199 |
+
* @var string
|
200 |
+
*/
|
201 |
+
public $auto_non_chars = "a-zA-Z0-9\n\r";
|
202 |
+
|
203 |
+
/**
|
204 |
+
* Auto Preferred
|
205 |
+
* preferred delimiter characters, only used when all filtering method
|
206 |
+
* returns multiple possible delimiters (happens very rarely)
|
207 |
+
*
|
208 |
+
* @access public
|
209 |
+
* @var string
|
210 |
+
*/
|
211 |
+
public $auto_preferred = ",;\t.:|";
|
212 |
+
|
213 |
+
/**
|
214 |
+
* Convert Encoding
|
215 |
+
* Should we convert the csv encoding?
|
216 |
+
*
|
217 |
+
* @access public
|
218 |
+
* @var bool
|
219 |
+
*/
|
220 |
+
public $convert_encoding = false;
|
221 |
+
|
222 |
+
/**
|
223 |
+
* Input Encoding
|
224 |
+
* Set the input encoding
|
225 |
+
*
|
226 |
+
* @access public
|
227 |
+
* @var string
|
228 |
+
*/
|
229 |
+
public $input_encoding = 'ISO-8859-1';
|
230 |
+
|
231 |
+
/**
|
232 |
+
* Output Encoding
|
233 |
+
* Set the output encoding
|
234 |
+
*
|
235 |
+
* @access public
|
236 |
+
* @var string
|
237 |
+
*/
|
238 |
+
public $output_encoding = 'ISO-8859-1';
|
239 |
+
|
240 |
+
/**
|
241 |
+
* Linefeed
|
242 |
+
* Line feed characters used by unparse, save, and output methods
|
243 |
+
*
|
244 |
+
* @access public
|
245 |
+
* @var string
|
246 |
+
*/
|
247 |
+
public $linefeed = "\r";
|
248 |
+
|
249 |
+
/**
|
250 |
+
* Output Delimiter
|
251 |
+
* Sets the output delimiter used by the output method
|
252 |
+
*
|
253 |
+
* @access public
|
254 |
+
* @var string
|
255 |
+
*/
|
256 |
+
public $output_delimiter = ',';
|
257 |
+
|
258 |
+
/**
|
259 |
+
* Output filename
|
260 |
+
* Sets the output filename
|
261 |
+
*
|
262 |
+
* @access public
|
263 |
+
* @var string
|
264 |
+
*/
|
265 |
+
public $output_filename = 'data.csv';
|
266 |
+
|
267 |
+
/**
|
268 |
+
* Keep File Data
|
269 |
+
* keep raw file data in memory after successful parsing (useful for debugging)
|
270 |
+
*
|
271 |
+
* @access public
|
272 |
+
* @var bool
|
273 |
+
*/
|
274 |
+
public $keep_file_data = false;
|
275 |
+
|
276 |
+
/**
|
277 |
+
* Internal variables
|
278 |
+
*/
|
279 |
+
|
280 |
+
/**
|
281 |
+
* File
|
282 |
+
* Current Filename
|
283 |
+
*
|
284 |
+
* @access public
|
285 |
+
* @var string
|
286 |
+
*/
|
287 |
+
public $file;
|
288 |
+
|
289 |
+
/**
|
290 |
+
* File Data
|
291 |
+
* Current file data
|
292 |
+
*
|
293 |
+
* @access public
|
294 |
+
* @var string
|
295 |
+
*/
|
296 |
+
public $file_data;
|
297 |
+
|
298 |
+
/**
|
299 |
+
* Error
|
300 |
+
* Contains the error code if one occured
|
301 |
+
*
|
302 |
+
* 0 = No errors found. Everything should be fine :)
|
303 |
+
* 1 = Hopefully correctable syntax error was found.
|
304 |
+
* 2 = Enclosure character (double quote by default)
|
305 |
+
* was found in non-enclosed field. This means
|
306 |
+
* the file is either corrupt, or does not
|
307 |
+
* standard CSV formatting. Please validate
|
308 |
+
* the parsed data yourself.
|
309 |
+
*
|
310 |
+
* @access public
|
311 |
+
* @var int
|
312 |
+
*/
|
313 |
+
public $error = 0;
|
314 |
+
|
315 |
+
/**
|
316 |
+
* Error Information
|
317 |
+
* Detailed error information
|
318 |
+
*
|
319 |
+
* @access public
|
320 |
+
* @var array
|
321 |
+
*/
|
322 |
+
public $error_info = array();
|
323 |
+
|
324 |
+
/**
|
325 |
+
* Titles
|
326 |
+
* CSV titles if they exists
|
327 |
+
*
|
328 |
+
* @access public
|
329 |
+
* @var array
|
330 |
+
*/
|
331 |
+
public $titles = array();
|
332 |
+
|
333 |
+
/**
|
334 |
+
* Data
|
335 |
+
* Two dimensional array of CSV data
|
336 |
+
*
|
337 |
+
* @access public
|
338 |
+
* @var array
|
339 |
+
*/
|
340 |
+
public $data = array();
|
341 |
+
|
342 |
+
/**
|
343 |
+
* Constructor
|
344 |
+
* Class constructor
|
345 |
+
*
|
346 |
+
* @access public
|
347 |
+
* @param [string] input The CSV string or a direct filepath
|
348 |
+
* @param [integer] offset Number of rows to ignore from the beginning of the data
|
349 |
+
* @param [integer] limit Limits the number of returned rows to specified amount
|
350 |
+
* @param [string] conditions Basic SQL-like conditions for row matching
|
351 |
+
*/
|
352 |
+
public function __construct($input = null, $offset = null, $limit = null, $conditions = null, $keep_file_data = null) {
|
353 |
+
if (!is_null($offset)) {
|
354 |
+
$this->offset = $offset;
|
355 |
+
}
|
356 |
+
|
357 |
+
if (!is_null($limit)) {
|
358 |
+
$this->limit = $limit;
|
359 |
+
}
|
360 |
+
|
361 |
+
if (!is_null($conditions)) {
|
362 |
+
$this->conditions = $conditions;
|
363 |
+
}
|
364 |
+
|
365 |
+
if (!is_null($keep_file_data)) {
|
366 |
+
$this->keep_file_data = $keep_file_data;
|
367 |
+
}
|
368 |
+
|
369 |
+
if (!empty($input)) {
|
370 |
+
$this->parse($input);
|
371 |
+
}
|
372 |
+
}
|
373 |
+
|
374 |
+
// ==============================================
|
375 |
+
// ----- [ Main Functions ] ---------------------
|
376 |
+
// ==============================================
|
377 |
+
|
378 |
+
/**
|
379 |
+
* Parse
|
380 |
+
* Parse a CSV file or string
|
381 |
+
*
|
382 |
+
* @access public
|
383 |
+
* @param [string] input The CSV string or a direct filepath
|
384 |
+
* @param [integer] offset Number of rows to ignore from the beginning of the data
|
385 |
+
* @param [integer] limit Limits the number of returned rows to specified amount
|
386 |
+
* @param [string] conditions Basic SQL-like conditions for row matching
|
387 |
+
*
|
388 |
+
* @return [bool]
|
389 |
+
*/
|
390 |
+
public function parse($input = null, $offset = null, $limit = null, $conditions = null) {
|
391 |
+
if (is_null($input)) {
|
392 |
+
$input = $this->file;
|
393 |
+
}
|
394 |
+
|
395 |
+
if (!empty($input)) {
|
396 |
+
if (!is_null($offset)) {
|
397 |
+
$this->offset = $offset;
|
398 |
+
}
|
399 |
+
|
400 |
+
if (!is_null($limit)) {
|
401 |
+
$this->limit = $limit;
|
402 |
+
}
|
403 |
+
|
404 |
+
if (!is_null($conditions)) {
|
405 |
+
$this->conditions = $conditions;
|
406 |
+
}
|
407 |
+
|
408 |
+
if (is_readable($input)) {
|
409 |
+
$this->data = $this->parse_file($input);
|
410 |
+
} else {
|
411 |
+
$this->file_data = &$input;
|
412 |
+
$this->data = $this->parse_string();
|
413 |
+
}
|
414 |
+
|
415 |
+
if ($this->data === false) {
|
416 |
+
return false;
|
417 |
+
}
|
418 |
+
}
|
419 |
+
|
420 |
+
return true;
|
421 |
+
}
|
422 |
+
|
423 |
+
/**
|
424 |
+
* Save
|
425 |
+
* Save changes, or write a new file and/or data
|
426 |
+
*
|
427 |
+
* @access public
|
428 |
+
* @param [string] $file File location to save to
|
429 |
+
* @param [array] $data 2D array of data
|
430 |
+
* @param [bool] $append Append current data to end of target CSV, if file exists
|
431 |
+
* @param [array] $fields Field names
|
432 |
+
*
|
433 |
+
* @return [bool]
|
434 |
+
*/
|
435 |
+
public function save($file = null, $data = array(), $append = false, $fields = array()) {
|
436 |
+
if (empty($file)) {
|
437 |
+
$file = &$this->file;
|
438 |
+
}
|
439 |
+
|
440 |
+
$mode = ($append) ? 'at' : 'wt';
|
441 |
+
$is_php = (preg_match('/\.php$/i', $file)) ? true : false;
|
442 |
+
|
443 |
+
return $this->_wfile($file, $this->unparse($data, $fields, $append, $is_php), $mode);
|
444 |
+
}
|
445 |
+
|
446 |
+
/**
|
447 |
+
* Output
|
448 |
+
* Generate a CSV based string for output.
|
449 |
+
*
|
450 |
+
* @access public
|
451 |
+
* @param [string] $filename If specified, headers and data will be output directly to browser as a downloable file
|
452 |
+
* @param [array] $data 2D array with data
|
453 |
+
* @param [array] $fields Field names
|
454 |
+
* @param [type] $delimiter delimiter used to separate data
|
455 |
+
*
|
456 |
+
* @return [string]
|
457 |
+
*/
|
458 |
+
public function output($filename = null, $data = array(), $fields = array(), $delimiter = null) {
|
459 |
+
if (empty($filename)) {
|
460 |
+
$filename = $this->output_filename;
|
461 |
+
}
|
462 |
+
|
463 |
+
if ($delimiter === null) {
|
464 |
+
$delimiter = $this->output_delimiter;
|
465 |
+
}
|
466 |
+
|
467 |
+
$data = $this->unparse($data, $fields, null, null, $delimiter);
|
468 |
+
|
469 |
+
if (!is_null($filename)) {
|
470 |
+
header('Content-type: application/csv');
|
471 |
+
header('Content-Length: ' . strlen($data));
|
472 |
+
header('Cache-Control: no-cache, must-revalidate');
|
473 |
+
header('Pragma: no-cache');
|
474 |
+
header('Expires: 0');
|
475 |
+
header('Content-Disposition: attachment; filename="' . $filename . '"; modification-date="' . date('r') . '";');
|
476 |
+
|
477 |
+
echo $data;
|
478 |
+
}
|
479 |
+
|
480 |
+
return $data;
|
481 |
+
}
|
482 |
+
|
483 |
+
/**
|
484 |
+
* Encoding
|
485 |
+
* Convert character encoding
|
486 |
+
*
|
487 |
+
* @access public
|
488 |
+
* @param [string] $input Input character encoding, uses default if left blank
|
489 |
+
* @param [string] $output Output character encoding, uses default if left blank
|
490 |
+
*/
|
491 |
+
public function encoding($input = null, $output = null) {
|
492 |
+
$this->convert_encoding = true;
|
493 |
+
if (!is_null($input)) {
|
494 |
+
$this->input_encoding = $input;
|
495 |
+
}
|
496 |
+
|
497 |
+
if (!is_null($output)) {
|
498 |
+
$this->output_encoding = $output;
|
499 |
+
}
|
500 |
+
}
|
501 |
+
|
502 |
+
/**
|
503 |
+
* Auto
|
504 |
+
* Auto-Detect Delimiter: Find delimiter by analyzing a specific number of
|
505 |
+
* rows to determine most probable delimiter character
|
506 |
+
*
|
507 |
+
* @access public
|
508 |
+
* @param [string] $file Local CSV file
|
509 |
+
* @param [bool] $parse True/false parse file directly
|
510 |
+
* @param [int] $search_depth Number of rows to analyze
|
511 |
+
* @param [string] $preferred Preferred delimiter characters
|
512 |
+
* @param [string] $enclosure Enclosure character, default is double quote (").
|
513 |
+
*
|
514 |
+
* @return [string]
|
515 |
+
*/
|
516 |
+
public function auto($file = null, $parse = true, $search_depth = null, $preferred = null, $enclosure = null) {
|
517 |
+
if (is_null($file)) {
|
518 |
+
$file = $this->file;
|
519 |
+
}
|
520 |
+
|
521 |
+
if (empty($search_depth)) {
|
522 |
+
$search_depth = $this->auto_depth;
|
523 |
+
}
|
524 |
+
|
525 |
+
if (is_null($enclosure)) {
|
526 |
+
$enclosure = $this->enclosure;
|
527 |
+
}
|
528 |
+
|
529 |
+
if (is_null($preferred)) {
|
530 |
+
$preferred = $this->auto_preferred;
|
531 |
+
}
|
532 |
+
|
533 |
+
if (empty($this->file_data)) {
|
534 |
+
if ($this->_check_data($file)) {
|
535 |
+
$data = &$this->file_data;
|
536 |
+
} else {
|
537 |
+
return false;
|
538 |
+
}
|
539 |
+
} else {
|
540 |
+
$data = &$this->file_data;
|
541 |
+
}
|
542 |
+
|
543 |
+
$chars = array();
|
544 |
+
$strlen = strlen($data);
|
545 |
+
$enclosed = false;
|
546 |
+
$n = 1;
|
547 |
+
$to_end = true;
|
548 |
+
|
549 |
+
// walk specific depth finding posssible delimiter characters
|
550 |
+
for ($i = 0; $i < $strlen; $i++) {
|
551 |
+
$ch = $data{$i};
|
552 |
+
$nch = (isset($data{$i + 1})) ? $data{$i + 1} : false;
|
553 |
+
$pch = (isset($data{$i - 1})) ? $data{$i - 1} : false;
|
554 |
+
|
555 |
+
// open and closing quotes
|
556 |
+
if ($ch == $enclosure) {
|
557 |
+
if (!$enclosed || $nch != $enclosure) {
|
558 |
+
$enclosed = ($enclosed) ? false : true;
|
559 |
+
} elseif ($enclosed) {
|
560 |
+
$i++;
|
561 |
+
}
|
562 |
+
|
563 |
+
// end of row
|
564 |
+
} elseif (($ch == "\n" && $pch != "\r" || $ch == "\r") && !$enclosed) {
|
565 |
+
if ($n >= $search_depth) {
|
566 |
+
$strlen = 0;
|
567 |
+
$to_end = false;
|
568 |
+
} else {
|
569 |
+
$n++;
|
570 |
+
}
|
571 |
+
|
572 |
+
// count character
|
573 |
+
} elseif (!$enclosed) {
|
574 |
+
if (!preg_match('/[' . preg_quote($this->auto_non_chars, '/') . ']/i', $ch)) {
|
575 |
+
if (!isset($chars[$ch][$n])) {
|
576 |
+
$chars[$ch][$n] = 1;
|
577 |
+
} else {
|
578 |
+
$chars[$ch][$n]++;
|
579 |
+
}
|
580 |
+
}
|
581 |
+
}
|
582 |
+
}
|
583 |
+
|
584 |
+
// filtering
|
585 |
+
$depth = ($to_end) ? $n - 1 : $n;
|
586 |
+
$filtered = array();
|
587 |
+
foreach ($chars as $char => $value) {
|
588 |
+
if ($match = $this->_check_count($char, $value, $depth, $preferred)) {
|
589 |
+
$filtered[$match] = $char;
|
590 |
+
}
|
591 |
+
}
|
592 |
+
|
593 |
+
// capture most probable delimiter
|
594 |
+
ksort($filtered);
|
595 |
+
$this->delimiter = reset($filtered);
|
596 |
+
|
597 |
+
// parse data
|
598 |
+
if ($parse) {
|
599 |
+
$this->data = $this->parse_string();
|
600 |
+
}
|
601 |
+
|
602 |
+
return $this->delimiter;
|
603 |
+
}
|
604 |
+
|
605 |
+
// ==============================================
|
606 |
+
// ----- [ Core Functions ] ---------------------
|
607 |
+
// ==============================================
|
608 |
+
|
609 |
+
/**
|
610 |
+
* Parse File
|
611 |
+
* Read file to string and call parse_string()
|
612 |
+
*
|
613 |
+
* @access public
|
614 |
+
*
|
615 |
+
* @param [string] $file Local CSV file
|
616 |
+
*
|
617 |
+
* @return [array|bool]
|
618 |
+
*/
|
619 |
+
public function parse_file($file = null) {
|
620 |
+
if (is_null($file)) {
|
621 |
+
$file = $this->file;
|
622 |
+
}
|
623 |
+
|
624 |
+
if (empty($this->file_data)) {
|
625 |
+
$this->load_data($file);
|
626 |
+
}
|
627 |
+
|
628 |
+
return (!empty($this->file_data)) ? $this->parse_string() : false;
|
629 |
+
}
|
630 |
+
|
631 |
+
/**
|
632 |
+
* Parse CSV strings to arrays
|
633 |
+
*
|
634 |
+
* @access public
|
635 |
+
* @param data CSV string
|
636 |
+
*
|
637 |
+
* @return 2D array with CSV data, or false on failure
|
638 |
+
*/
|
639 |
+
public function parse_string($data = null) {
|
640 |
+
if (empty($data)) {
|
641 |
+
if ($this->_check_data()) {
|
642 |
+
$data = &$this->file_data;
|
643 |
+
} else {
|
644 |
+
return false;
|
645 |
+
}
|
646 |
+
}
|
647 |
+
|
648 |
+
$white_spaces = str_replace($this->delimiter, '', " \t\x0B\0");
|
649 |
+
|
650 |
+
$rows = array();
|
651 |
+
$row = array();
|
652 |
+
$row_count = 0;
|
653 |
+
$current = '';
|
654 |
+
$head = (!empty($this->fields)) ? $this->fields : array();
|
655 |
+
$col = 0;
|
656 |
+
$enclosed = false;
|
657 |
+
$was_enclosed = false;
|
658 |
+
$strlen = strlen($data);
|
659 |
+
|
660 |
+
// force the parser to process end of data as a character (false) when
|
661 |
+
// data does not end with a line feed or carriage return character.
|
662 |
+
$lch = $data{$strlen - 1};
|
663 |
+
if ($lch != "\n" && $lch != "\r") {
|
664 |
+
$strlen++;
|
665 |
+
}
|
666 |
+
|
667 |
+
// walk through each character
|
668 |
+
for ($i = 0; $i < $strlen; $i++) {
|
669 |
+
$ch = (isset($data{$i})) ? $data{$i} : false;
|
670 |
+
$nch = (isset($data{$i + 1})) ? $data{$i + 1} : false;
|
671 |
+
$pch = (isset($data{$i - 1})) ? $data{$i - 1} : false;
|
672 |
+
|
673 |
+
// open/close quotes, and inline quotes
|
674 |
+
if ($ch == $this->enclosure) {
|
675 |
+
if (!$enclosed) {
|
676 |
+
if (ltrim($current, $white_spaces) == '') {
|
677 |
+
$enclosed = true;
|
678 |
+
$was_enclosed = true;
|
679 |
+
} else {
|
680 |
+
$this->error = 2;
|
681 |
+
$error_row = count($rows) + 1;
|
682 |
+
$error_col = $col + 1;
|
683 |
+
if (!isset($this->error_info[$error_row . '-' . $error_col])) {
|
684 |
+
$this->error_info[$error_row . '-' . $error_col] = array(
|
685 |
+
'type' => 2,
|
686 |
+
'info' => 'Syntax error found on row ' . $error_row . '. Non-enclosed fields can not contain double-quotes.',
|
687 |
+
'row' => $error_row,
|
688 |
+
'field' => $error_col,
|
689 |
+
'field_name' => (!empty($head[$col])) ? $head[$col] : null,
|
690 |
+
);
|
691 |
+
}
|
692 |
+
|
693 |
+
$current .= $ch;
|
694 |
+
}
|
695 |
+
} elseif ($nch == $this->enclosure) {
|
696 |
+
$current .= $ch;
|
697 |
+
$i++;
|
698 |
+
} elseif ($nch != $this->delimiter && $nch != "\r" && $nch != "\n") {
|
699 |
+
for ($x = ($i + 1);isset($data{$x}) && ltrim($data{$x}, $white_spaces) == ''; $x++) {}
|
700 |
+
if ($data{$x} == $this->delimiter) {
|
701 |
+
$enclosed = false;
|
702 |
+
$i = $x;
|
703 |
+
} else {
|
704 |
+
if ($this->error < 1) {
|
705 |
+
$this->error = 1;
|
706 |
+
}
|
707 |
+
|
708 |
+
$error_row = count($rows) + 1;
|
709 |
+
$error_col = $col + 1;
|
710 |
+
if (!isset($this->error_info[$error_row . '-' . $error_col])) {
|
711 |
+
$this->error_info[$error_row . '-' . $error_col] = array(
|
712 |
+
'type' => 1,
|
713 |
+
'info' =>
|
714 |
+
'Syntax error found on row ' . (count($rows) + 1) . '. ' .
|
715 |
+
'A single double-quote was found within an enclosed string. ' .
|
716 |
+
'Enclosed double-quotes must be escaped with a second double-quote.',
|
717 |
+
'row' => count($rows) + 1,
|
718 |
+
'field' => $col + 1,
|
719 |
+
'field_name' => (!empty($head[$col])) ? $head[$col] : null,
|
720 |
+
);
|
721 |
+
}
|
722 |
+
|
723 |
+
$current .= $ch;
|
724 |
+
$enclosed = false;
|
725 |
+
}
|
726 |
+
} else {
|
727 |
+
$enclosed = false;
|
728 |
+
}
|
729 |
+
|
730 |
+
// end of field/row/csv
|
731 |
+
} elseif (($ch == $this->delimiter || $ch == "\n" || $ch == "\r" || $ch === false) && !$enclosed) {
|
732 |
+
$key = (!empty($head[$col])) ? $head[$col] : $col;
|
733 |
+
$row[$key] = ($was_enclosed) ? $current : trim($current);
|
734 |
+
$current = '';
|
735 |
+
$was_enclosed = false;
|
736 |
+
$col++;
|
737 |
+
|
738 |
+
// end of row
|
739 |
+
if ($ch == "\n" || $ch == "\r" || $ch === false) {
|
740 |
+
if ($this->_validate_offset($row_count) && $this->_validate_row_conditions($row, $this->conditions)) {
|
741 |
+
if ($this->heading && empty($head)) {
|
742 |
+
$head = $row;
|
743 |
+
} elseif (empty($this->fields) || (!empty($this->fields) && (($this->heading && $row_count > 0) || !$this->heading))) {
|
744 |
+
if (!empty($this->sort_by) && !empty($row[$this->sort_by])) {
|
745 |
+
if (isset($rows[$row[$this->sort_by]])) {
|
746 |
+
$rows[$row[$this->sort_by] . '_0'] = &$rows[$row[$this->sort_by]];
|
747 |
+
unset($rows[$row[$this->sort_by]]);
|
748 |
+
for ($sn = 1;isset($rows[$row[$this->sort_by] . '_' . $sn]); $sn++) {}
|
749 |
+
$rows[$row[$this->sort_by] . '_' . $sn] = $row;
|
750 |
+
} else {
|
751 |
+
$rows[$row[$this->sort_by]] = $row;
|
752 |
+
}
|
753 |
+
|
754 |
+
} else {
|
755 |
+
$rows[] = $row;
|
756 |
+
}
|
757 |
+
}
|
758 |
+
}
|
759 |
+
|
760 |
+
$row = array();
|
761 |
+
$col = 0;
|
762 |
+
$row_count++;
|
763 |
+
|
764 |
+
if ($this->sort_by === null && $this->limit !== null && count($rows) == $this->limit) {
|
765 |
+
$i = $strlen;
|
766 |
+
}
|
767 |
+
|
768 |
+
if ($ch == "\r" && $nch == "\n") {
|
769 |
+
$i++;
|
770 |
+
}
|
771 |
+
}
|
772 |
+
|
773 |
+
// append character to current field
|
774 |
+
} else {
|
775 |
+
$current .= $ch;
|
776 |
+
}
|
777 |
+
}
|
778 |
+
|
779 |
+
$this->titles = $head;
|
780 |
+
if (!empty($this->sort_by)) {
|
781 |
+
$sort_type = SORT_REGULAR;
|
782 |
+
if ($this->sort_type == 'numeric') {
|
783 |
+
$sort_type = SORT_NUMERIC;
|
784 |
+
} elseif ($this->sort_type == 'string') {
|
785 |
+
$sort_type = SORT_STRING;
|
786 |
+
}
|
787 |
+
|
788 |
+
($this->sort_reverse) ? krsort($rows, $sort_type) : ksort($rows, $sort_type);
|
789 |
+
|
790 |
+
if ($this->offset !== null || $this->limit !== null) {
|
791 |
+
$rows = array_slice($rows, ($this->offset === null ? 0 : $this->offset), $this->limit, true);
|
792 |
+
}
|
793 |
+
}
|
794 |
+
|
795 |
+
if (!$this->keep_file_data) {
|
796 |
+
$this->file_data = null;
|
797 |
+
}
|
798 |
+
|
799 |
+
return $rows;
|
800 |
+
}
|
801 |
+
|
802 |
+
/**
|
803 |
+
* Create CSV data from array
|
804 |
+
*
|
805 |
+
* @access public
|
806 |
+
* @param data 2D array with data
|
807 |
+
* @param fields field names
|
808 |
+
* @param append if true, field names will not be output
|
809 |
+
* @param is_php if a php die() call should be put on the first
|
810 |
+
* line of the file, this is later ignored when read.
|
811 |
+
* @param delimiter field delimiter to use
|
812 |
+
*
|
813 |
+
* @return CSV data (text string)
|
814 |
+
*/
|
815 |
+
public function unparse($data = array(), $fields = array(), $append = false, $is_php = false, $delimiter = null) {
|
816 |
+
if (!is_array($data) || empty($data)) {
|
817 |
+
$data = &$this->data;
|
818 |
+
}
|
819 |
+
|
820 |
+
if (!is_array($fields) || empty($fields)) {
|
821 |
+
$fields = &$this->titles;
|
822 |
+
}
|
823 |
+
|
824 |
+
if ($delimiter === null) {
|
825 |
+
$delimiter = $this->delimiter;
|
826 |
+
}
|
827 |
+
|
828 |
+
$string = ($is_php) ? "<?php header('Status: 403'); die(' '); ?>" . $this->linefeed : '';
|
829 |
+
$entry = array();
|
830 |
+
|
831 |
+
// create heading
|
832 |
+
if ($this->heading && !$append && !empty($fields)) {
|
833 |
+
foreach ($fields as $key => $value) {
|
834 |
+
$entry[] = $this->_enclose_value($value, $delimiter);
|
835 |
+
}
|
836 |
+
|
837 |
+
$string .= implode($delimiter, $entry) . $this->linefeed;
|
838 |
+
$entry = array();
|
839 |
+
}
|
840 |
+
|
841 |
+
// create data
|
842 |
+
foreach ($data as $key => $row) {
|
843 |
+
foreach ($row as $field => $value) {
|
844 |
+
$entry[] = $this->_enclose_value($value, $delimiter);
|
845 |
+
}
|
846 |
+
|
847 |
+
$string .= implode($delimiter, $entry) . $this->linefeed;
|
848 |
+
$entry = array();
|
849 |
+
}
|
850 |
+
|
851 |
+
if ($this->convert_encoding) {
|
852 |
+
$string = iconv($this->input_encoding, $this->output_encoding, $string);
|
853 |
+
}
|
854 |
+
|
855 |
+
return $string;
|
856 |
+
}
|
857 |
+
|
858 |
+
/**
|
859 |
+
* Load local file or string
|
860 |
+
*
|
861 |
+
* @access public
|
862 |
+
* @param input local CSV file
|
863 |
+
*
|
864 |
+
* @return true or false
|
865 |
+
*/
|
866 |
+
public function load_data($input = null) {
|
867 |
+
$data = null;
|
868 |
+
$file = null;
|
869 |
+
|
870 |
+
if (is_null($input)) {
|
871 |
+
$file = $this->file;
|
872 |
+
} elseif (file_exists($input)) {
|
873 |
+
$file = $input;
|
874 |
+
} else {
|
875 |
+
$data = $input;
|
876 |
+
}
|
877 |
+
|
878 |
+
if (!empty($data) || $data = $this->_rfile($file)) {
|
879 |
+
if ($this->file != $file) {
|
880 |
+
$this->file = $file;
|
881 |
+
}
|
882 |
+
|
883 |
+
if (preg_match('/\.php$/i', $file) && preg_match('/<\?.*?\?>(.*)/ims', $data, $strip)) {
|
884 |
+
$data = ltrim($strip[1]);
|
885 |
+
}
|
886 |
+
|
887 |
+
if ($this->convert_encoding) {
|
888 |
+
$data = iconv($this->input_encoding, $this->output_encoding, $data);
|
889 |
+
}
|
890 |
+
|
891 |
+
if (substr($data, -1) != "\n") {
|
892 |
+
$data .= "\n";
|
893 |
+
}
|
894 |
+
|
895 |
+
$this->file_data = &$data;
|
896 |
+
return true;
|
897 |
+
}
|
898 |
+
|
899 |
+
return false;
|
900 |
+
}
|
901 |
+
|
902 |
+
// ==============================================
|
903 |
+
// ----- [ Internal Functions ] -----------------
|
904 |
+
// ==============================================
|
905 |
+
|
906 |
+
/**
|
907 |
+
* Validate a row against specified conditions
|
908 |
+
*
|
909 |
+
* @access protected
|
910 |
+
* @param row array with values from a row
|
911 |
+
* @param conditions specified conditions that the row must match
|
912 |
+
*
|
913 |
+
* @return true of false
|
914 |
+
*/
|
915 |
+
protected function _validate_row_conditions($row = array(), $conditions = null) {
|
916 |
+
if (!empty($row)) {
|
917 |
+
if (!empty($conditions)) {
|
918 |
+
$conditions = (strpos($conditions, ' OR ') !== false) ? explode(' OR ', $conditions) : array($conditions);
|
919 |
+
$or = '';
|
920 |
+
foreach ($conditions as $key => $value) {
|
921 |
+
if (strpos($value, ' AND ') !== false) {
|
922 |
+
$value = explode(' AND ', $value);
|
923 |
+
$and = '';
|
924 |
+
|
925 |
+
foreach ($value as $k => $v) {
|
926 |
+
$and .= $this->_validate_row_condition($row, $v);
|
927 |
+
}
|
928 |
+
|
929 |
+
$or .= (strpos($and, '0') !== false) ? '0' : '1';
|
930 |
+
} else {
|
931 |
+
$or .= $this->_validate_row_condition($row, $value);
|
932 |
+
}
|
933 |
+
}
|
934 |
+
|
935 |
+
return (strpos($or, '1') !== false) ? true : false;
|
936 |
+
}
|
937 |
+
|
938 |
+
return true;
|
939 |
+
}
|
940 |
+
|
941 |
+
return false;
|
942 |
+
}
|
943 |
+
|
944 |
+
/**
|
945 |
+
* Validate a row against a single condition
|
946 |
+
*
|
947 |
+
* @access protected
|
948 |
+
* @param row array with values from a row
|
949 |
+
* @param condition specified condition that the row must match
|
950 |
+
*
|
951 |
+
* @return true of false
|
952 |
+
*/
|
953 |
+
protected function _validate_row_condition($row, $condition) {
|
954 |
+
$operators = array(
|
955 |
+
'=', 'equals', 'is',
|
956 |
+
'!=', 'is not',
|
957 |
+
'<', 'is less than',
|
958 |
+
'>', 'is greater than',
|
959 |
+
'<=', 'is less than or equals',
|
960 |
+
'>=', 'is greater than or equals',
|
961 |
+
'contains',
|
962 |
+
'does not contain',
|
963 |
+
);
|
964 |
+
|
965 |
+
$operators_regex = array();
|
966 |
+
|
967 |
+
foreach ($operators as $value) {
|
968 |
+
$operators_regex[] = preg_quote($value, '/');
|
969 |
+
}
|
970 |
+
|
971 |
+
$operators_regex = implode('|', $operators_regex);
|
972 |
+
|
973 |
+
if (preg_match('/^(.+) (' . $operators_regex . ') (.+)$/i', trim($condition), $capture)) {
|
974 |
+
$field = $capture[1];
|
975 |
+
$op = $capture[2];
|
976 |
+
$value = $capture[3];
|
977 |
+
|
978 |
+
if (preg_match('/^([\'\"]{1})(.*)([\'\"]{1})$/i', $value, $capture)) {
|
979 |
+
if ($capture[1] == $capture[3]) {
|
980 |
+
$value = $capture[2];
|
981 |
+
$value = str_replace("\\n", "\n", $value);
|
982 |
+
$value = str_replace("\\r", "\r", $value);
|
983 |
+
$value = str_replace("\\t", "\t", $value);
|
984 |
+
$value = stripslashes($value);
|
985 |
+
}
|
986 |
+
}
|
987 |
+
|
988 |
+
if (array_key_exists($field, $row)) {
|
989 |
+
if (($op == '=' || $op == 'equals' || $op == 'is') && $row[$field] == $value) {
|
990 |
+
return '1';
|
991 |
+
} elseif (($op == '!=' || $op == 'is not') && $row[$field] != $value) {
|
992 |
+
return '1';
|
993 |
+
} elseif (($op == '<' || $op == 'is less than') && $row[$field] < $value) {
|
994 |
+
return '1';
|
995 |
+
} elseif (($op == '>' || $op == 'is greater than') && $row[$field] > $value) {
|
996 |
+
return '1';
|
997 |
+
} elseif (($op == '<=' || $op == 'is less than or equals') && $row[$field] <= $value) {
|
998 |
+
return '1';
|
999 |
+
} elseif (($op == '>=' || $op == 'is greater than or equals') && $row[$field] >= $value) {
|
1000 |
+
return '1';
|
1001 |
+
} elseif ($op == 'contains' && preg_match('/' . preg_quote($value, '/') . '/i', $row[$field])) {
|
1002 |
+
return '1';
|
1003 |
+
} elseif ($op == 'does not contain' && !preg_match('/' . preg_quote($value, '/') . '/i', $row[$field])) {
|
1004 |
+
return '1';
|
1005 |
+
} else {
|
1006 |
+
return '0';
|
1007 |
+
}
|
1008 |
+
}
|
1009 |
+
}
|
1010 |
+
|
1011 |
+
return '1';
|
1012 |
+
}
|
1013 |
+
|
1014 |
+
/**
|
1015 |
+
* Validates if the row is within the offset or not if sorting is disabled
|
1016 |
+
*
|
1017 |
+
* @access protected
|
1018 |
+
* @param current_row the current row number being processed
|
1019 |
+
*
|
1020 |
+
* @return true of false
|
1021 |
+
*/
|
1022 |
+
protected function _validate_offset($current_row) {
|
1023 |
+
if ($this->sort_by === null && $this->offset !== null && $current_row < $this->offset) {
|
1024 |
+
return false;
|
1025 |
+
}
|
1026 |
+
|
1027 |
+
return true;
|
1028 |
+
}
|
1029 |
+
|
1030 |
+
/**
|
1031 |
+
* Enclose values if needed
|
1032 |
+
* - only used by unparse()
|
1033 |
+
*
|
1034 |
+
* @access protected
|
1035 |
+
* @param value string to process
|
1036 |
+
*
|
1037 |
+
* @return Processed value
|
1038 |
+
*/
|
1039 |
+
protected function _enclose_value($value = null, $delimiter = null) {
|
1040 |
+
if (is_null($delimiter)) {
|
1041 |
+
$delimiter = $this->delimiter;
|
1042 |
+
}
|
1043 |
+
if ($value !== null && $value != '') {
|
1044 |
+
$delimiter_quoted = preg_quote($delimiter, '/');
|
1045 |
+
$enclosure_quoted = preg_quote($this->enclosure, '/');
|
1046 |
+
if (preg_match("/" . $delimiter_quoted . "|" . $enclosure_quoted . "|\n|\r/i", $value) || ($value{0} == ' ' || substr($value, -1) == ' ') || $this->enclose_all) {
|
1047 |
+
$value = str_replace($this->enclosure, $this->enclosure . $this->enclosure, $value);
|
1048 |
+
$value = $this->enclosure . $value . $this->enclosure;
|
1049 |
+
}
|
1050 |
+
}
|
1051 |
+
|
1052 |
+
return $value;
|
1053 |
+
}
|
1054 |
+
|
1055 |
+
/**
|
1056 |
+
* Check file data
|
1057 |
+
*
|
1058 |
+
* @access protected
|
1059 |
+
* @param file local filename
|
1060 |
+
*
|
1061 |
+
* @return true or false
|
1062 |
+
*/
|
1063 |
+
protected function _check_data($file = null) {
|
1064 |
+
if (empty($this->file_data)) {
|
1065 |
+
if (is_null($file)) {
|
1066 |
+
$file = $this->file;
|
1067 |
+
}
|
1068 |
+
|
1069 |
+
return $this->load_data($file);
|
1070 |
+
}
|
1071 |
+
|
1072 |
+
return true;
|
1073 |
+
}
|
1074 |
+
|
1075 |
+
/**
|
1076 |
+
* Check if passed info might be delimiter
|
1077 |
+
* Only used by find_delimiter
|
1078 |
+
*
|
1079 |
+
* @access protected
|
1080 |
+
* @param [type] $char [description]
|
1081 |
+
* @param [type] $array [description]
|
1082 |
+
* @param [type] $depth [description]
|
1083 |
+
* @param [type] $preferred [description]
|
1084 |
+
*
|
1085 |
+
* @return special string used for delimiter selection, or false
|
1086 |
+
*/
|
1087 |
+
protected function _check_count($char, $array, $depth, $preferred) {
|
1088 |
+
if ($depth == count($array)) {
|
1089 |
+
$first = null;
|
1090 |
+
$equal = null;
|
1091 |
+
$almost = false;
|
1092 |
+
foreach ($array as $key => $value) {
|
1093 |
+
if ($first == null) {
|
1094 |
+
$first = $value;
|
1095 |
+
} elseif ($value == $first && $equal !== false) {
|
1096 |
+
$equal = true;
|
1097 |
+
} elseif ($value == $first + 1 && $equal !== false) {
|
1098 |
+
$equal = true;
|
1099 |
+
$almost = true;
|
1100 |
+
} else {
|
1101 |
+
$equal = false;
|
1102 |
+
}
|
1103 |
+
}
|
1104 |
+
|
1105 |
+
if ($equal) {
|
1106 |
+
$match = ($almost) ? 2 : 1;
|
1107 |
+
$pref = strpos($preferred, $char);
|
1108 |
+
$pref = ($pref !== false) ? str_pad($pref, 3, '0', STR_PAD_LEFT) : '999';
|
1109 |
+
|
1110 |
+
return $pref . $match . '.' . (99999 - str_pad($first, 5, '0', STR_PAD_LEFT));
|
1111 |
+
} else {
|
1112 |
+
return false;
|
1113 |
+
}
|
1114 |
+
}
|
1115 |
+
}
|
1116 |
+
|
1117 |
+
/**
|
1118 |
+
* Read local file
|
1119 |
+
*
|
1120 |
+
* @access protected
|
1121 |
+
* @param file local filename
|
1122 |
+
*
|
1123 |
+
* @return Data from file, or false on failure
|
1124 |
+
*/
|
1125 |
+
protected function _rfile($file = null) {
|
1126 |
+
if (is_readable($file)) {
|
1127 |
+
if (!($fh = fopen($file, 'r'))) {
|
1128 |
+
return false;
|
1129 |
+
}
|
1130 |
+
|
1131 |
+
$data = fread($fh, filesize($file));
|
1132 |
+
fclose($fh);
|
1133 |
+
return $data;
|
1134 |
+
}
|
1135 |
+
|
1136 |
+
return false;
|
1137 |
+
}
|
1138 |
+
|
1139 |
+
/**
|
1140 |
+
* Write to local file
|
1141 |
+
*
|
1142 |
+
* @access protected
|
1143 |
+
* @param file local filename
|
1144 |
+
* @param string data to write to file
|
1145 |
+
* @param mode fopen() mode
|
1146 |
+
* @param lock flock() mode
|
1147 |
+
*
|
1148 |
+
* @return true or false
|
1149 |
+
*/
|
1150 |
+
protected function _wfile($file, $string = '', $mode = 'wb', $lock = 2) {
|
1151 |
+
if ($fp = fopen($file, $mode)) {
|
1152 |
+
flock($fp, $lock);
|
1153 |
+
$re = fwrite($fp, $string);
|
1154 |
+
$re2 = fclose($fp);
|
1155 |
+
|
1156 |
+
if ($re != false && $re2 != false) {
|
1157 |
+
return true;
|
1158 |
+
}
|
1159 |
+
}
|
1160 |
+
|
1161 |
+
return false;
|
1162 |
+
}
|
1163 |
+
}
|
includes/mime-types.php
CHANGED
@@ -31,6 +31,7 @@ function edd_allowed_mime_types( $existing_mimes = array() ) {
|
|
31 |
$existing_mimes['exe'] = 'application/octet-stream';
|
32 |
$existing_mimes['apk'] = 'application/vnd.android.package-archive';
|
33 |
$existing_mimes['msi'] = 'application/x-ole-storage';
|
|
|
34 |
|
35 |
return $existing_mimes;
|
36 |
}
|
31 |
$existing_mimes['exe'] = 'application/octet-stream';
|
32 |
$existing_mimes['apk'] = 'application/vnd.android.package-archive';
|
33 |
$existing_mimes['msi'] = 'application/x-ole-storage';
|
34 |
+
$existing_mimes['csv'] = 'text/csv';
|
35 |
|
36 |
return $existing_mimes;
|
37 |
}
|
includes/misc-functions.php
CHANGED
@@ -496,7 +496,7 @@ function edd_add_cache_busting( $url = '' ) {
|
|
496 |
* trigger or false to not trigger error.
|
497 |
*
|
498 |
* @param string $function The function that was called
|
499 |
-
* @param string $version The version of
|
500 |
* @param string $replacement Optional. The function that should have been called
|
501 |
* @param array $backtrace Optional. Contains stack backtrace of deprecated function
|
502 |
*/
|
@@ -719,24 +719,39 @@ function edd_get_timezone_id() {
|
|
719 |
}
|
720 |
|
721 |
/**
|
722 |
-
*
|
723 |
*
|
724 |
-
*
|
725 |
-
*
|
726 |
-
* @
|
727 |
-
*
|
728 |
-
* @param unknown $data
|
729 |
-
* @return array
|
730 |
*/
|
731 |
-
function edd_object_to_array( $
|
732 |
-
|
733 |
-
|
734 |
-
|
735 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
736 |
}
|
737 |
-
return $result;
|
738 |
}
|
739 |
-
|
|
|
|
|
740 |
}
|
741 |
|
742 |
/**
|
496 |
* trigger or false to not trigger error.
|
497 |
*
|
498 |
* @param string $function The function that was called
|
499 |
+
* @param string $version The version of Easy Digital Downloads that deprecated the function
|
500 |
* @param string $replacement Optional. The function that should have been called
|
501 |
* @param array $backtrace Optional. Contains stack backtrace of deprecated function
|
502 |
*/
|
719 |
}
|
720 |
|
721 |
/**
|
722 |
+
* Given an object or array of objects, convert them to arrays
|
723 |
*
|
724 |
+
* @since 1.7
|
725 |
+
* @internal Updated in 2.6
|
726 |
+
* @param object|array $object An object or an array of objects
|
727 |
+
* @return array An array or array of arrays, converted from the provided object(s)
|
|
|
|
|
728 |
*/
|
729 |
+
function edd_object_to_array( $object = array() ) {
|
730 |
+
|
731 |
+
if ( empty( $object ) || ( ! is_object( $object ) && ! is_array( $object ) ) ) {
|
732 |
+
return $object;
|
733 |
+
}
|
734 |
+
|
735 |
+
if ( is_array( $object ) ) {
|
736 |
+
$return = array();
|
737 |
+
foreach ( $object as $item ) {
|
738 |
+
if ( is_a( $object, 'EDD_Payment' ) ) {
|
739 |
+
$return[] = $object->array_convert();
|
740 |
+
} else {
|
741 |
+
$return[] = edd_object_to_array( $item );
|
742 |
+
}
|
743 |
+
|
744 |
+
}
|
745 |
+
} else {
|
746 |
+
if ( is_a( $object, 'EDD_Payment' ) ) {
|
747 |
+
$return = $object->array_convert();
|
748 |
+
} else {
|
749 |
+
$return = get_object_vars( $object );
|
750 |
}
|
|
|
751 |
}
|
752 |
+
|
753 |
+
return $return;
|
754 |
+
|
755 |
}
|
756 |
|
757 |
/**
|
includes/payments/class-edd-payment.php
CHANGED
@@ -19,11 +19,9 @@ if( ! defined( 'ABSPATH' ) ) exit;
|
|
19 |
/**
|
20 |
* EDD_Payment Class
|
21 |
*
|
22 |
-
* Note: Will remain in Final status for a few point releases
|
23 |
-
*
|
24 |
* @since 2.5
|
25 |
*/
|
26 |
-
|
27 |
|
28 |
/**
|
29 |
* The Payment we are working with
|
@@ -540,7 +538,14 @@ final class EDD_Payment {
|
|
540 |
$customer = new stdClass;
|
541 |
|
542 |
if ( did_action( 'edd_pre_process_purchase' ) && is_user_logged_in() ) {
|
543 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
544 |
}
|
545 |
|
546 |
if ( empty( $customer->id ) ) {
|
@@ -559,6 +564,7 @@ final class EDD_Payment {
|
|
559 |
|
560 |
}
|
561 |
|
|
|
562 |
$this->customer_id = $customer->id;
|
563 |
$this->pending['customer_id'] = $this->customer_id;
|
564 |
$customer->attach_payment( $this->ID, false );
|
@@ -1923,6 +1929,22 @@ final class EDD_Payment {
|
|
1923 |
*/
|
1924 |
private function setup_user_id() {
|
1925 |
$user_id = $this->get_meta( '_edd_payment_user_id', true );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1926 |
return $user_id;
|
1927 |
}
|
1928 |
|
@@ -1958,6 +1980,10 @@ final class EDD_Payment {
|
|
1958 |
$user_info = isset( $this->payment_meta['user_info'] ) ? maybe_unserialize( $this->payment_meta['user_info'] ) : array();
|
1959 |
$user_info = wp_parse_args( $user_info, $defaults );
|
1960 |
|
|
|
|
|
|
|
|
|
1961 |
|
1962 |
if ( empty( $user_info ) ) {
|
1963 |
// Get the customer, but only if it's been created
|
19 |
/**
|
20 |
* EDD_Payment Class
|
21 |
*
|
|
|
|
|
22 |
* @since 2.5
|
23 |
*/
|
24 |
+
class EDD_Payment {
|
25 |
|
26 |
/**
|
27 |
* The Payment we are working with
|
538 |
$customer = new stdClass;
|
539 |
|
540 |
if ( did_action( 'edd_pre_process_purchase' ) && is_user_logged_in() ) {
|
541 |
+
|
542 |
+
$customer = new EDD_customer( get_current_user_id(), true );
|
543 |
+
|
544 |
+
// Customer is logged in but used a different email to purchase with so assign to their customer record
|
545 |
+
if( ! empty( $customer->id ) && $this->email != $customer->email ) {
|
546 |
+
$customer->add_email( $this->email );
|
547 |
+
}
|
548 |
+
|
549 |
}
|
550 |
|
551 |
if ( empty( $customer->id ) ) {
|
564 |
|
565 |
}
|
566 |
|
567 |
+
|
568 |
$this->customer_id = $customer->id;
|
569 |
$this->pending['customer_id'] = $this->customer_id;
|
570 |
$customer->attach_payment( $this->ID, false );
|
1929 |
*/
|
1930 |
private function setup_user_id() {
|
1931 |
$user_id = $this->get_meta( '_edd_payment_user_id', true );
|
1932 |
+
|
1933 |
+
if( empty( $user_id ) ) {
|
1934 |
+
|
1935 |
+
$customer = new EDD_Customer( $this->customer_id );
|
1936 |
+
|
1937 |
+
if( ! empty( $customer->user_id ) ) {
|
1938 |
+
|
1939 |
+
$user_id = $customer->user_id;
|
1940 |
+
|
1941 |
+
// Backfill the user ID
|
1942 |
+
$this->update_meta( '_edd_payment_user_id', $user_id );
|
1943 |
+
|
1944 |
+
}
|
1945 |
+
|
1946 |
+
}
|
1947 |
+
|
1948 |
return $user_id;
|
1949 |
}
|
1950 |
|
1980 |
$user_info = isset( $this->payment_meta['user_info'] ) ? maybe_unserialize( $this->payment_meta['user_info'] ) : array();
|
1981 |
$user_info = wp_parse_args( $user_info, $defaults );
|
1982 |
|
1983 |
+
// Ensure email index is in the old user info array
|
1984 |
+
if( empty( $user_info['email'] ) ) {
|
1985 |
+
$user_info['email'] = $this->email;
|
1986 |
+
}
|
1987 |
|
1988 |
if ( empty( $user_info ) ) {
|
1989 |
// Get the customer, but only if it's been created
|
includes/payments/class-payment-stats.php
CHANGED
@@ -107,8 +107,6 @@ class EDD_Payment_Stats extends EDD_Stats {
|
|
107 |
if( is_wp_error( $this->end_date ) )
|
108 |
return $this->end_date;
|
109 |
|
110 |
-
$earnings = false;
|
111 |
-
|
112 |
add_filter( 'posts_where', array( $this, 'payments_where' ) );
|
113 |
|
114 |
if ( empty( $download_id ) ) {
|
@@ -128,8 +126,8 @@ class EDD_Payment_Stats extends EDD_Stats {
|
|
128 |
'include_taxes' => $include_taxes,
|
129 |
);
|
130 |
|
131 |
-
$args
|
132 |
-
$key
|
133 |
|
134 |
$earnings = get_transient( $key );
|
135 |
|
@@ -148,6 +146,8 @@ class EDD_Payment_Stats extends EDD_Stats {
|
|
148 |
$total_tax = $wpdb->get_var( "SELECT SUM(meta_value) FROM $wpdb->postmeta WHERE meta_key = '_edd_payment_tax' AND post_id IN ({$sales})" );
|
149 |
}
|
150 |
|
|
|
|
|
151 |
$earnings += ( $total_earnings - $total_tax );
|
152 |
|
153 |
}
|
@@ -173,16 +173,13 @@ class EDD_Payment_Stats extends EDD_Stats {
|
|
173 |
);
|
174 |
|
175 |
$args = apply_filters( 'edd_stats_earnings_args', $args );
|
176 |
-
$key = 'edd_stats_' .
|
177 |
|
178 |
$earnings = get_transient( $key );
|
179 |
-
$earnings = false;
|
180 |
if( false === $earnings ) {
|
181 |
|
182 |
$this->timestamp = false;
|
183 |
-
add_filter( 'posts_where', array( $this, 'payments_where' ) );
|
184 |
$log_ids = $edd_logs->get_connected_logs( $args, 'sale' );
|
185 |
-
remove_filter( 'posts_where', array( $this, 'payments_where' ) );
|
186 |
|
187 |
$earnings = 0;
|
188 |
|
@@ -201,6 +198,15 @@ class EDD_Payment_Stats extends EDD_Stats {
|
|
201 |
|
202 |
$earnings += $item['price'];
|
203 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
204 |
if ( ! $include_taxes ) {
|
205 |
$earnings -= edd_get_payment_item_tax( $payment_id, $cart_key );
|
206 |
}
|
107 |
if( is_wp_error( $this->end_date ) )
|
108 |
return $this->end_date;
|
109 |
|
|
|
|
|
110 |
add_filter( 'posts_where', array( $this, 'payments_where' ) );
|
111 |
|
112 |
if ( empty( $download_id ) ) {
|
126 |
'include_taxes' => $include_taxes,
|
127 |
);
|
128 |
|
129 |
+
$args = apply_filters( 'edd_stats_earnings_args', $args );
|
130 |
+
$key = 'edd_stats_' . md5( serialize( $args ) );
|
131 |
|
132 |
$earnings = get_transient( $key );
|
133 |
|
146 |
$total_tax = $wpdb->get_var( "SELECT SUM(meta_value) FROM $wpdb->postmeta WHERE meta_key = '_edd_payment_tax' AND post_id IN ({$sales})" );
|
147 |
}
|
148 |
|
149 |
+
$total_earnings = apply_filters( 'edd_payment_stats_earnings_total', $total_earnings, $sales, $args );
|
150 |
+
|
151 |
$earnings += ( $total_earnings - $total_tax );
|
152 |
|
153 |
}
|
173 |
);
|
174 |
|
175 |
$args = apply_filters( 'edd_stats_earnings_args', $args );
|
176 |
+
$key = 'edd_stats_' . md5( serialize( $args ) );
|
177 |
|
178 |
$earnings = get_transient( $key );
|
|
|
179 |
if( false === $earnings ) {
|
180 |
|
181 |
$this->timestamp = false;
|
|
|
182 |
$log_ids = $edd_logs->get_connected_logs( $args, 'sale' );
|
|
|
183 |
|
184 |
$earnings = 0;
|
185 |
|
198 |
|
199 |
$earnings += $item['price'];
|
200 |
|
201 |
+
// Check if there are any item specific fees
|
202 |
+
if ( ! empty( $item['fees'] ) ) {
|
203 |
+
foreach ( $item['fees'] as $key => $fee ) {
|
204 |
+
$earnings += $fee['amount'];
|
205 |
+
}
|
206 |
+
}
|
207 |
+
|
208 |
+
$earnings = apply_filters( 'edd_payment_stats_item_earnings', $earnings, $payment_id, $cart_key, $item );
|
209 |
+
|
210 |
if ( ! $include_taxes ) {
|
211 |
$earnings -= edd_get_payment_item_tax( $payment_id, $cart_key );
|
212 |
}
|
includes/payments/class-payments-query.php
CHANGED
@@ -49,7 +49,7 @@ class EDD_Payments_Query extends EDD_Stats {
|
|
49 |
*
|
50 |
* @access public
|
51 |
* @since 1.8
|
52 |
-
* @param $args
|
53 |
*/
|
54 |
public function __construct( $args = array() ) {
|
55 |
$defaults = array(
|
@@ -62,6 +62,7 @@ class EDD_Payments_Query extends EDD_Stats {
|
|
62 |
'orderby' => 'ID',
|
63 |
'order' => 'DESC',
|
64 |
'user' => null,
|
|
|
65 |
'status' => edd_get_payment_status_keys(),
|
66 |
'meta_key' => null,
|
67 |
'year' => null,
|
@@ -120,6 +121,7 @@ class EDD_Payments_Query extends EDD_Stats {
|
|
120 |
add_action( 'edd_pre_get_payments', array( $this, 'per_page' ) );
|
121 |
add_action( 'edd_pre_get_payments', array( $this, 'page' ) );
|
122 |
add_action( 'edd_pre_get_payments', array( $this, 'user' ) );
|
|
|
123 |
add_action( 'edd_pre_get_payments', array( $this, 'search' ) );
|
124 |
add_action( 'edd_pre_get_payments', array( $this, 'mode' ) );
|
125 |
add_action( 'edd_pre_get_payments', array( $this, 'children' ) );
|
@@ -322,6 +324,24 @@ class EDD_Payments_Query extends EDD_Stats {
|
|
322 |
) );
|
323 |
}
|
324 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
325 |
/**
|
326 |
* Search
|
327 |
*
|
49 |
*
|
50 |
* @access public
|
51 |
* @since 1.8
|
52 |
+
* @param array $args The array of arguments that can be passed in and used for setting up this payment query.
|
53 |
*/
|
54 |
public function __construct( $args = array() ) {
|
55 |
$defaults = array(
|
62 |
'orderby' => 'ID',
|
63 |
'order' => 'DESC',
|
64 |
'user' => null,
|
65 |
+
'customer' => null,
|
66 |
'status' => edd_get_payment_status_keys(),
|
67 |
'meta_key' => null,
|
68 |
'year' => null,
|
121 |
add_action( 'edd_pre_get_payments', array( $this, 'per_page' ) );
|
122 |
add_action( 'edd_pre_get_payments', array( $this, 'page' ) );
|
123 |
add_action( 'edd_pre_get_payments', array( $this, 'user' ) );
|
124 |
+
add_action( 'edd_pre_get_payments', array( $this, 'customer' ) );
|
125 |
add_action( 'edd_pre_get_payments', array( $this, 'search' ) );
|
126 |
add_action( 'edd_pre_get_payments', array( $this, 'mode' ) );
|
127 |
add_action( 'edd_pre_get_payments', array( $this, 'children' ) );
|
324 |
) );
|
325 |
}
|
326 |
|
327 |
+
/**
|
328 |
+
* Specific customer id
|
329 |
+
*
|
330 |
+
* @access public
|
331 |
+
* @since 2.6
|
332 |
+
* @return void
|
333 |
+
*/
|
334 |
+
public function customer() {
|
335 |
+
if ( is_null( $this->args['customer'] ) || ! is_numeric( $this->args['customer'] ) ) {
|
336 |
+
return;
|
337 |
+
}
|
338 |
+
|
339 |
+
$this->__set( 'meta_query', array(
|
340 |
+
'key' => '_edd_payment_customer_id',
|
341 |
+
'value' => (int) $this->args['customer'],
|
342 |
+
) );
|
343 |
+
}
|
344 |
+
|
345 |
/**
|
346 |
* Search
|
347 |
*
|
includes/payments/functions.php
CHANGED
@@ -371,6 +371,7 @@ function edd_count_payments( $args = array() ) {
|
|
371 |
|
372 |
$defaults = array(
|
373 |
'user' => null,
|
|
|
374 |
's' => null,
|
375 |
'start-date' => null,
|
376 |
'end-date' => null,
|
@@ -401,6 +402,13 @@ function edd_count_payments( $args = array() ) {
|
|
401 |
AND m.meta_value = '{$args['user']}'";
|
402 |
}
|
403 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
404 |
// Count payments for a search
|
405 |
} elseif( ! empty( $args['s'] ) ) {
|
406 |
|
@@ -576,13 +584,23 @@ function edd_check_for_existing_payment( $payment_id ) {
|
|
576 |
*
|
577 |
* @since 1.0
|
578 |
*
|
579 |
-
* @param WP_Post $payment Payment post object
|
580 |
* @param bool $return_label Whether to return the payment status or not
|
581 |
*
|
582 |
* @return bool|mixed if payment status exists, false otherwise
|
583 |
*/
|
584 |
function edd_get_payment_status( $payment, $return_label = false ) {
|
585 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
586 |
if ( ! is_object( $payment ) || ! isset( $payment->post_status ) ) {
|
587 |
return false;
|
588 |
}
|
@@ -1575,7 +1593,7 @@ function edd_get_payment_note_html( $note, $payment_id = 0 ) {
|
|
1575 |
$note_html .='<p>';
|
1576 |
$note_html .= '<strong>' . $user . '</strong> – ' . date_i18n( $date_format, strtotime( $note->comment_date ) ) . '<br/>';
|
1577 |
$note_html .= $note->comment_content;
|
1578 |
-
$note_html .= ' – <a href="' . esc_url( $delete_note_url ) . '" class="edd-delete-payment-note" data-note-id="' . absint( $note->comment_ID ) . '" data-payment-id="' . absint( $payment_id ) . '"
|
1579 |
$note_html .= '</p>';
|
1580 |
$note_html .= '</div>';
|
1581 |
|
371 |
|
372 |
$defaults = array(
|
373 |
'user' => null,
|
374 |
+
'customer' => null,
|
375 |
's' => null,
|
376 |
'start-date' => null,
|
377 |
'end-date' => null,
|
402 |
AND m.meta_value = '{$args['user']}'";
|
403 |
}
|
404 |
|
405 |
+
} elseif ( ! empty( $args['customer'] ) ) {
|
406 |
+
|
407 |
+
$join = "LEFT JOIN $wpdb->postmeta m ON (p.ID = m.post_id)";
|
408 |
+
$where .= "
|
409 |
+
AND m.meta_key = '_edd_payment_customer_id'
|
410 |
+
AND m.meta_value = '{$args['customer']}'";
|
411 |
+
|
412 |
// Count payments for a search
|
413 |
} elseif( ! empty( $args['s'] ) ) {
|
414 |
|
584 |
*
|
585 |
* @since 1.0
|
586 |
*
|
587 |
+
* @param mixed WP_Post|EDD_Payment|Payment ID $payment Payment post object, EDD_Payment object, or payment/post ID
|
588 |
* @param bool $return_label Whether to return the payment status or not
|
589 |
*
|
590 |
* @return bool|mixed if payment status exists, false otherwise
|
591 |
*/
|
592 |
function edd_get_payment_status( $payment, $return_label = false ) {
|
593 |
|
594 |
+
if( is_numeric( $payment ) ) {
|
595 |
+
|
596 |
+
$payment = new EDD_Payment( $payment );
|
597 |
+
|
598 |
+
if( ! $payment->ID > 0 ) {
|
599 |
+
return false;
|
600 |
+
}
|
601 |
+
|
602 |
+
}
|
603 |
+
|
604 |
if ( ! is_object( $payment ) || ! isset( $payment->post_status ) ) {
|
605 |
return false;
|
606 |
}
|
1593 |
$note_html .='<p>';
|
1594 |
$note_html .= '<strong>' . $user . '</strong> – ' . date_i18n( $date_format, strtotime( $note->comment_date ) ) . '<br/>';
|
1595 |
$note_html .= $note->comment_content;
|
1596 |
+
$note_html .= ' – <a href="' . esc_url( $delete_note_url ) . '" class="edd-delete-payment-note" data-note-id="' . absint( $note->comment_ID ) . '" data-payment-id="' . absint( $payment_id ) . '">' . __( 'Delete', 'easy-digital-downloads' ) . '</a>';
|
1597 |
$note_html .= '</p>';
|
1598 |
$note_html .= '</div>';
|
1599 |
|
includes/post-types.php
CHANGED
@@ -406,3 +406,20 @@ function edd_bulk_updated_messages( $bulk_messages, $bulk_counts ) {
|
|
406 |
return $bulk_messages;
|
407 |
}
|
408 |
add_filter( 'bulk_post_updated_messages', 'edd_bulk_updated_messages', 10, 2 );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
406 |
return $bulk_messages;
|
407 |
}
|
408 |
add_filter( 'bulk_post_updated_messages', 'edd_bulk_updated_messages', 10, 2 );
|
409 |
+
|
410 |
+
/**
|
411 |
+
* Add row actions for the downloads custom post type
|
412 |
+
*
|
413 |
+
* @since 2.5
|
414 |
+
* @param array $actions
|
415 |
+
* @param WP_Post $post
|
416 |
+
* @return array
|
417 |
+
*/
|
418 |
+
function edd_download_row_actions( $actions, $post ) {
|
419 |
+
if ( 'download' === $post->post_type ) {
|
420 |
+
return array_merge( array( 'id' => 'ID: ' . $post->ID ), $actions );
|
421 |
+
}
|
422 |
+
|
423 |
+
return $actions;
|
424 |
+
}
|
425 |
+
add_filter( 'post_row_actions', 'edd_download_row_actions', 2, 100 );
|
includes/process-purchase.php
CHANGED
@@ -46,7 +46,7 @@ function edd_process_purchase_form() {
|
|
46 |
|
47 |
// Validate the user
|
48 |
$user = edd_get_purchase_form_user( $valid_data );
|
49 |
-
|
50 |
// Let extensions validate fields after user is logged in if user has used login/registration form
|
51 |
do_action( 'edd_checkout_user_error_checks', $user, $valid_data, $_POST );
|
52 |
|
@@ -131,6 +131,36 @@ add_action( 'edd_purchase', 'edd_process_purchase_form' );
|
|
131 |
add_action( 'wp_ajax_edd_process_checkout', 'edd_process_purchase_form' );
|
132 |
add_action( 'wp_ajax_nopriv_edd_process_checkout', 'edd_process_purchase_form' );
|
133 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
134 |
/**
|
135 |
* Process the checkout login form
|
136 |
*
|
@@ -481,11 +511,14 @@ function edd_purchase_form_validate_new_user() {
|
|
481 |
if ( ! is_email( $user_email ) ) {
|
482 |
edd_set_error( 'email_invalid', __( 'Invalid email', 'easy-digital-downloads' ) );
|
483 |
// Check if email exists
|
484 |
-
} else
|
|
|
|
|
485 |
edd_set_error( 'email_used', __( 'Email already used', 'easy-digital-downloads' ) );
|
486 |
} else {
|
487 |
-
|
488 |
-
|
|
|
489 |
}
|
490 |
} else {
|
491 |
// No email
|
@@ -554,7 +587,7 @@ function edd_purchase_form_validate_user_login() {
|
|
554 |
'password_incorrect',
|
555 |
sprintf(
|
556 |
__( 'The password you entered is incorrect. %sReset Password%s', 'easy-digital-downloads' ),
|
557 |
-
'<a href="' . wp_lostpassword_url( edd_get_checkout_uri() ) . '"
|
558 |
'</a>'
|
559 |
)
|
560 |
);
|
46 |
|
47 |
// Validate the user
|
48 |
$user = edd_get_purchase_form_user( $valid_data );
|
49 |
+
|
50 |
// Let extensions validate fields after user is logged in if user has used login/registration form
|
51 |
do_action( 'edd_checkout_user_error_checks', $user, $valid_data, $_POST );
|
52 |
|
131 |
add_action( 'wp_ajax_edd_process_checkout', 'edd_process_purchase_form' );
|
132 |
add_action( 'wp_ajax_nopriv_edd_process_checkout', 'edd_process_purchase_form' );
|
133 |
|
134 |
+
/**
|
135 |
+
* Verify that when a logged in user makes a purchase that the email address used doesn't belong to a different customer
|
136 |
+
*
|
137 |
+
* @since 2.6
|
138 |
+
* @param array $valid_data Validated data submitted for the purchase
|
139 |
+
* @param array $post Additional $_POST data submitted
|
140 |
+
* @return void
|
141 |
+
*/
|
142 |
+
function edd_checkout_check_existing_email( $valid_data, $post ) {
|
143 |
+
|
144 |
+
// Verify that the email address belongs to this customer
|
145 |
+
if ( is_user_logged_in() ) {
|
146 |
+
|
147 |
+
$email = $valid_data['logged_in_user']['user_email'];
|
148 |
+
$customer = new EDD_Customer( get_current_user_id(), true );
|
149 |
+
|
150 |
+
// If this email address is not registered with this customer, see if it belongs to any other customer
|
151 |
+
if ( $email != $customer->email && ( is_array( $customer->emails ) && ! in_array( $email, $customer->emails ) ) ) {
|
152 |
+
$found_customer = new EDD_Customer( $email );
|
153 |
+
if ( $found_customer->id > 0 ) {
|
154 |
+
edd_set_error( 'edd-customer-email-exists', __( sprintf( 'The email address %s is already in use.', $email ), 'easy-digital-downloads' ) );
|
155 |
+
}
|
156 |
+
}
|
157 |
+
|
158 |
+
|
159 |
+
}
|
160 |
+
|
161 |
+
}
|
162 |
+
add_action( 'edd_checkout_error_checks', 'edd_checkout_check_existing_email', 10, 2 );
|
163 |
+
|
164 |
/**
|
165 |
* Process the checkout login form
|
166 |
*
|
511 |
if ( ! is_email( $user_email ) ) {
|
512 |
edd_set_error( 'email_invalid', __( 'Invalid email', 'easy-digital-downloads' ) );
|
513 |
// Check if email exists
|
514 |
+
} else {
|
515 |
+
$customer = new EDD_Customer( $user_email );
|
516 |
+
if ( $registering_new_user && ( $customer->id > 0 || email_exists( $user_email ) ) ) {
|
517 |
edd_set_error( 'email_used', __( 'Email already used', 'easy-digital-downloads' ) );
|
518 |
} else {
|
519 |
+
// All the checks have run and it's good to go
|
520 |
+
$valid_user_data['user_email'] = $user_email;
|
521 |
+
}
|
522 |
}
|
523 |
} else {
|
524 |
// No email
|
587 |
'password_incorrect',
|
588 |
sprintf(
|
589 |
__( 'The password you entered is incorrect. %sReset Password%s', 'easy-digital-downloads' ),
|
590 |
+
'<a href="' . wp_lostpassword_url( edd_get_checkout_uri() ) . '">',
|
591 |
'</a>'
|
592 |
)
|
593 |
);
|
includes/scripts.php
CHANGED
@@ -75,7 +75,7 @@ function edd_load_scripts() {
|
|
75 |
'empty_cart_message' => __('Your cart is empty','easy-digital-downloads' ), // Item already in the cart message
|
76 |
'loading' => __('Loading','easy-digital-downloads' ) , // General loading message
|
77 |
'select_option' => __('Please select an option','easy-digital-downloads' ) , // Variable pricing error with multi-purchase option enabled
|
78 |
-
'ajax_loader' => set_url_scheme( EDD_PLUGIN_URL . 'assets/images/loading.gif', 'relative' ), //
|
79 |
'is_checkout' => edd_is_checkout() ? '1' : '0',
|
80 |
'default_gateway' => edd_get_default_gateway(),
|
81 |
'redirect_to_checkout' => ( edd_straight_to_checkout() || edd_is_checkout() ) ? '1' : '0',
|
@@ -158,7 +158,7 @@ function edd_load_admin_scripts( $hook ) {
|
|
158 |
return;
|
159 |
}
|
160 |
|
161 |
-
global $
|
162 |
|
163 |
$js_dir = EDD_PLUGIN_URL . 'assets/js/';
|
164 |
$css_dir = EDD_PLUGIN_URL . 'assets/css/';
|
@@ -173,7 +173,10 @@ function edd_load_admin_scripts( $hook ) {
|
|
173 |
wp_register_script( 'jquery-chosen', $js_dir . 'chosen.jquery' . $suffix . '.js', array( 'jquery' ), EDD_VERSION );
|
174 |
wp_enqueue_script( 'jquery-chosen' );
|
175 |
|
|
|
|
|
176 |
$admin_deps = array();
|
|
|
177 |
if ( ! edd_is_admin_page( $hook, 'edit' ) && ! edd_is_admin_page( $hook, 'new' ) ) {
|
178 |
$admin_deps = array( 'jquery', 'inline-edit-post' );
|
179 |
} else {
|
@@ -181,6 +184,7 @@ function edd_load_admin_scripts( $hook ) {
|
|
181 |
}
|
182 |
|
183 |
wp_register_script( 'edd-admin-scripts', $js_dir . 'admin-scripts' . $suffix . '.js', $admin_deps, EDD_VERSION, false );
|
|
|
184 |
wp_enqueue_script( 'edd-admin-scripts' );
|
185 |
|
186 |
wp_localize_script( 'edd-admin-scripts', 'edd_vars', array(
|
@@ -215,7 +219,8 @@ function edd_load_admin_scripts( $hook ) {
|
|
215 |
'batch_export_no_class' => __( 'You must choose a method.', 'easy-digital-downloads' ),
|
216 |
'batch_export_no_reqs' => __( 'Required fields not completed.', 'easy-digital-downloads' ),
|
217 |
'reset_stats_warn' => __( 'Are you sure you want to reset your store? This process is <strong><em>not reversible</em></strong>. Please be sure you have a recent backup.', 'easy-digital-downloads' ),
|
218 |
-
'search_placeholder' => sprintf( __( 'Type to search all %s', 'easy-digital-downloads' ), edd_get_label_plural() )
|
|
|
219 |
));
|
220 |
|
221 |
wp_enqueue_style( 'wp-color-picker' );
|
@@ -227,16 +232,15 @@ function edd_load_admin_scripts( $hook ) {
|
|
227 |
wp_register_script( 'colorbox', $js_dir . 'jquery.colorbox-min.js', array( 'jquery' ), '1.3.20' );
|
228 |
wp_enqueue_script( 'colorbox' );
|
229 |
|
230 |
-
|
231 |
-
|
232 |
-
wp_enqueue_media();
|
233 |
-
}
|
234 |
|
235 |
wp_register_script( 'jquery-flot', $js_dir . 'jquery.flot' . $suffix . '.js' );
|
236 |
wp_enqueue_script( 'jquery-flot' );
|
237 |
|
238 |
wp_enqueue_script( 'jquery-ui-datepicker' );
|
239 |
wp_enqueue_script( 'jquery-ui-dialog' );
|
|
|
240 |
|
241 |
$ui_style = ( 'classic' == get_user_option( 'admin_color' ) ) ? 'classic' : 'fresh';
|
242 |
wp_register_style( 'jquery-ui-css', $css_dir . 'jquery-ui-' . $ui_style . $suffix . '.css' );
|
@@ -272,21 +276,10 @@ function edd_admin_downloads_icon() {
|
|
272 |
$icon_cpt_2x_url = $images_url . 'edd-cpt-2x.png';
|
273 |
?>
|
274 |
<style type="text/css" media="screen">
|
275 |
-
|
276 |
-
|
277 |
-
|
278 |
-
|
279 |
-
}
|
280 |
-
<?php } else { ?>
|
281 |
-
/** Fallback for outdated WP installations */
|
282 |
-
#adminmenu #menu-posts-download div.wp-menu-image {
|
283 |
-
background: url(<?php echo $icon_url; ?>) no-repeat 7px -17px;
|
284 |
-
}
|
285 |
-
#adminmenu #menu-posts-download:hover div.wp-menu-image,
|
286 |
-
#adminmenu #menu-posts-download.wp-has-current-submenu div.wp-menu-image {
|
287 |
-
background-position: 7px 6px;
|
288 |
-
}
|
289 |
-
<?php } ?>
|
290 |
#icon-edit.icon32-posts-download {
|
291 |
background: url(<?php echo $icon_cpt_url; ?>) -7px -5px no-repeat;
|
292 |
}
|
@@ -300,17 +293,6 @@ function edd_admin_downloads_icon() {
|
|
300 |
only screen and ( -o-min-device-pixel-ratio: 3/2),
|
301 |
only screen and ( min-device-pixel-ratio: 1.5),
|
302 |
only screen and ( min-resolution: 1.5dppx) {
|
303 |
-
<?php if( version_compare( $wp_version, '3.7', '<=' ) ) { ?>
|
304 |
-
#adminmenu #menu-posts-download div.wp-menu-image {
|
305 |
-
background-image: url(<?php echo $icon_2x_url; ?>);
|
306 |
-
background-position: 7px -18px;
|
307 |
-
background-size: 16px 40px;
|
308 |
-
}
|
309 |
-
#adminmenu #menu-posts-download:hover div.wp-menu-image,
|
310 |
-
#adminmenu #menu-posts-download.wp-has-current-submenu div.wp-menu-image {
|
311 |
-
background-position: 7px 6px;
|
312 |
-
}
|
313 |
-
<?php } ?>
|
314 |
#icon-edit.icon32-posts-download {
|
315 |
background: url(<?php echo $icon_cpt_2x_url; ?>) no-repeat -7px -5px !important;
|
316 |
background-size: 55px 45px !important;
|
75 |
'empty_cart_message' => __('Your cart is empty','easy-digital-downloads' ), // Item already in the cart message
|
76 |
'loading' => __('Loading','easy-digital-downloads' ) , // General loading message
|
77 |
'select_option' => __('Please select an option','easy-digital-downloads' ) , // Variable pricing error with multi-purchase option enabled
|
78 |
+
'ajax_loader' => set_url_scheme( EDD_PLUGIN_URL . 'assets/images/loading.gif', 'relative' ), // AJAX loading image
|
79 |
'is_checkout' => edd_is_checkout() ? '1' : '0',
|
80 |
'default_gateway' => edd_get_default_gateway(),
|
81 |
'redirect_to_checkout' => ( edd_straight_to_checkout() || edd_is_checkout() ) ? '1' : '0',
|
158 |
return;
|
159 |
}
|
160 |
|
161 |
+
global $post;
|
162 |
|
163 |
$js_dir = EDD_PLUGIN_URL . 'assets/js/';
|
164 |
$css_dir = EDD_PLUGIN_URL . 'assets/css/';
|
173 |
wp_register_script( 'jquery-chosen', $js_dir . 'chosen.jquery' . $suffix . '.js', array( 'jquery' ), EDD_VERSION );
|
174 |
wp_enqueue_script( 'jquery-chosen' );
|
175 |
|
176 |
+
wp_enqueue_script( 'jquery-form' );
|
177 |
+
|
178 |
$admin_deps = array();
|
179 |
+
|
180 |
if ( ! edd_is_admin_page( $hook, 'edit' ) && ! edd_is_admin_page( $hook, 'new' ) ) {
|
181 |
$admin_deps = array( 'jquery', 'inline-edit-post' );
|
182 |
} else {
|
184 |
}
|
185 |
|
186 |
wp_register_script( 'edd-admin-scripts', $js_dir . 'admin-scripts' . $suffix . '.js', $admin_deps, EDD_VERSION, false );
|
187 |
+
|
188 |
wp_enqueue_script( 'edd-admin-scripts' );
|
189 |
|
190 |
wp_localize_script( 'edd-admin-scripts', 'edd_vars', array(
|
219 |
'batch_export_no_class' => __( 'You must choose a method.', 'easy-digital-downloads' ),
|
220 |
'batch_export_no_reqs' => __( 'Required fields not completed.', 'easy-digital-downloads' ),
|
221 |
'reset_stats_warn' => __( 'Are you sure you want to reset your store? This process is <strong><em>not reversible</em></strong>. Please be sure you have a recent backup.', 'easy-digital-downloads' ),
|
222 |
+
'search_placeholder' => sprintf( __( 'Type to search all %s', 'easy-digital-downloads' ), edd_get_label_plural() ),
|
223 |
+
'unsupported_browser' => __( 'We are sorry but your browser is not compatible with this kind of file upload. Please upgrade your browser.', 'easy-digital-downloads' )
|
224 |
));
|
225 |
|
226 |
wp_enqueue_style( 'wp-color-picker' );
|
232 |
wp_register_script( 'colorbox', $js_dir . 'jquery.colorbox-min.js', array( 'jquery' ), '1.3.20' );
|
233 |
wp_enqueue_script( 'colorbox' );
|
234 |
|
235 |
+
//call for media manager
|
236 |
+
wp_enqueue_media();
|
|
|
|
|
237 |
|
238 |
wp_register_script( 'jquery-flot', $js_dir . 'jquery.flot' . $suffix . '.js' );
|
239 |
wp_enqueue_script( 'jquery-flot' );
|
240 |
|
241 |
wp_enqueue_script( 'jquery-ui-datepicker' );
|
242 |
wp_enqueue_script( 'jquery-ui-dialog' );
|
243 |
+
wp_enqueue_script( 'jquery-ui-tooltip' );
|
244 |
|
245 |
$ui_style = ( 'classic' == get_user_option( 'admin_color' ) ) ? 'classic' : 'fresh';
|
246 |
wp_register_style( 'jquery-ui-css', $css_dir . 'jquery-ui-' . $ui_style . $suffix . '.css' );
|
276 |
$icon_cpt_2x_url = $images_url . 'edd-cpt-2x.png';
|
277 |
?>
|
278 |
<style type="text/css" media="screen">
|
279 |
+
#adminmenu #menu-posts-download .wp-menu-image:before,
|
280 |
+
#dashboard_right_now .download-count:before {
|
281 |
+
content: '<?php echo $menu_icon; ?>';
|
282 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
283 |
#icon-edit.icon32-posts-download {
|
284 |
background: url(<?php echo $icon_cpt_url; ?>) -7px -5px no-repeat;
|
285 |
}
|
293 |
only screen and ( -o-min-device-pixel-ratio: 3/2),
|
294 |
only screen and ( min-device-pixel-ratio: 1.5),
|
295 |
only screen and ( min-resolution: 1.5dppx) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
296 |
#icon-edit.icon32-posts-download {
|
297 |
background: url(<?php echo $icon_cpt_2x_url; ?>) no-repeat -7px -5px !important;
|
298 |
background-size: 55px 45px !important;
|
includes/shortcodes.php
CHANGED
@@ -170,8 +170,15 @@ add_shortcode( 'download_cart', 'edd_cart_shortcode' );
|
|
170 |
* @return string
|
171 |
*/
|
172 |
function edd_login_form_shortcode( $atts, $content = null ) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
173 |
extract( shortcode_atts( array(
|
174 |
-
'redirect' =>
|
175 |
), $atts, 'edd_login' )
|
176 |
);
|
177 |
return edd_login_form( $redirect );
|
@@ -190,8 +197,15 @@ add_shortcode( 'edd_login', 'edd_login_form_shortcode' );
|
|
190 |
* @return string
|
191 |
*/
|
192 |
function edd_register_form_shortcode( $atts, $content = null ) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
193 |
extract( shortcode_atts( array(
|
194 |
-
'redirect' =>
|
195 |
), $atts, 'edd_register' )
|
196 |
);
|
197 |
return edd_register_form( $redirect );
|
@@ -322,6 +336,10 @@ function edd_downloads_query( $atts, $content = null ) {
|
|
322 |
$query['nopaging'] = true;
|
323 |
}
|
324 |
|
|
|
|
|
|
|
|
|
325 |
switch ( $atts['orderby'] ) {
|
326 |
case 'price':
|
327 |
$atts['orderby'] = 'meta_value';
|
@@ -341,6 +359,10 @@ function edd_downloads_query( $atts, $content = null ) {
|
|
341 |
$query['orderby'] = 'rand';
|
342 |
break;
|
343 |
|
|
|
|
|
|
|
|
|
344 |
default:
|
345 |
$query['orderby'] = 'post_date';
|
346 |
break;
|
@@ -358,7 +380,10 @@ function edd_downloads_query( $atts, $content = null ) {
|
|
358 |
|
359 |
foreach( $tag_list as $tag ) {
|
360 |
|
361 |
-
|
|
|
|
|
|
|
362 |
|
363 |
$term_id = $tag;
|
364 |
|
@@ -388,7 +413,10 @@ function edd_downloads_query( $atts, $content = null ) {
|
|
388 |
|
389 |
foreach( $categories as $category ) {
|
390 |
|
391 |
-
|
|
|
|
|
|
|
392 |
|
393 |
$term_id = $category;
|
394 |
|
@@ -420,7 +448,10 @@ function edd_downloads_query( $atts, $content = null ) {
|
|
420 |
|
421 |
foreach( $categories as $category ) {
|
422 |
|
423 |
-
|
|
|
|
|
|
|
424 |
|
425 |
$term_id = $category;
|
426 |
|
@@ -451,7 +482,10 @@ function edd_downloads_query( $atts, $content = null ) {
|
|
451 |
|
452 |
foreach( $tag_list as $tag ) {
|
453 |
|
454 |
-
|
|
|
|
|
|
|
455 |
|
456 |
$term_id = $tag;
|
457 |
|
@@ -831,10 +865,14 @@ function edd_process_profile_editor_updates( $data ) {
|
|
831 |
$updated = wp_update_user( $userdata );
|
832 |
|
833 |
// Possibly update the customer
|
834 |
-
$customer
|
|
|
|
|
|
|
|
|
835 |
if ( $customer->id > 0 ) {
|
836 |
$update_args = array(
|
837 |
-
'name'
|
838 |
);
|
839 |
|
840 |
$customer->update( $update_args );
|
@@ -847,3 +885,48 @@ function edd_process_profile_editor_updates( $data ) {
|
|
847 |
}
|
848 |
}
|
849 |
add_action( 'edd_edit_user_profile', 'edd_process_profile_editor_updates' );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
170 |
* @return string
|
171 |
*/
|
172 |
function edd_login_form_shortcode( $atts, $content = null ) {
|
173 |
+
$redirect = home_url();
|
174 |
+
$purchase_history = edd_get_option( 'purchase_history_page', 0 );
|
175 |
+
|
176 |
+
if ( ! empty( $purchase_history ) ) {
|
177 |
+
$redirect = get_permalink( $purchase_history );
|
178 |
+
}
|
179 |
+
|
180 |
extract( shortcode_atts( array(
|
181 |
+
'redirect' => $redirect
|
182 |
), $atts, 'edd_login' )
|
183 |
);
|
184 |
return edd_login_form( $redirect );
|
197 |
* @return string
|
198 |
*/
|
199 |
function edd_register_form_shortcode( $atts, $content = null ) {
|
200 |
+
$redirect = home_url();
|
201 |
+
$purchase_history = edd_get_option( 'purchase_history_page', 0 );
|
202 |
+
|
203 |
+
if ( ! empty( $purchase_history ) ) {
|
204 |
+
$redirect = get_permalink( $purchase_history );
|
205 |
+
}
|
206 |
+
|
207 |
extract( shortcode_atts( array(
|
208 |
+
'redirect' => $redirect
|
209 |
), $atts, 'edd_register' )
|
210 |
);
|
211 |
return edd_register_form( $redirect );
|
336 |
$query['nopaging'] = true;
|
337 |
}
|
338 |
|
339 |
+
if( 'random' == $atts['orderby'] ) {
|
340 |
+
$atts['pagination'] = false;
|
341 |
+
}
|
342 |
+
|
343 |
switch ( $atts['orderby'] ) {
|
344 |
case 'price':
|
345 |
$atts['orderby'] = 'meta_value';
|
359 |
$query['orderby'] = 'rand';
|
360 |
break;
|
361 |
|
362 |
+
case 'post__in':
|
363 |
+
$query['orderby'] = 'post__in';
|
364 |
+
break;
|
365 |
+
|
366 |
default:
|
367 |
$query['orderby'] = 'post_date';
|
368 |
break;
|
380 |
|
381 |
foreach( $tag_list as $tag ) {
|
382 |
|
383 |
+
$t_id = (int) $tag;
|
384 |
+
$is_id = is_int( $t_id ) && ! empty( $t_id );
|
385 |
+
|
386 |
+
if( $is_id ) {
|
387 |
|
388 |
$term_id = $tag;
|
389 |
|
413 |
|
414 |
foreach( $categories as $category ) {
|
415 |
|
416 |
+
$t_id = (int) $category;
|
417 |
+
$is_id = is_int( $t_id ) && ! empty( $t_id );
|
418 |
+
|
419 |
+
if( $is_id ) {
|
420 |
|
421 |
$term_id = $category;
|
422 |
|
448 |
|
449 |
foreach( $categories as $category ) {
|
450 |
|
451 |
+
$t_id = (int) $category;
|
452 |
+
$is_id = is_int( $t_id ) && ! empty( $t_id );
|
453 |
+
|
454 |
+
if( $is_id ) {
|
455 |
|
456 |
$term_id = $category;
|
457 |
|
482 |
|
483 |
foreach( $tag_list as $tag ) {
|
484 |
|
485 |
+
$t_id = (int) $tag;
|
486 |
+
$is_id = is_int( $t_id ) && ! empty( $t_id );
|
487 |
+
|
488 |
+
if( $is_id ) {
|
489 |
|
490 |
$term_id = $tag;
|
491 |
|
865 |
$updated = wp_update_user( $userdata );
|
866 |
|
867 |
// Possibly update the customer
|
868 |
+
$customer = new EDD_Customer( $user_id, true );
|
869 |
+
if ( $customer->email === $email || ( is_array( $customer->emails ) && in_array( $email, $customer->emails ) ) ) {
|
870 |
+
$customer->set_primary_email( $email );
|
871 |
+
};
|
872 |
+
|
873 |
if ( $customer->id > 0 ) {
|
874 |
$update_args = array(
|
875 |
+
'name' => $first_name . ' ' . $last_name,
|
876 |
);
|
877 |
|
878 |
$customer->update( $update_args );
|
885 |
}
|
886 |
}
|
887 |
add_action( 'edd_edit_user_profile', 'edd_process_profile_editor_updates' );
|
888 |
+
|
889 |
+
/**
|
890 |
+
* Process the 'remove' URL on the profile editor when customers wish to remove an email address
|
891 |
+
*
|
892 |
+
* @since 2.6
|
893 |
+
* @return void
|
894 |
+
*/
|
895 |
+
function edd_process_profile_editor_remove_email() {
|
896 |
+
if ( ! is_user_logged_in() ) {
|
897 |
+
return false;
|
898 |
+
}
|
899 |
+
|
900 |
+
// Pending users can't edit their profile
|
901 |
+
if ( edd_user_pending_verification() ) {
|
902 |
+
return false;
|
903 |
+
}
|
904 |
+
|
905 |
+
// Nonce security
|
906 |
+
if ( ! wp_verify_nonce( $_GET['_wpnonce'], 'edd-remove-customer-email' ) ) {
|
907 |
+
return false;
|
908 |
+
}
|
909 |
+
|
910 |
+
if ( empty( $_GET['email'] ) || ! is_email( $_GET['email'] ) ) {
|
911 |
+
return false;
|
912 |
+
}
|
913 |
+
|
914 |
+
$customer = new EDD_Customer( get_current_user_id(), true );
|
915 |
+
if ( $customer->remove_email( $_GET['email'] ) ) {
|
916 |
+
|
917 |
+
$url = add_query_arg( 'updated', true, $_GET['redirect'] );
|
918 |
+
|
919 |
+
$user = wp_get_current_user();
|
920 |
+
$user_login = ! empty( $user->user_login ) ? $user->user_login : 'EDDBot';
|
921 |
+
$customer_note = __( sprintf( 'Email address %s removed by %s', $_GET['email'], $user_login ), 'easy-digital-downloads' );
|
922 |
+
$customer->add_note( $customer_note );
|
923 |
+
|
924 |
+
} else {
|
925 |
+
edd_set_error( 'profile-remove-email-failure', __( 'Error removing email address from profile. Please try again later.', 'easy-digital-downloads' ) );
|
926 |
+
$url = $_GET['redirect'];
|
927 |
+
}
|
928 |
+
|
929 |
+
wp_safe_redirect( $url );
|
930 |
+
exit;
|
931 |
+
}
|
932 |
+
add_action( 'edd_profile-remove-email', 'edd_process_profile_editor_remove_email' );
|
includes/template-functions.php
CHANGED
@@ -234,6 +234,14 @@ function edd_get_purchase_link( $args = array() ) {
|
|
234 |
* @return void
|
235 |
*/
|
236 |
function edd_purchase_variable_pricing( $download_id = 0, $args = array() ) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
237 |
$variable_pricing = edd_has_variable_prices( $download_id );
|
238 |
|
239 |
if ( ! $variable_pricing ) {
|
@@ -262,10 +270,19 @@ function edd_purchase_variable_pricing( $download_id = 0, $args = array() ) {
|
|
262 |
if ( $prices ) :
|
263 |
$checked_key = isset( $_GET['price_option'] ) ? absint( $_GET['price_option'] ) : edd_get_default_variable_price( $download_id );
|
264 |
foreach ( $prices as $key => $price ) :
|
265 |
-
echo '<li id="edd_price_option_' . $download_id . '_' . sanitize_key( $price['name'] ) . '"' . $schema . '>';
|
266 |
-
echo '<label for="'
|
267 |
-
echo '<input type="' . $type . '" ' . checked( apply_filters( 'edd_price_option_checked', $checked_key, $download_id, $key ), $key, false ) . ' name="edd_options[price_id][]" id="' . esc_attr( 'edd_price_option_' . $download_id . '_' . $key ) . '" class="' . esc_attr( 'edd_price_option_' . $download_id ) . '" value="' . esc_attr( $key ) . '" data-price="' . edd_get_price_option_amount( $download_id, $key ) .'"/> ';
|
268 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
269 |
echo '</label>';
|
270 |
do_action( 'edd_after_price_option', $key, $price, $download_id );
|
271 |
echo '</li>';
|
@@ -922,3 +939,48 @@ function edd_add_download_post_classes( $classes, $class = '', $post_id = false
|
|
922 |
return $classes;
|
923 |
}
|
924 |
add_filter( 'post_class', 'edd_add_download_post_classes', 20, 3 );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
234 |
* @return void
|
235 |
*/
|
236 |
function edd_purchase_variable_pricing( $download_id = 0, $args = array() ) {
|
237 |
+
global $edd_displayed_form_ids;
|
238 |
+
|
239 |
+
// If we've already generated a form ID for this download ID, apped -#
|
240 |
+
$form_id = '';
|
241 |
+
if ( $edd_displayed_form_ids[ $download_id ] > 1 ) {
|
242 |
+
$form_id .= '-' . $edd_displayed_form_ids[ $download_id ];
|
243 |
+
}
|
244 |
+
|
245 |
$variable_pricing = edd_has_variable_prices( $download_id );
|
246 |
|
247 |
if ( ! $variable_pricing ) {
|
270 |
if ( $prices ) :
|
271 |
$checked_key = isset( $_GET['price_option'] ) ? absint( $_GET['price_option'] ) : edd_get_default_variable_price( $download_id );
|
272 |
foreach ( $prices as $key => $price ) :
|
273 |
+
echo '<li id="edd_price_option_' . $download_id . '_' . sanitize_key( $price['name'] ) . $form_id . '"' . $schema . '>';
|
274 |
+
echo '<label for="' . esc_attr( 'edd_price_option_' . $download_id . '_' . $key . $form_id ) . '">';
|
275 |
+
echo '<input type="' . $type . '" ' . checked( apply_filters( 'edd_price_option_checked', $checked_key, $download_id, $key ), $key, false ) . ' name="edd_options[price_id][]" id="' . esc_attr( 'edd_price_option_' . $download_id . '_' . $key . $form_id ) . '" class="' . esc_attr( 'edd_price_option_' . $download_id ) . '" value="' . esc_attr( $key ) . '" data-price="' . edd_get_price_option_amount( $download_id, $key ) .'"/> ';
|
276 |
+
|
277 |
+
$item_prop = edd_add_schema_microdata() ? ' itemprop="description"' : '';
|
278 |
+
|
279 |
+
echo '<span class="edd_price_option_name"' . $item_prop . '>' . esc_html( $price['name'] ) . '</span><span class="edd_price_option_sep"> – </span><span class="edd_price_option_price">' . edd_currency_filter( edd_format_amount( $price['amount'] ) ) . '</span>';
|
280 |
+
|
281 |
+
if( edd_add_schema_microdata() ) {
|
282 |
+
echo '<meta itemprop="price" content="' . esc_attr( $price['amount'] ) .'" />';
|
283 |
+
echo '<meta itemprop="priceCurrency" content="' . esc_attr( edd_get_currency() ) .'" />';
|
284 |
+
}
|
285 |
+
|
286 |
echo '</label>';
|
287 |
do_action( 'edd_after_price_option', $key, $price, $download_id );
|
288 |
echo '</li>';
|
939 |
return $classes;
|
940 |
}
|
941 |
add_filter( 'post_class', 'edd_add_download_post_classes', 20, 3 );
|
942 |
+
|
943 |
+
/**
|
944 |
+
* Adds Download product price to oembed display
|
945 |
+
*
|
946 |
+
* @since 2.6
|
947 |
+
* @return void
|
948 |
+
*/
|
949 |
+
function edd_add_oembed_price() {
|
950 |
+
|
951 |
+
if( 'download' !== get_post_type( get_the_ID() ) ) {
|
952 |
+
return;
|
953 |
+
}
|
954 |
+
|
955 |
+
$show = ! get_post_meta( get_the_ID(), '_edd_hide_purchase_link', true );
|
956 |
+
|
957 |
+
if ( apply_filters( 'edd_show_oembed_purchase_links', $show ) ) {
|
958 |
+
echo '<style>.wp-embed-edd-price { margin: 20px 0 0 0; }</style>';
|
959 |
+
echo '<div class="wp-embed-edd-price">';
|
960 |
+
if ( edd_has_variable_prices( get_the_ID() ) ) {
|
961 |
+
echo edd_price_range( get_the_ID() );
|
962 |
+
} else {
|
963 |
+
edd_price( get_the_ID(), true );
|
964 |
+
}
|
965 |
+
|
966 |
+
echo '</div>';
|
967 |
+
}
|
968 |
+
}
|
969 |
+
add_action( 'embed_content', 'edd_add_oembed_price' );
|
970 |
+
|
971 |
+
/**
|
972 |
+
* Remove comments button for download embeds
|
973 |
+
*
|
974 |
+
* @since 2.6
|
975 |
+
* @return void
|
976 |
+
*/
|
977 |
+
function edd_remove_embed_comments_button() {
|
978 |
+
global $post;
|
979 |
+
|
980 |
+
$hide_comments = apply_filters( 'edd_embed_hide_comments', true, $post );
|
981 |
+
|
982 |
+
if ( ! empty( $post ) && $post->post_type == 'download' && true === $hide_comments ) {
|
983 |
+
remove_action( 'embed_content_meta', 'print_embed_comments_button' );
|
984 |
+
}
|
985 |
+
}
|
986 |
+
add_action( 'embed_content_meta', 'edd_remove_embed_comments_button', 5 );
|
includes/user-functions.php
CHANGED
@@ -133,7 +133,16 @@ function edd_get_users_purchased_products( $user = 0, $status = 'complete' ) {
|
|
133 |
// Grab only the post ids of the products purchased on this order
|
134 |
$purchase_product_ids = array();
|
135 |
foreach ( $purchase_data as $purchase_meta ) {
|
136 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
137 |
}
|
138 |
|
139 |
// Ensure that grabbed products actually HAVE downloads
|
@@ -153,15 +162,16 @@ function edd_get_users_purchased_products( $user = 0, $status = 'complete' ) {
|
|
153 |
$product_ids = array_unique( $purchased_products );
|
154 |
|
155 |
// Make sure we still have some products and a first item
|
156 |
-
if ( empty ( $product_ids ) || ! isset( $product_ids[0] ) )
|
157 |
return false;
|
|
|
158 |
|
159 |
$post_type = get_post_type( $product_ids[0] );
|
160 |
|
161 |
$args = apply_filters( 'edd_get_users_purchased_products_args', array(
|
162 |
-
'include'
|
163 |
-
'post_type'
|
164 |
-
'posts_per_page'
|
165 |
) );
|
166 |
|
167 |
return apply_filters( 'edd_users_purchased_products_list', get_posts( $args ) );
|
@@ -227,7 +237,7 @@ function edd_has_user_purchased( $user_id, $downloads, $variable_price_id = null
|
|
227 |
*
|
228 |
* @access public
|
229 |
* @since 1.0
|
230 |
-
* @param $user_id
|
231 |
* @return bool - true if has purchased, false other wise.
|
232 |
*/
|
233 |
function edd_has_purchases( $user_id = null ) {
|
@@ -249,8 +259,8 @@ function edd_has_purchases( $user_id = null ) {
|
|
249 |
*
|
250 |
* @access public
|
251 |
* @since 1.6
|
252 |
-
* @param
|
253 |
-
* @param $mode
|
254 |
* @return array
|
255 |
*/
|
256 |
function edd_get_purchase_stats_by_user( $user = '' ) {
|
@@ -289,7 +299,7 @@ function edd_get_purchase_stats_by_user( $user = '' ) {
|
|
289 |
*
|
290 |
* @access public
|
291 |
* @since 1.3
|
292 |
-
* @param $user
|
293 |
* @return int - the total number of purchases
|
294 |
*/
|
295 |
function edd_count_purchases_of_customer( $user = null ) {
|
@@ -307,7 +317,7 @@ function edd_count_purchases_of_customer( $user = null ) {
|
|
307 |
*
|
308 |
* @access public
|
309 |
* @since 1.3
|
310 |
-
* @param $user
|
311 |
* @return float - the total amount the user has spent
|
312 |
*/
|
313 |
function edd_purchase_total_of_user( $user = null ) {
|
@@ -322,7 +332,7 @@ function edd_purchase_total_of_user( $user = null ) {
|
|
322 |
*
|
323 |
* @access public
|
324 |
* @since 1.3
|
325 |
-
* @param $user
|
326 |
* @return int - The total number of files the user has downloaded
|
327 |
*/
|
328 |
function edd_count_file_downloads_of_user( $user ) {
|
@@ -389,7 +399,7 @@ add_action( 'user_register', 'edd_connect_existing_customer_to_new_user', 10, 1
|
|
389 |
*
|
390 |
* @access public
|
391 |
* @since 1.6
|
392 |
-
* @param $user_id
|
393 |
* @return void
|
394 |
*/
|
395 |
function edd_add_past_purchases_to_new_user( $user_id ) {
|
@@ -432,8 +442,8 @@ add_action( 'user_register', 'edd_add_past_purchases_to_new_user', 10, 1 );
|
|
432 |
* @since 1.7
|
433 |
* @return int - The total number of customers.
|
434 |
*/
|
435 |
-
function edd_count_total_customers() {
|
436 |
-
return EDD()->customers->count();
|
437 |
}
|
438 |
|
439 |
|
@@ -487,7 +497,7 @@ function edd_new_user_notification( $user_id = 0, $user_data = array() ) {
|
|
487 |
return;
|
488 |
}
|
489 |
|
490 |
-
$emails =
|
491 |
$from_name = edd_get_option( 'from_name', wp_specialchars_decode( get_bloginfo( 'name' ), ENT_QUOTES ) );
|
492 |
$from_email = edd_get_option( 'from_email', get_bloginfo( 'admin_email' ) );
|
493 |
|
@@ -506,7 +516,15 @@ function edd_new_user_notification( $user_id = 0, $user_data = array() ) {
|
|
506 |
$user_subject = sprintf( __( '[%s] Your username and password', 'easy-digital-downloads' ), $from_name );
|
507 |
$user_heading = __( 'Your account info', 'easy-digital-downloads' );
|
508 |
$user_message = sprintf( __( 'Username: %s', 'easy-digital-downloads' ), $user_data['user_login'] ) . "\r\n";
|
509 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
510 |
$user_message .= '<a href="' . wp_login_url() . '"> ' . esc_attr__( 'Click Here to Log In', 'easy-digital-downloads' ) . ' »</a>' . "\r\n";
|
511 |
|
512 |
$emails->__set( 'heading', $user_heading );
|
@@ -922,3 +940,75 @@ function edd_detach_deleted_user( $user_id ) {
|
|
922 |
return $detached;
|
923 |
}
|
924 |
add_action( 'delete_user', 'edd_detach_deleted_user', 10, 1 );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
133 |
// Grab only the post ids of the products purchased on this order
|
134 |
$purchase_product_ids = array();
|
135 |
foreach ( $purchase_data as $purchase_meta ) {
|
136 |
+
|
137 |
+
$purchase_ids = @wp_list_pluck( $purchase_meta, 'id' );
|
138 |
+
|
139 |
+
if ( ! is_array( $purchase_ids ) || empty( $purchase_ids ) ) {
|
140 |
+
continue;
|
141 |
+
}
|
142 |
+
|
143 |
+
$purchase_ids = array_values( $purchase_ids );
|
144 |
+
$purchase_product_ids[] = $purchase_ids;
|
145 |
+
|
146 |
}
|
147 |
|
148 |
// Ensure that grabbed products actually HAVE downloads
|
162 |
$product_ids = array_unique( $purchased_products );
|
163 |
|
164 |
// Make sure we still have some products and a first item
|
165 |
+
if ( empty ( $product_ids ) || ! isset( $product_ids[0] ) ) {
|
166 |
return false;
|
167 |
+
}
|
168 |
|
169 |
$post_type = get_post_type( $product_ids[0] );
|
170 |
|
171 |
$args = apply_filters( 'edd_get_users_purchased_products_args', array(
|
172 |
+
'include' => $product_ids,
|
173 |
+
'post_type' => $post_type,
|
174 |
+
'posts_per_page' => -1,
|
175 |
) );
|
176 |
|
177 |
return apply_filters( 'edd_users_purchased_products_list', get_posts( $args ) );
|
237 |
*
|
238 |
* @access public
|
239 |
* @since 1.0
|
240 |
+
* @param int $user_id - the ID of the user to check
|
241 |
* @return bool - true if has purchased, false other wise.
|
242 |
*/
|
243 |
function edd_has_purchases( $user_id = null ) {
|
259 |
*
|
260 |
* @access public
|
261 |
* @since 1.6
|
262 |
+
* @param int|string $user - the ID or email of the customer to retrieve stats for
|
263 |
+
* @param string $mode - "test" or "live"
|
264 |
* @return array
|
265 |
*/
|
266 |
function edd_get_purchase_stats_by_user( $user = '' ) {
|
299 |
*
|
300 |
* @access public
|
301 |
* @since 1.3
|
302 |
+
* @param mixed $user - ID or email
|
303 |
* @return int - the total number of purchases
|
304 |
*/
|
305 |
function edd_count_purchases_of_customer( $user = null ) {
|
317 |
*
|
318 |
* @access public
|
319 |
* @since 1.3
|
320 |
+
* @param mixed $user - ID or email
|
321 |
* @return float - the total amount the user has spent
|
322 |
*/
|
323 |
function edd_purchase_total_of_user( $user = null ) {
|
332 |
*
|
333 |
* @access public
|
334 |
* @since 1.3
|
335 |
+
* @param mixed $user - ID or email
|
336 |
* @return int - The total number of files the user has downloaded
|
337 |
*/
|
338 |
function edd_count_file_downloads_of_user( $user ) {
|
399 |
*
|
400 |
* @access public
|
401 |
* @since 1.6
|
402 |
+
* @param int $user_id - the new user's ID
|
403 |
* @return void
|
404 |
*/
|
405 |
function edd_add_past_purchases_to_new_user( $user_id ) {
|
442 |
* @since 1.7
|
443 |
* @return int - The total number of customers.
|
444 |
*/
|
445 |
+
function edd_count_total_customers( $args = array() ) {
|
446 |
+
return EDD()->customers->count( $args );
|
447 |
}
|
448 |
|
449 |
|
497 |
return;
|
498 |
}
|
499 |
|
500 |
+
$emails = EDD()->emails;
|
501 |
$from_name = edd_get_option( 'from_name', wp_specialchars_decode( get_bloginfo( 'name' ), ENT_QUOTES ) );
|
502 |
$from_email = edd_get_option( 'from_email', get_bloginfo( 'admin_email' ) );
|
503 |
|
516 |
$user_subject = sprintf( __( '[%s] Your username and password', 'easy-digital-downloads' ), $from_name );
|
517 |
$user_heading = __( 'Your account info', 'easy-digital-downloads' );
|
518 |
$user_message = sprintf( __( 'Username: %s', 'easy-digital-downloads' ), $user_data['user_login'] ) . "\r\n";
|
519 |
+
|
520 |
+
if ( did_action( 'edd_pre_process_purchase' ) ) {
|
521 |
+
$password_message = __( 'Password entered at checkout', 'easy-digital-downloads' );
|
522 |
+
} else {
|
523 |
+
$password_message = __( 'Password entered at registration', 'easy-digital-downloads' );
|
524 |
+
}
|
525 |
+
|
526 |
+
$user_message .= sprintf( __( 'Password: %s', 'easy-digital-downloads' ), '[' . $password_message . ']' ) . "\r\n";
|
527 |
+
|
528 |
$user_message .= '<a href="' . wp_login_url() . '"> ' . esc_attr__( 'Click Here to Log In', 'easy-digital-downloads' ) . ' »</a>' . "\r\n";
|
529 |
|
530 |
$emails->__set( 'heading', $user_heading );
|
940 |
return $detached;
|
941 |
}
|
942 |
add_action( 'delete_user', 'edd_detach_deleted_user', 10, 1 );
|
943 |
+
|
944 |
+
/**
|
945 |
+
* Modify User Profile
|
946 |
+
*
|
947 |
+
* Modifies the output of profile.php to add key generation/revocation
|
948 |
+
*
|
949 |
+
* @since 2.6
|
950 |
+
* @param object $user Current user info
|
951 |
+
* @return void
|
952 |
+
*/
|
953 |
+
function edd_show_user_api_key_field( $user ) {
|
954 |
+
if ( ( edd_get_option( 'api_allow_user_keys', false ) || current_user_can( 'manage_shop_settings' ) ) && current_user_can( 'edit_user', $user->ID ) ) {
|
955 |
+
$user = get_userdata( $user->ID );
|
956 |
+
?>
|
957 |
+
<table class="form-table">
|
958 |
+
<tbody>
|
959 |
+
<tr>
|
960 |
+
<th>
|
961 |
+
<?php _e( 'Easy Digital Downloads API Keys', 'easy-digital-downloads' ); ?>
|
962 |
+
</th>
|
963 |
+
<td>
|
964 |
+
<?php
|
965 |
+
$public_key = EDD()->api->get_user_public_key( $user->ID );
|
966 |
+
$secret_key = EDD()->api->get_user_secret_key( $user->ID );
|
967 |
+
?>
|
968 |
+
<?php if ( empty( $user->edd_user_public_key ) ) { ?>
|
969 |
+
<input name="edd_set_api_key" type="checkbox" id="edd_set_api_key" value="0" />
|
970 |
+
<span class="description"><?php _e( 'Generate API Key', 'easy-digital-downloads' ); ?></span>
|
971 |
+
<?php } else { ?>
|
972 |
+
<strong style="display:inline-block; width: 125px;"><?php _e( 'Public key:', 'easy-digital-downloads' ); ?> </strong><input type="text" disabled="disabled" class="regular-text" id="publickey" value="<?php echo esc_attr( $public_key ); ?>"/><br/>
|
973 |
+
<strong style="display:inline-block; width: 125px;"><?php _e( 'Secret key:', 'easy-digital-downloads' ); ?> </strong><input type="text" disabled="disabled" class="regular-text" id="privatekey" value="<?php echo esc_attr( $secret_key ); ?>"/><br/>
|
974 |
+
<strong style="display:inline-block; width: 125px;"><?php _e( 'Token:', 'easy-digital-downloads' ); ?> </strong><input type="text" disabled="disabled" class="regular-text" id="token" value="<?php echo esc_attr( EDD()->api->get_token( $user->ID ) ); ?>"/><br/>
|
975 |
+
<input name="edd_set_api_key" type="checkbox" id="edd_set_api_key" value="0" />
|
976 |
+
<span class="description"><label for="edd_set_api_key"><?php _e( 'Revoke API Keys', 'easy-digital-downloads' ); ?></label></span>
|
977 |
+
<?php } ?>
|
978 |
+
</td>
|
979 |
+
</tr>
|
980 |
+
</tbody>
|
981 |
+
</table>
|
982 |
+
<?php }
|
983 |
+
}
|
984 |
+
add_action( 'show_user_profile', 'edd_show_user_api_key_field' );
|
985 |
+
add_action( 'edit_user_profile', 'edd_show_user_api_key_field' );
|
986 |
+
|
987 |
+
/**
|
988 |
+
* Generate and Save API key
|
989 |
+
*
|
990 |
+
* Generates the key requested by user_key_field and stores it in the database
|
991 |
+
*
|
992 |
+
* @since 2.6
|
993 |
+
* @param int $user_id
|
994 |
+
* @return void
|
995 |
+
*/
|
996 |
+
function edd_update_user_api_key( $user_id ) {
|
997 |
+
if ( current_user_can( 'edit_user', $user_id ) && isset( $_POST['edd_set_api_key'] ) ) {
|
998 |
+
|
999 |
+
$user = get_userdata( $user_id );
|
1000 |
+
$public_key = EDD()->api->get_user_public_key( $user_id );
|
1001 |
+
|
1002 |
+
if ( empty( $public_key ) ) {
|
1003 |
+
$new_public_key = EDD()->api->generate_public_key( $user->user_email );
|
1004 |
+
$new_secret_key = EDD()->api->generate_private_key( $user->ID );
|
1005 |
+
|
1006 |
+
update_user_meta( $user_id, $new_public_key, 'edd_user_public_key' );
|
1007 |
+
update_user_meta( $user_id, $new_secret_key, 'edd_user_secret_key' );
|
1008 |
+
} else {
|
1009 |
+
EDD()->api->revoke_api_key( $user_id );
|
1010 |
+
}
|
1011 |
+
}
|
1012 |
+
}
|
1013 |
+
add_action( 'personal_options_update', 'edd_update_user_api_key' );
|
1014 |
+
add_action( 'edit_user_profile_update', 'edd_update_user_api_key' );
|
languages/easy-digital-downloads-af.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-am.mo
ADDED
Binary file
|
languages/easy-digital-downloads-an.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ar.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ary.mo
ADDED
Binary file
|
languages/easy-digital-downloads-as.mo
ADDED
Binary file
|
languages/easy-digital-downloads-az.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-azb.mo
ADDED
Binary file
|
languages/easy-digital-downloads-bel.mo
ADDED
Binary file
|
languages/easy-digital-downloads-bg_BG.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-bn_BD.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-bs_BA.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ca.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ceb.mo
ADDED
Binary file
|
languages/easy-digital-downloads-co.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-cs_CZ.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-cy.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-da_DK.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-de_CH.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-de_DE.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-el.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-en_AU.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-en_CA.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-en_GB.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-en_NZ.mo
ADDED
Binary file
|
languages/easy-digital-downloads-en_ZA.mo
ADDED
Binary file
|
languages/easy-digital-downloads-eo.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-es_AR.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-es_CL.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-es_ES.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-es_MX.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-es_PE.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-es_VE.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-et.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-eu.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-fa_IR.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-fi.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-fo.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-fr_BE.mo
ADDED
Binary file
|
languages/easy-digital-downloads-fr_CA.mo
ADDED
Binary file
|
languages/easy-digital-downloads-fr_FR.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-fy.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ga.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-gd.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-gl_ES.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-he_IL.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-hi_IN.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-hr.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-hu_HU.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-hy.mo
ADDED
Binary file
|
languages/easy-digital-downloads-id_ID.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-is_IS.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-it_IT.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ja.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-jv_ID.mo
ADDED
Binary file
|
languages/easy-digital-downloads-ka_GE.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-kk.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-km.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-kn.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ko_KR.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ky_KY.mo
ADDED
Binary file
|
languages/easy-digital-downloads-lb_LU.mo
ADDED
Binary file
|
languages/easy-digital-downloads-lo.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-lt_LT.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-lv.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-mg_MG.mo
ADDED
Binary file
|
languages/easy-digital-downloads-mk_MK.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ml_IN.mo
ADDED
Binary file
|
languages/easy-digital-downloads-mn.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ms_MY.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-my_MM.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-nb_NO.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ne_NP.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-nl_NL.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-nn_NO.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-oci.mo
ADDED
Binary file
|
languages/easy-digital-downloads-os.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-pa_IN.mo
ADDED
Binary file
|
languages/easy-digital-downloads-pl_PL.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ps.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-pt_BR.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-pt_PT.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ro_RO.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ru_RU.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-sah.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-si_LK.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-sk_SK.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-sl_SI.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-snd.mo
ADDED
Binary file
|
languages/easy-digital-downloads-so_SO.mo
ADDED
Binary file
|
languages/easy-digital-downloads-sq.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-sr_RS.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-su_ID.mo
ADDED
Binary file
|
languages/easy-digital-downloads-sv_SE.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-sw.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ta_IN.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ta_LK.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-te.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-tg.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-th.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-tl.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-tr_TR.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ug_CN.mo
ADDED
Binary file
|
languages/easy-digital-downloads-uk.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-ur.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-uz_UZ.mo
ADDED
Binary file
|
languages/easy-digital-downloads-vi.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-zh_CN.mo
CHANGED
Binary file
|
languages/easy-digital-downloads-zh_TW.mo
CHANGED
Binary file
|
languages/easy-digital-downloads.mo
ADDED
Binary file
|
languages/easy-digital-downloads.pot
CHANGED
@@ -2,16 +2,16 @@
|
|
2 |
# This file is distributed under the same license as the Easy Digital Downloads package.
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
-
"Project-Id-Version: Easy Digital Downloads 2.
|
6 |
"Report-Msgid-Bugs-To: https://easydigitaldownloads.com/\n"
|
7 |
-
"POT-Creation-Date: 2016-
|
8 |
"MIME-Version: 1.0\n"
|
9 |
"Content-Type: text/plain; charset=utf-8\n"
|
10 |
"Content-Transfer-Encoding: 8bit\n"
|
11 |
"PO-Revision-Date: 2016-MO-DA HO:MI+ZONE\n"
|
12 |
"Last-Translator: WP-Translations (http://wp-translations.org/)\n"
|
13 |
"Language-Team: WP-Translations <wpt@wp-translations.org>\n"
|
14 |
-
"X-Generator: grunt-wp-i18n 0.5.
|
15 |
"X-Poedit-KeywordsList: "
|
16 |
"__;_e;_x:1,2c;_ex:1,2c;_n:1,2;_nx:1,2,4c;_n_noop:1,2;_nx_noop:1,2,3c;esc_"
|
17 |
"attr__;esc_html__;esc_attr_e;esc_html_e;esc_attr_x:1,2c;esc_html_x:1,2c;\n"
|
@@ -24,7 +24,7 @@ msgstr ""
|
|
24 |
"X-Poedit-Bookmarks: \n"
|
25 |
"X-Textdomain-Support: yes\n"
|
26 |
|
27 |
-
#: easy-digital-downloads.php:
|
28 |
msgid "Cheatin’ huh?"
|
29 |
msgstr ""
|
30 |
|
@@ -38,12 +38,14 @@ msgid ""
|
|
38 |
"or %5$supdate now%6$s."
|
39 |
msgstr ""
|
40 |
|
41 |
-
#: includes/EDD_SL_Plugin_Updater.php:
|
42 |
msgid "You do not have permission to install plugin updates"
|
43 |
msgstr ""
|
44 |
|
45 |
-
#: includes/EDD_SL_Plugin_Updater.php:
|
46 |
-
#: includes/admin/customers/customer-actions.php:
|
|
|
|
|
47 |
#: includes/admin/discounts/discount-actions.php:30
|
48 |
#: includes/admin/discounts/discount-actions.php:92
|
49 |
#: includes/admin/discounts/discount-actions.php:144
|
@@ -53,6 +55,9 @@ msgstr ""
|
|
53 |
#: includes/admin/discounts/discount-actions.php:194
|
54 |
#: includes/admin/discounts/edit-discount.php:16
|
55 |
#: includes/admin/downloads/dashboard-columns.php:171
|
|
|
|
|
|
|
56 |
#: includes/admin/payments/actions.php:25
|
57 |
#: includes/admin/payments/actions.php:145
|
58 |
#: includes/admin/payments/actions.php:291
|
@@ -75,27 +80,27 @@ msgstr ""
|
|
75 |
#: includes/admin/tools/class-edd-tools-recount-single-customer-stats.php:149
|
76 |
#: includes/admin/tools/class-edd-tools-recount-store-earnings.php:154
|
77 |
#: includes/admin/tools/class-edd-tools-reset-stats.php:180
|
78 |
-
#: includes/admin/tools.php:
|
79 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
80 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
81 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
82 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
83 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
84 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
85 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
86 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
87 |
-
#: includes/api/class-edd-api.php:
|
88 |
-
#: includes/api/class-edd-api.php:
|
89 |
-
#: includes/cart/functions.php:
|
90 |
#: includes/class-edd-license-handler.php:304
|
91 |
#: includes/deprecated-functions.php:517 includes/deprecated-functions.php:532
|
92 |
#: includes/deprecated-functions.php:542 includes/download-functions.php:1228
|
93 |
#: includes/emails/actions.php:49 includes/emails/template.php:245
|
94 |
#: includes/error-tracking.php:36 includes/gateways/functions.php:221
|
95 |
-
#: includes/gateways/manual.php:33 includes/gateways/paypal-standard.php:
|
96 |
#: includes/process-download.php:254 includes/process-download.php:787
|
97 |
-
#: includes/query-filters.php:48 includes/user-functions.php:
|
98 |
-
#: includes/user-functions.php:
|
99 |
msgid "Error"
|
100 |
msgstr ""
|
101 |
|
@@ -127,7 +132,7 @@ msgid ""
|
|
127 |
msgstr ""
|
128 |
|
129 |
#: includes/admin/admin-pages.php:38
|
130 |
-
#: includes/admin/customers/class-customer-table.php:
|
131 |
#: includes/admin/customers/customers.php:63
|
132 |
msgid "Customers"
|
133 |
msgstr ""
|
@@ -159,7 +164,7 @@ msgstr ""
|
|
159 |
msgid "Easy Digital Download Info and Tools"
|
160 |
msgstr ""
|
161 |
|
162 |
-
#: includes/admin/admin-pages.php:42 includes/admin/customers/customers.php:
|
163 |
msgid "Tools"
|
164 |
msgstr ""
|
165 |
|
@@ -169,7 +174,7 @@ msgstr ""
|
|
169 |
|
170 |
#: includes/admin/admin-pages.php:43 includes/admin/plugins.php:58
|
171 |
#: includes/admin/settings/contextual-help.php:87
|
172 |
-
#: includes/admin/settings/register-settings.php:
|
173 |
msgid "Extensions"
|
174 |
msgstr ""
|
175 |
|
@@ -199,8 +204,8 @@ msgstr ""
|
|
199 |
|
200 |
#: includes/admin/class-api-keys-table.php:176
|
201 |
#: includes/checkout/template.php:466 includes/checkout/template.php:472
|
202 |
-
#: includes/checkout/template.php:538 templates/shortcode-
|
203 |
-
#: templates/shortcode-register.php:
|
204 |
msgid "Username"
|
205 |
msgstr ""
|
206 |
|
@@ -343,37 +348,57 @@ msgstr ""
|
|
343 |
msgid "User successfully verified"
|
344 |
msgstr ""
|
345 |
|
346 |
-
#: includes/admin/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
347 |
#: includes/admin/payments/class-payments-table.php:227
|
348 |
msgid "Customer"
|
349 |
msgstr ""
|
350 |
|
351 |
-
#: includes/admin/customers/class-customer-table.php:
|
352 |
msgid "Unnamed Customer"
|
353 |
msgstr ""
|
354 |
|
355 |
-
#: includes/admin/customers/class-customer-table.php:
|
356 |
msgid "View"
|
357 |
msgstr ""
|
358 |
|
359 |
-
#: includes/admin/customers/class-customer-table.php:
|
360 |
msgid "Download log"
|
361 |
msgstr ""
|
362 |
|
363 |
-
#: includes/admin/customers/class-customer-table.php:
|
364 |
#: includes/admin/discounts/class-discount-codes-table.php:221
|
365 |
#: includes/admin/discounts/class-discount-codes-table.php:289
|
366 |
#: includes/admin/payments/class-payments-table.php:323
|
367 |
#: includes/admin/payments/class-payments-table.php:395
|
368 |
-
#: includes/payments/functions.php:
|
369 |
msgid "Delete"
|
370 |
msgstr ""
|
371 |
|
372 |
-
#: includes/admin/customers/class-customer-table.php:
|
373 |
msgid "(Pending Verification)"
|
374 |
msgstr ""
|
375 |
|
376 |
-
#: includes/admin/customers/class-customer-table.php:
|
377 |
#: includes/admin/discounts/add-discount.php:23
|
378 |
#: includes/admin/discounts/class-discount-codes-table.php:145
|
379 |
#: includes/admin/discounts/edit-discount.php:37
|
@@ -385,40 +410,34 @@ msgstr ""
|
|
385 |
msgid "Name"
|
386 |
msgstr ""
|
387 |
|
388 |
-
#: includes/admin/customers/class-customer-table.php:
|
389 |
-
|
390 |
-
#: includes/admin/reporting/class-export-customers.php:68
|
391 |
-
#: includes/admin/reporting/class-export-customers.php:79
|
392 |
-
#: includes/admin/reporting/class-export-payments.php:63
|
393 |
-
#: includes/admin/reporting/export/class-batch-export-customers.php:44
|
394 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:42
|
395 |
-
#: templates/shortcode-register.php:23
|
396 |
-
msgid "Email"
|
397 |
msgstr ""
|
398 |
|
399 |
-
#: includes/admin/customers/class-customer-table.php:
|
400 |
msgid "Purchases"
|
401 |
msgstr ""
|
402 |
|
403 |
-
#: includes/admin/customers/class-customer-table.php:
|
404 |
msgid "Total Spent"
|
405 |
msgstr ""
|
406 |
|
407 |
-
#: includes/admin/customers/class-customer-table.php:
|
408 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:45
|
409 |
msgid "Date Created"
|
410 |
msgstr ""
|
411 |
|
412 |
#: includes/admin/customers/customer-actions.php:17
|
413 |
#: includes/admin/customers/customer-actions.php:169
|
414 |
-
#: includes/admin/customers/customer-actions.php:
|
|
|
415 |
msgid "You do not have permission to edit this customer."
|
416 |
msgstr ""
|
417 |
|
418 |
#: includes/admin/customers/customer-actions.php:29
|
419 |
-
#: includes/admin/customers/customer-actions.php:
|
420 |
-
#: includes/admin/customers/customer-actions.php:
|
421 |
-
#: includes/admin/customers/customer-actions.php:
|
422 |
msgid "Cheatin' eh?!"
|
423 |
msgstr ""
|
424 |
|
@@ -434,38 +453,75 @@ msgstr ""
|
|
434 |
msgid "The User ID %d does not exist. Please assign an existing user."
|
435 |
msgstr ""
|
436 |
|
437 |
-
#: includes/admin/customers/customer-actions.php:
|
438 |
-
msgid "
|
439 |
msgstr ""
|
440 |
|
441 |
-
#: includes/admin/customers/customer-actions.php:
|
442 |
-
msgid "
|
443 |
msgstr ""
|
444 |
|
445 |
-
#: includes/admin/customers/customer-actions.php:
|
446 |
-
msgid "
|
447 |
msgstr ""
|
448 |
|
449 |
-
#: includes/admin/customers/customer-actions.php:
|
450 |
-
|
|
|
451 |
msgstr ""
|
452 |
|
453 |
-
#: includes/admin/customers/customer-actions.php:
|
454 |
-
msgid "Invalid
|
455 |
msgstr ""
|
456 |
|
457 |
-
#: includes/admin/customers/customer-actions.php:
|
458 |
-
msgid "
|
|
|
|
|
|
|
|
|
459 |
msgstr ""
|
460 |
|
461 |
-
#: includes/admin/customers/customer-actions.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
462 |
#: includes/admin/reporting/export/export-actions.php:23
|
463 |
#: includes/admin/reporting/pdf-reports.php:33
|
464 |
-
#: includes/api/class-edd-api.php:
|
465 |
#: includes/class-edd-license-handler.php:304
|
466 |
msgid "Nonce verification failed"
|
467 |
msgstr ""
|
468 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
469 |
#: includes/admin/customers/customer-functions.php:37
|
470 |
msgid "Customer Profile"
|
471 |
msgstr ""
|
@@ -479,7 +535,7 @@ msgid "Customer Tools"
|
|
479 |
msgstr ""
|
480 |
|
481 |
#: includes/admin/customers/customer-functions.php:55
|
482 |
-
#: includes/admin/customers/customers.php:
|
483 |
msgid "Delete Customer"
|
484 |
msgstr ""
|
485 |
|
@@ -509,127 +565,173 @@ msgid "Invalid Customer ID Provided."
|
|
509 |
msgstr ""
|
510 |
|
511 |
#: includes/admin/customers/customers.php:115
|
512 |
-
#: includes/admin/payments/view-order-details.php:
|
513 |
msgid "Customer Details"
|
514 |
msgstr ""
|
515 |
|
516 |
-
#: includes/admin/customers/customers.php:
|
517 |
msgid "Edit Customer"
|
518 |
msgstr ""
|
519 |
|
520 |
-
#: includes/admin/customers/customers.php:
|
521 |
msgid "Customer Address"
|
522 |
msgstr ""
|
523 |
|
524 |
-
#: includes/admin/customers/customers.php:
|
525 |
msgid "Address 1"
|
526 |
msgstr ""
|
527 |
|
528 |
-
#: includes/admin/customers/customers.php:
|
529 |
msgid "Address 2"
|
530 |
msgstr ""
|
531 |
|
532 |
-
#: includes/admin/customers/customers.php:
|
533 |
#: includes/admin/reporting/class-export-payments.php:68
|
534 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
535 |
-
#: includes/
|
|
|
536 |
msgid "City"
|
537 |
msgstr ""
|
538 |
|
539 |
-
#: includes/admin/customers/customers.php:
|
540 |
-
#: includes/admin/settings/register-settings.php:
|
541 |
-
#: includes/
|
|
|
542 |
msgid "State / Province"
|
543 |
msgstr ""
|
544 |
|
545 |
-
#: includes/admin/customers/customers.php:
|
546 |
msgid "Postal"
|
547 |
msgstr ""
|
548 |
|
549 |
-
#: includes/admin/customers/customers.php:
|
550 |
msgid "Customer Name"
|
551 |
msgstr ""
|
552 |
|
553 |
-
#: includes/admin/customers/customers.php:
|
554 |
msgid "Customer Email"
|
555 |
msgstr ""
|
556 |
|
557 |
-
#: includes/admin/customers/customers.php:
|
558 |
msgid "Customer since"
|
559 |
msgstr ""
|
560 |
|
561 |
-
#: includes/admin/customers/customers.php:
|
562 |
msgid "User ID"
|
563 |
msgstr ""
|
564 |
|
565 |
-
#: includes/admin/customers/customers.php:
|
566 |
#: includes/admin/reporting/class-export-payments.php:187
|
567 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
568 |
msgid "none"
|
569 |
msgstr ""
|
570 |
|
571 |
-
#: includes/admin/customers/customers.php:
|
572 |
-
msgid "Disconnects the current user ID from this customer record"
|
573 |
-
msgstr ""
|
574 |
-
|
575 |
-
#: includes/admin/customers/customers.php:292
|
576 |
msgid "Disconnect User"
|
577 |
msgstr ""
|
578 |
|
579 |
-
#: includes/admin/customers/customers.php:
|
580 |
msgid "Update Customer"
|
581 |
msgstr ""
|
582 |
|
583 |
-
#: includes/admin/customers/customers.php:
|
584 |
-
#: includes/admin/customers/customers.php:
|
585 |
-
#: includes/admin/payments/view-order-details.php:
|
586 |
-
#: includes/admin/thickbox.php:
|
587 |
msgid "Cancel"
|
588 |
msgstr ""
|
589 |
|
590 |
-
#: includes/admin/customers/customers.php:
|
591 |
-
msgid "View All Purchases"
|
592 |
-
msgstr ""
|
593 |
-
|
594 |
-
#: includes/admin/customers/customers.php:318
|
595 |
msgid "%d Completed Sale"
|
596 |
msgid_plural "%d Completed Sales"
|
597 |
msgstr[0] ""
|
598 |
msgstr[1] ""
|
599 |
|
600 |
-
#: includes/admin/customers/customers.php:
|
601 |
msgid "Lifetime Value"
|
602 |
msgstr ""
|
603 |
|
604 |
-
#: includes/admin/customers/customers.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
605 |
msgid "Recent Payments"
|
606 |
msgstr ""
|
607 |
|
608 |
-
#: includes/admin/customers/customers.php:
|
609 |
#: includes/admin/downloads/metabox.php:346
|
610 |
-
#: includes/admin/downloads/metabox.php:
|
611 |
#: includes/admin/payments/class-payments-table.php:222
|
612 |
#: includes/admin/reporting/class-export-payments.php:61
|
613 |
#: includes/admin/reporting/class-export.php:69
|
614 |
#: includes/admin/reporting/export/class-batch-export-customers.php:42
|
615 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:42
|
616 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:40
|
617 |
#: templates/history-purchases.php:18
|
618 |
msgid "ID"
|
619 |
msgstr ""
|
620 |
|
621 |
-
#: includes/admin/customers/customers.php:
|
622 |
#: includes/admin/discounts/add-discount.php:56
|
623 |
#: includes/admin/discounts/class-discount-codes-table.php:147
|
624 |
#: includes/admin/discounts/edit-discount.php:70
|
625 |
#: includes/admin/payments/class-payments-table.php:225
|
626 |
#: includes/admin/reporting/class-export-payments.php:74
|
627 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
628 |
#: templates/history-purchases.php:20
|
629 |
msgid "Amount"
|
630 |
msgstr ""
|
631 |
|
632 |
-
#: includes/admin/customers/customers.php:
|
633 |
#: includes/admin/downloads/dashboard-columns.php:37
|
634 |
#: includes/admin/payments/class-payments-table.php:226
|
635 |
#: includes/admin/reporting/class-api-requests-logs-list-table.php:94
|
@@ -639,94 +741,82 @@ msgstr ""
|
|
639 |
#: includes/admin/reporting/class-export.php:70
|
640 |
#: includes/admin/reporting/class-file-downloads-logs-list-table.php:150
|
641 |
#: includes/admin/reporting/class-gateway-error-logs-list-table.php:134
|
642 |
-
#: includes/admin/reporting/class-sales-logs-list-table.php:
|
643 |
#: includes/admin/reporting/export/class-batch-export-file-downloads.php:42
|
644 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
645 |
-
#:
|
|
|
646 |
msgid "Date"
|
647 |
msgstr ""
|
648 |
|
649 |
-
#: includes/admin/customers/customers.php:
|
650 |
#: includes/admin/discounts/class-discount-codes-table.php:151
|
651 |
#: includes/admin/discounts/edit-discount.php:175
|
652 |
#: includes/admin/payments/class-payments-table.php:228
|
653 |
#: includes/admin/reporting/class-export-payments.php:82
|
654 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:49
|
655 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
|
|
656 |
msgid "Status"
|
657 |
msgstr ""
|
658 |
|
659 |
-
#: includes/admin/customers/customers.php:
|
660 |
-
#: includes/admin/customers/customers.php:381 templates/checkout_cart.php:13
|
661 |
-
msgid "Actions"
|
662 |
-
msgstr ""
|
663 |
-
|
664 |
-
#: includes/admin/customers/customers.php:360
|
665 |
-
msgid "View Details for Payment"
|
666 |
-
msgstr ""
|
667 |
-
|
668 |
-
#: includes/admin/customers/customers.php:361
|
669 |
msgid "View Details"
|
670 |
msgstr ""
|
671 |
|
672 |
-
#: includes/admin/customers/customers.php:
|
673 |
msgid "No Payments Found"
|
674 |
msgstr ""
|
675 |
|
676 |
-
#: includes/admin/customers/customers.php:
|
677 |
-
#: includes/admin/payments/view-order-details.php:
|
678 |
msgid "Purchased %s"
|
679 |
msgstr ""
|
680 |
|
681 |
-
#: includes/admin/customers/customers.php:
|
682 |
-
#: includes/admin/customers/customers.php:391 includes/admin/welcome.php:495
|
683 |
msgid "View %s"
|
684 |
msgstr ""
|
685 |
|
686 |
-
#: includes/admin/customers/customers.php:
|
687 |
msgid "No %s Found"
|
688 |
msgstr ""
|
689 |
|
690 |
-
#: includes/admin/customers/customers.php:
|
691 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:57
|
692 |
msgid "Notes"
|
693 |
msgstr ""
|
694 |
|
695 |
-
#: includes/admin/customers/customers.php:
|
696 |
msgid "No Customer Notes"
|
697 |
msgstr ""
|
698 |
|
699 |
-
#: includes/admin/customers/customers.php:
|
700 |
msgid "Are you sure you want to delete this customer?"
|
701 |
msgstr ""
|
702 |
|
703 |
-
#: includes/admin/customers/customers.php:
|
704 |
msgid "Delete all associated payments and records?"
|
705 |
msgstr ""
|
706 |
|
707 |
-
#: includes/admin/customers/customers.php:
|
708 |
msgid "Recount Customer Stats"
|
709 |
msgstr ""
|
710 |
|
711 |
-
#: includes/admin/customers/customers.php:
|
712 |
msgid ""
|
713 |
"Use this tool to recalculate the purchase count and total value of the "
|
714 |
"customer."
|
715 |
msgstr ""
|
716 |
|
717 |
-
#: includes/admin/customers/customers.php:
|
718 |
msgid "Recount Stats"
|
719 |
msgstr ""
|
720 |
|
721 |
-
#: includes/admin/customers/customers.php:
|
722 |
msgid "This customer's user account is pending verification."
|
723 |
msgstr ""
|
724 |
|
725 |
-
#: includes/admin/customers/customers.php:
|
726 |
-
msgid "Verify this customer's account"
|
727 |
-
msgstr ""
|
728 |
-
|
729 |
-
#: includes/admin/customers/customers.php:588
|
730 |
msgid "Verify account."
|
731 |
msgstr ""
|
732 |
|
@@ -745,8 +835,8 @@ msgstr ""
|
|
745 |
#: includes/admin/reporting/class-download-reports-table.php:112
|
746 |
#: includes/admin/reporting/class-export-earnings.php:64
|
747 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:59
|
748 |
-
#: includes/admin/reporting/graphing.php:
|
749 |
-
#: includes/admin/reporting/graphing.php:
|
750 |
#: includes/admin/reporting/pdf-reports.php:206
|
751 |
#: includes/admin/reporting/reports.php:54
|
752 |
msgid "Earnings"
|
@@ -760,12 +850,12 @@ msgstr[0] ""
|
|
760 |
msgstr[1] ""
|
761 |
|
762 |
#: includes/admin/dashboard-widgets.php:80
|
763 |
-
#: includes/admin/reporting/graphing.php:
|
764 |
msgid "Last Month"
|
765 |
msgstr ""
|
766 |
|
767 |
#: includes/admin/dashboard-widgets.php:105
|
768 |
-
#: includes/admin/reporting/graphing.php:
|
769 |
msgid "Today"
|
770 |
msgstr ""
|
771 |
|
@@ -774,8 +864,8 @@ msgstr ""
|
|
774 |
#: includes/admin/reporting/class-download-reports-table.php:111
|
775 |
#: includes/admin/reporting/class-export-earnings.php:63
|
776 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:58
|
777 |
-
#: includes/admin/reporting/graphing.php:
|
778 |
-
#: includes/admin/reporting/graphing.php:
|
779 |
#: includes/admin/reporting/logs.php:145
|
780 |
#: includes/admin/reporting/pdf-reports.php:223
|
781 |
msgid "Sales"
|
@@ -787,6 +877,7 @@ msgstr ""
|
|
787 |
|
788 |
#: includes/admin/dashboard-widgets.php:138
|
789 |
#: includes/admin/reporting/class-categories-reports-table.php:85
|
|
|
790 |
msgid "Total Earnings"
|
791 |
msgstr ""
|
792 |
|
@@ -804,11 +895,6 @@ msgstr ""
|
|
804 |
msgid "View All"
|
805 |
msgstr ""
|
806 |
|
807 |
-
#: includes/admin/dashboard-widgets.php:174
|
808 |
-
#: includes/admin/dashboard-widgets.php:186
|
809 |
-
msgid "Purchase Details for Payment #%s"
|
810 |
-
msgstr ""
|
811 |
-
|
812 |
#: includes/admin/discounts/add-discount.php:15 includes/post-types.php:106
|
813 |
msgid "Add New Discount"
|
814 |
msgstr ""
|
@@ -899,7 +985,9 @@ msgstr ""
|
|
899 |
|
900 |
#: includes/admin/discounts/add-discount.php:97
|
901 |
#: includes/admin/discounts/edit-discount.php:112
|
902 |
-
msgid "
|
|
|
|
|
903 |
msgstr ""
|
904 |
|
905 |
#: includes/admin/discounts/add-discount.php:103
|
@@ -978,7 +1066,7 @@ msgstr ""
|
|
978 |
#: includes/admin/discounts/class-discount-codes-table.php:127
|
979 |
#: includes/admin/payments/class-payments-table.php:200
|
980 |
#: includes/admin/reporting/class-file-downloads-logs-list-table.php:348
|
981 |
-
#: includes/admin/reporting/class-sales-logs-list-table.php:
|
982 |
msgid "All"
|
983 |
msgstr ""
|
984 |
|
@@ -1066,7 +1154,7 @@ msgstr ""
|
|
1066 |
|
1067 |
#: includes/admin/discounts/contextual-help.php:38
|
1068 |
#: includes/admin/settings/contextual-help.php:42
|
1069 |
-
#: includes/admin/settings/register-settings.php:
|
1070 |
#: includes/admin/tools.php:68
|
1071 |
msgid "General"
|
1072 |
msgstr ""
|
@@ -1401,6 +1489,10 @@ msgstr ""
|
|
1401 |
msgid "Set ID %s as default price"
|
1402 |
msgstr ""
|
1403 |
|
|
|
|
|
|
|
|
|
1404 |
#: includes/admin/downloads/metabox.php:474
|
1405 |
msgid "Product Type Options:"
|
1406 |
msgstr ""
|
@@ -1409,130 +1501,229 @@ msgstr ""
|
|
1409 |
msgid "Select a product type"
|
1410 |
msgstr ""
|
1411 |
|
1412 |
-
#: includes/admin/downloads/metabox.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
1413 |
msgid "Bundled %s:"
|
1414 |
msgstr ""
|
1415 |
|
1416 |
-
#: includes/admin/downloads/metabox.php:
|
1417 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1418 |
msgid "Add New File"
|
1419 |
msgstr ""
|
1420 |
|
1421 |
-
#: includes/admin/downloads/metabox.php:
|
1422 |
msgid "File Downloads:"
|
1423 |
msgstr ""
|
1424 |
|
1425 |
-
#: includes/admin/downloads/metabox.php:
|
1426 |
-
#: includes/admin/downloads/metabox.php:
|
1427 |
msgid "File Name"
|
1428 |
msgstr ""
|
1429 |
|
1430 |
-
#: includes/admin/downloads/metabox.php:
|
1431 |
msgid "File URL"
|
1432 |
msgstr ""
|
1433 |
|
1434 |
-
#: includes/admin/downloads/metabox.php:
|
1435 |
msgid "Price Assignment"
|
1436 |
msgstr ""
|
1437 |
|
1438 |
-
#: includes/admin/downloads/metabox.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1439 |
msgid "Upload or enter the file URL"
|
1440 |
msgstr ""
|
1441 |
|
1442 |
-
#: includes/admin/downloads/metabox.php:
|
1443 |
msgid "Insert File"
|
1444 |
msgstr ""
|
1445 |
|
1446 |
-
#: includes/admin/downloads/metabox.php:
|
1447 |
msgid "Insert"
|
1448 |
msgstr ""
|
1449 |
|
1450 |
-
#: includes/admin/downloads/metabox.php:
|
1451 |
msgid "Upload a File"
|
1452 |
msgstr ""
|
1453 |
|
1454 |
-
#: includes/admin/downloads/metabox.php:
|
|
|
|
|
|
|
|
|
1455 |
msgid "Insert into %s"
|
1456 |
msgstr ""
|
1457 |
|
1458 |
-
#: includes/admin/downloads/metabox.php:
|
1459 |
msgid "File Download Limit:"
|
1460 |
msgstr ""
|
1461 |
|
1462 |
-
#: includes/admin/downloads/metabox.php:
|
1463 |
msgid "Leave blank for global setting or 0 for unlimited"
|
1464 |
msgstr ""
|
1465 |
|
1466 |
-
#: includes/admin/downloads/metabox.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
1467 |
msgid "Ignore Tax:"
|
1468 |
msgstr ""
|
1469 |
|
1470 |
-
#: includes/admin/downloads/metabox.php:
|
1471 |
msgid "Mark this product as exclusive of tax"
|
1472 |
msgstr ""
|
1473 |
|
1474 |
-
#: includes/admin/downloads/metabox.php:
|
1475 |
-
#: includes/admin/settings/register-settings.php:
|
1476 |
-
#: includes/admin/thickbox.php:
|
1477 |
#: includes/scripts.php:60 includes/shortcodes.php:49
|
1478 |
#: includes/template-functions.php:67
|
1479 |
msgid "Purchase"
|
1480 |
msgstr ""
|
1481 |
|
1482 |
-
#: includes/admin/downloads/metabox.php:
|
1483 |
msgid "Purchase Shortcode:"
|
1484 |
msgstr ""
|
1485 |
|
1486 |
-
#: includes/admin/downloads/metabox.php:
|
1487 |
-
msgid "
|
|
|
|
|
1488 |
msgstr ""
|
1489 |
|
1490 |
#: includes/admin/downloads/metabox.php:876
|
|
|
|
|
|
|
|
|
1491 |
msgid "Enter an SKU for this %s."
|
1492 |
msgstr ""
|
1493 |
|
1494 |
-
#: includes/admin/downloads/metabox.php:
|
1495 |
msgid "Button Options:"
|
1496 |
msgstr ""
|
1497 |
|
1498 |
-
#: includes/admin/downloads/metabox.php:
|
1499 |
msgid "Disable the automatic output of the purchase button"
|
1500 |
msgstr ""
|
1501 |
|
1502 |
#: includes/admin/downloads/metabox.php:911
|
1503 |
-
|
1504 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1505 |
msgid "Add to Cart"
|
1506 |
msgstr ""
|
1507 |
|
1508 |
-
#: includes/admin/downloads/metabox.php:
|
1509 |
-
#: includes/admin/settings/register-settings.php:
|
1510 |
#: includes/template-functions.php:67
|
1511 |
msgid "Buy Now"
|
1512 |
msgstr ""
|
1513 |
|
1514 |
-
#: includes/admin/downloads/metabox.php:
|
1515 |
msgid "Purchase button behavior"
|
1516 |
msgstr ""
|
1517 |
|
1518 |
-
#: includes/admin/downloads/metabox.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1519 |
msgid ""
|
1520 |
"Special notes or instructions for this product. These notes will be added "
|
1521 |
"to the purchase receipt."
|
1522 |
msgstr ""
|
1523 |
|
1524 |
-
#: includes/admin/downloads/metabox.php:
|
1525 |
msgid "Sales:"
|
1526 |
msgstr ""
|
1527 |
|
1528 |
-
#: includes/admin/downloads/metabox.php:
|
1529 |
msgid "Earnings:"
|
1530 |
msgstr ""
|
1531 |
|
1532 |
-
#: includes/admin/downloads/metabox.php:
|
1533 |
msgid "View File Download Log"
|
1534 |
msgstr ""
|
1535 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1536 |
#: includes/admin/payments/actions.php:25
|
1537 |
#: includes/admin/payments/actions.php:291
|
1538 |
#: includes/admin/payments/actions.php:307
|
@@ -1575,27 +1766,27 @@ msgid "Completed"
|
|
1575 |
msgstr ""
|
1576 |
|
1577 |
#: includes/admin/payments/class-payments-table.php:202
|
1578 |
-
#: includes/payments/functions.php:
|
1579 |
msgid "Pending"
|
1580 |
msgstr ""
|
1581 |
|
1582 |
#: includes/admin/payments/class-payments-table.php:203
|
1583 |
-
#: includes/payments/functions.php:
|
1584 |
msgid "Refunded"
|
1585 |
msgstr ""
|
1586 |
|
1587 |
#: includes/admin/payments/class-payments-table.php:204
|
1588 |
-
#: includes/payments/functions.php:
|
1589 |
msgid "Revoked"
|
1590 |
msgstr ""
|
1591 |
|
1592 |
#: includes/admin/payments/class-payments-table.php:205
|
1593 |
-
#: includes/payments/functions.php:
|
1594 |
msgid "Failed"
|
1595 |
msgstr ""
|
1596 |
|
1597 |
#: includes/admin/payments/class-payments-table.php:206
|
1598 |
-
#: includes/payments/functions.php:
|
1599 |
msgid "Abandoned"
|
1600 |
msgstr ""
|
1601 |
|
@@ -1783,201 +1974,239 @@ msgstr ""
|
|
1783 |
msgid "Status:"
|
1784 |
msgstr ""
|
1785 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1786 |
#: includes/admin/payments/view-order-details.php:85
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1787 |
msgid "Date:"
|
1788 |
msgstr ""
|
1789 |
|
1790 |
-
#: includes/admin/payments/view-order-details.php:
|
1791 |
msgid "Time:"
|
1792 |
msgstr ""
|
1793 |
|
1794 |
-
#: includes/admin/payments/view-order-details.php:
|
1795 |
#: includes/admin/reporting/class-export-payments.php:76
|
1796 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
1797 |
msgid "Discount Code"
|
1798 |
msgstr ""
|
1799 |
|
1800 |
-
#: includes/admin/payments/view-order-details.php:
|
1801 |
-
#: includes/admin/settings/register-settings.php:
|
1802 |
msgid "None"
|
1803 |
msgstr ""
|
1804 |
|
1805 |
-
#: includes/admin/payments/view-order-details.php:
|
1806 |
#: templates/shortcode-receipt.php:66
|
1807 |
msgid "Fees"
|
1808 |
msgstr ""
|
1809 |
|
1810 |
-
#: includes/admin/payments/view-order-details.php:
|
1811 |
#: includes/admin/reporting/class-export-payments.php:75
|
1812 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
1813 |
-
#:
|
|
|
1814 |
msgid "Tax"
|
1815 |
msgstr ""
|
1816 |
|
1817 |
-
#: includes/admin/payments/view-order-details.php:
|
1818 |
#: templates/shortcode-receipt.php:105
|
1819 |
msgid "Total Price"
|
1820 |
msgstr ""
|
1821 |
|
1822 |
-
#: includes/admin/payments/view-order-details.php:
|
1823 |
msgid "Recalculate Totals"
|
1824 |
msgstr ""
|
1825 |
|
1826 |
-
#: includes/admin/payments/view-order-details.php:
|
1827 |
msgid "Recalculate"
|
1828 |
msgstr ""
|
1829 |
|
1830 |
-
#: includes/admin/payments/view-order-details.php:
|
1831 |
msgid "Delete Payment"
|
1832 |
msgstr ""
|
1833 |
|
1834 |
-
#: includes/admin/payments/view-order-details.php:
|
1835 |
msgid "Save Payment"
|
1836 |
msgstr ""
|
1837 |
|
1838 |
-
#: includes/admin/payments/view-order-details.php:
|
1839 |
msgid "Resend Receipt"
|
1840 |
msgstr ""
|
1841 |
|
1842 |
-
#: includes/admin/payments/view-order-details.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1843 |
msgid "Payment Meta"
|
1844 |
msgstr ""
|
1845 |
|
1846 |
-
#: includes/admin/payments/view-order-details.php:
|
1847 |
msgid "Gateway:"
|
1848 |
msgstr ""
|
1849 |
|
1850 |
-
#: includes/admin/payments/view-order-details.php:
|
1851 |
msgid "Key:"
|
1852 |
msgstr ""
|
1853 |
|
1854 |
-
#: includes/admin/payments/view-order-details.php:
|
1855 |
msgid "IP:"
|
1856 |
msgstr ""
|
1857 |
|
1858 |
-
#: includes/admin/payments/view-order-details.php:
|
1859 |
msgid "Transaction ID:"
|
1860 |
msgstr ""
|
1861 |
|
1862 |
-
#: includes/admin/payments/view-order-details.php:
|
1863 |
-
msgid ""
|
1864 |
-
"Grants the customer unlimited file downloads for this purchase, regardless "
|
1865 |
-
"of other limits set."
|
1866 |
msgstr ""
|
1867 |
|
1868 |
-
#: includes/admin/payments/view-order-details.php:
|
1869 |
-
msgid "
|
|
|
|
|
|
|
1870 |
msgstr ""
|
1871 |
|
1872 |
-
#: includes/admin/payments/view-order-details.php:
|
1873 |
#: includes/admin/reporting/reports.php:33 includes/class-edd-logging.php:48
|
1874 |
msgid "Logs"
|
1875 |
msgstr ""
|
1876 |
|
1877 |
-
#: includes/admin/payments/view-order-details.php:
|
1878 |
msgid "View file download log for purchase"
|
1879 |
msgstr ""
|
1880 |
|
1881 |
-
#: includes/admin/payments/view-order-details.php:
|
1882 |
msgid "View customer download log"
|
1883 |
msgstr ""
|
1884 |
|
1885 |
-
#: includes/admin/payments/view-order-details.php:
|
1886 |
msgid "View all purchases of customer"
|
1887 |
msgstr ""
|
1888 |
|
1889 |
-
#: includes/admin/payments/view-order-details.php:
|
1890 |
#: templates/widget-cart-checkout.php:5 templates/widget-cart-empty.php:6
|
1891 |
msgid "Total:"
|
1892 |
msgstr ""
|
1893 |
|
1894 |
-
#: includes/admin/payments/view-order-details.php:
|
1895 |
-
#: includes/admin/payments/view-order-details.php:578
|
1896 |
msgid "Copy Download Link(s)"
|
1897 |
msgstr ""
|
1898 |
|
1899 |
-
#: includes/admin/payments/view-order-details.php:
|
1900 |
-
#: includes/admin/settings/register-settings.php:1746 includes/scripts.php:212
|
1901 |
-
#: templates/checkout_cart.php:49 templates/checkout_cart.php:67
|
1902 |
-
msgid "Remove"
|
1903 |
-
msgstr ""
|
1904 |
-
|
1905 |
-
#: includes/admin/payments/view-order-details.php:365
|
1906 |
#: includes/emails/class-edd-email-tags.php:407
|
1907 |
#: includes/emails/class-edd-email-tags.php:518
|
1908 |
#: templates/shortcode-receipt.php:128
|
1909 |
msgid "Quantity"
|
1910 |
msgstr ""
|
1911 |
|
1912 |
-
#: includes/admin/payments/view-order-details.php:
|
1913 |
msgid "Item Price: "
|
1914 |
msgstr ""
|
1915 |
|
1916 |
-
#: includes/admin/payments/view-order-details.php:
|
1917 |
msgid "Add %s to Payment"
|
1918 |
msgstr ""
|
1919 |
|
1920 |
-
#: includes/admin/payments/view-order-details.php:
|
1921 |
msgid "No %s included with this purchase"
|
1922 |
msgstr ""
|
1923 |
|
1924 |
-
#: includes/admin/payments/view-order-details.php:
|
1925 |
msgid "View Customer Details"
|
1926 |
msgstr ""
|
1927 |
|
1928 |
-
#: includes/admin/payments/view-order-details.php:
|
1929 |
msgid "New Customer"
|
1930 |
msgstr ""
|
1931 |
|
1932 |
-
#: includes/admin/payments/view-order-details.php:
|
1933 |
msgid "Name:"
|
1934 |
msgstr ""
|
1935 |
|
1936 |
-
#: includes/admin/payments/view-order-details.php:
|
1937 |
msgid "Email:"
|
1938 |
msgstr ""
|
1939 |
|
1940 |
-
#: includes/admin/payments/view-order-details.php:
|
1941 |
msgid "Click \"Save Payment\" to create new customer"
|
1942 |
msgstr ""
|
1943 |
|
1944 |
-
#: includes/admin/payments/view-order-details.php:
|
1945 |
#: includes/checkout/template.php:329
|
1946 |
msgid "Billing Address"
|
1947 |
msgstr ""
|
1948 |
|
1949 |
-
#: includes/admin/payments/view-order-details.php:
|
1950 |
msgid "Street Address Line 1:"
|
1951 |
msgstr ""
|
1952 |
|
1953 |
-
#: includes/admin/payments/view-order-details.php:
|
1954 |
msgid "Street Address Line 2:"
|
1955 |
msgstr ""
|
1956 |
|
1957 |
-
#: includes/admin/payments/view-order-details.php:
|
1958 |
-
#: includes/admin/settings/register-settings.php:
|
1959 |
msgid "Select a country"
|
1960 |
msgstr ""
|
1961 |
|
1962 |
-
#: includes/admin/payments/view-order-details.php:
|
1963 |
-
#: includes/admin/settings/register-settings.php:
|
1964 |
msgid "Select a state"
|
1965 |
msgstr ""
|
1966 |
|
1967 |
-
#: includes/admin/payments/view-order-details.php:
|
1968 |
msgid "Payment Notes"
|
1969 |
msgstr ""
|
1970 |
|
1971 |
-
#: includes/admin/payments/view-order-details.php:
|
1972 |
msgid "No payment notes"
|
1973 |
msgstr ""
|
1974 |
|
1975 |
-
#: includes/admin/payments/view-order-details.php:
|
1976 |
msgid "Add Note"
|
1977 |
msgstr ""
|
1978 |
|
1979 |
#: includes/admin/plugins.php:27
|
1980 |
-
#: includes/admin/settings/register-settings.php:
|
1981 |
msgid "General Settings"
|
1982 |
msgstr ""
|
1983 |
|
@@ -1988,7 +2217,7 @@ msgstr ""
|
|
1988 |
#: includes/admin/reporting/class-api-requests-logs-list-table.php:89
|
1989 |
#: includes/admin/reporting/class-file-downloads-logs-list-table.php:144
|
1990 |
#: includes/admin/reporting/class-gateway-error-logs-list-table.php:129
|
1991 |
-
#: includes/admin/reporting/class-sales-logs-list-table.php:
|
1992 |
msgid "Log ID"
|
1993 |
msgstr ""
|
1994 |
|
@@ -2008,10 +2237,6 @@ msgstr ""
|
|
2008 |
msgid "Request Speed"
|
2009 |
msgstr ""
|
2010 |
|
2011 |
-
#: includes/admin/reporting/class-api-requests-logs-list-table.php:137
|
2012 |
-
msgid "View Request Details"
|
2013 |
-
msgstr ""
|
2014 |
-
|
2015 |
#: includes/admin/reporting/class-api-requests-logs-list-table.php:137
|
2016 |
msgid "View Request"
|
2017 |
msgstr ""
|
@@ -2070,15 +2295,17 @@ msgstr ""
|
|
2070 |
|
2071 |
#: includes/admin/reporting/class-export-customers.php:66
|
2072 |
#: includes/admin/reporting/class-export-payments.php:64
|
2073 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
2074 |
-
#: includes/
|
|
|
2075 |
msgid "First Name"
|
2076 |
msgstr ""
|
2077 |
|
2078 |
#: includes/admin/reporting/class-export-customers.php:67
|
2079 |
#: includes/admin/reporting/class-export-payments.php:65
|
2080 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
2081 |
-
#: includes/
|
|
|
2082 |
msgid "Last Name"
|
2083 |
msgstr ""
|
2084 |
|
@@ -2102,6 +2329,8 @@ msgstr ""
|
|
2102 |
#: includes/admin/reporting/class-export-download-history.php:66
|
2103 |
#: includes/admin/reporting/class-file-downloads-logs-list-table.php:149
|
2104 |
#: includes/admin/reporting/export/class-batch-export-file-downloads.php:44
|
|
|
|
|
2105 |
msgid "IP Address"
|
2106 |
msgstr ""
|
2107 |
|
@@ -2118,73 +2347,77 @@ msgstr ""
|
|
2118 |
|
2119 |
#: includes/admin/reporting/class-export-payments.php:62
|
2120 |
#: includes/admin/reporting/export/class-batch-export-payments.php:41
|
|
|
2121 |
msgid "Payment Number"
|
2122 |
msgstr ""
|
2123 |
|
2124 |
#: includes/admin/reporting/class-export-payments.php:66
|
2125 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
2126 |
msgid "Address"
|
2127 |
msgstr ""
|
2128 |
|
2129 |
#: includes/admin/reporting/class-export-payments.php:67
|
2130 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
2131 |
msgid "Address (Line 2)"
|
2132 |
msgstr ""
|
2133 |
|
2134 |
#: includes/admin/reporting/class-export-payments.php:69
|
2135 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
2136 |
msgid "State"
|
2137 |
msgstr ""
|
2138 |
|
2139 |
#: includes/admin/reporting/class-export-payments.php:70
|
2140 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
2141 |
-
#: includes/admin/settings/register-settings.php:
|
2142 |
-
#: templates/shortcode-profile-editor.php:
|
2143 |
msgid "Country"
|
2144 |
msgstr ""
|
2145 |
|
2146 |
#: includes/admin/reporting/class-export-payments.php:71
|
2147 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
2148 |
-
#: includes/
|
|
|
2149 |
msgid "Zip / Postal Code"
|
2150 |
msgstr ""
|
2151 |
|
2152 |
#: includes/admin/reporting/class-export-payments.php:72
|
2153 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:51
|
2154 |
#: templates/shortcode-receipt.php:119
|
2155 |
msgid "Products"
|
2156 |
msgstr ""
|
2157 |
|
2158 |
#: includes/admin/reporting/class-export-payments.php:73
|
2159 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
2160 |
msgid "SKUs"
|
2161 |
msgstr ""
|
2162 |
|
2163 |
#: includes/admin/reporting/class-export-payments.php:77
|
2164 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
2165 |
-
#: templates/shortcode-receipt.php:53
|
2166 |
msgid "Payment Method"
|
2167 |
msgstr ""
|
2168 |
|
2169 |
#: includes/admin/reporting/class-export-payments.php:78
|
2170 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
|
|
2171 |
msgid "Transaction ID"
|
2172 |
msgstr ""
|
2173 |
|
2174 |
#: includes/admin/reporting/class-export-payments.php:79
|
2175 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
|
|
2176 |
msgid "Purchase Key"
|
2177 |
msgstr ""
|
2178 |
|
2179 |
#: includes/admin/reporting/class-export-payments.php:81
|
2180 |
#: includes/admin/reporting/class-file-downloads-logs-list-table.php:146
|
2181 |
-
#: includes/admin/reporting/class-sales-logs-list-table.php:
|
2182 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
|
|
2183 |
msgid "User"
|
2184 |
msgstr ""
|
2185 |
|
2186 |
#: includes/admin/reporting/class-export-payments.php:192
|
2187 |
-
#: includes/admin/reporting/export/class-batch-export-payments.php:
|
2188 |
msgid "guest"
|
2189 |
msgstr ""
|
2190 |
|
@@ -2200,12 +2433,13 @@ msgstr ""
|
|
2200 |
|
2201 |
#: includes/admin/reporting/class-file-downloads-logs-list-table.php:147
|
2202 |
#: includes/admin/reporting/class-gateway-error-logs-list-table.php:130
|
2203 |
-
#: includes/admin/reporting/class-sales-logs-list-table.php:
|
|
|
2204 |
msgid "Payment ID"
|
2205 |
msgstr ""
|
2206 |
|
2207 |
#: includes/admin/reporting/class-gateway-error-logs-list-table.php:79
|
2208 |
-
#: includes/gateways/manual.php:73 includes/gateways/paypal-standard.php:
|
2209 |
msgid "Payment Error"
|
2210 |
msgstr ""
|
2211 |
|
@@ -2234,7 +2468,7 @@ msgstr ""
|
|
2234 |
msgid "Pending / Failed Sales"
|
2235 |
msgstr ""
|
2236 |
|
2237 |
-
#: includes/admin/reporting/class-sales-logs-list-table.php:
|
2238 |
msgid "Item Amount"
|
2239 |
msgstr ""
|
2240 |
|
@@ -2245,7 +2479,7 @@ msgid ""
|
|
2245 |
msgstr ""
|
2246 |
|
2247 |
#: includes/admin/reporting/contextual-help.php:48
|
2248 |
-
#: includes/admin/reporting/reports.php:31 includes/admin/tools.php:
|
2249 |
msgid "Export"
|
2250 |
msgstr ""
|
2251 |
|
@@ -2341,7 +2575,8 @@ msgid "Files"
|
|
2341 |
msgstr ""
|
2342 |
|
2343 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:54
|
2344 |
-
#: includes/admin/settings/register-settings.php:
|
|
|
2345 |
msgid "File Download Limit"
|
2346 |
msgstr ""
|
2347 |
|
@@ -2356,6 +2591,25 @@ msgstr ""
|
|
2356 |
msgid "SKU"
|
2357 |
msgstr ""
|
2358 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2359 |
#: includes/admin/reporting/export/export-functions.php:49
|
2360 |
msgid "Export location or file not writable"
|
2361 |
msgstr ""
|
@@ -2368,98 +2622,98 @@ msgstr ""
|
|
2368 |
msgid "Batch Processing Complete"
|
2369 |
msgstr ""
|
2370 |
|
2371 |
-
#: includes/admin/reporting/graphing.php:
|
2372 |
msgid "Earnings Over Time"
|
2373 |
msgstr ""
|
2374 |
|
2375 |
-
#: includes/admin/reporting/graphing.php:
|
2376 |
-
#: includes/admin/reporting/graphing.php:
|
2377 |
msgid "Total earnings for period shown: "
|
2378 |
msgstr ""
|
2379 |
|
2380 |
-
#: includes/admin/reporting/graphing.php:
|
2381 |
-
#: includes/admin/reporting/graphing.php:
|
2382 |
msgid "Total sales for period shown: "
|
2383 |
msgstr ""
|
2384 |
|
2385 |
-
#: includes/admin/reporting/graphing.php:
|
2386 |
msgid "Estimated monthly earnings: "
|
2387 |
msgstr ""
|
2388 |
|
2389 |
-
#: includes/admin/reporting/graphing.php:
|
2390 |
msgid "Estimated monthly sales: "
|
2391 |
msgstr ""
|
2392 |
|
2393 |
-
#: includes/admin/reporting/graphing.php:
|
2394 |
msgid "Excludes sales tax."
|
2395 |
msgstr ""
|
2396 |
|
2397 |
-
#: includes/admin/reporting/graphing.php:
|
2398 |
msgid "Earnings Over Time for %s"
|
2399 |
msgstr ""
|
2400 |
|
2401 |
-
#: includes/admin/reporting/graphing.php:
|
2402 |
msgid "Average monthly earnings: %s"
|
2403 |
msgstr ""
|
2404 |
|
2405 |
-
#: includes/admin/reporting/graphing.php:
|
2406 |
msgid "Average monthly sales: %s"
|
2407 |
msgstr ""
|
2408 |
|
2409 |
-
#: includes/admin/reporting/graphing.php:
|
2410 |
msgid "Yesterday"
|
2411 |
msgstr ""
|
2412 |
|
2413 |
-
#: includes/admin/reporting/graphing.php:
|
2414 |
msgid "This Week"
|
2415 |
msgstr ""
|
2416 |
|
2417 |
-
#: includes/admin/reporting/graphing.php:
|
2418 |
msgid "Last Week"
|
2419 |
msgstr ""
|
2420 |
|
2421 |
-
#: includes/admin/reporting/graphing.php:
|
2422 |
msgid "This Month"
|
2423 |
msgstr ""
|
2424 |
|
2425 |
-
#: includes/admin/reporting/graphing.php:
|
2426 |
msgid "This Quarter"
|
2427 |
msgstr ""
|
2428 |
|
2429 |
-
#: includes/admin/reporting/graphing.php:
|
2430 |
msgid "Last Quarter"
|
2431 |
msgstr ""
|
2432 |
|
2433 |
-
#: includes/admin/reporting/graphing.php:
|
2434 |
msgid "This Year"
|
2435 |
msgstr ""
|
2436 |
|
2437 |
-
#: includes/admin/reporting/graphing.php:
|
2438 |
msgid "Last Year"
|
2439 |
msgstr ""
|
2440 |
|
2441 |
-
#: includes/admin/reporting/graphing.php:
|
2442 |
msgid "Custom"
|
2443 |
msgstr ""
|
2444 |
|
2445 |
-
#: includes/admin/reporting/graphing.php:
|
2446 |
msgid "From"
|
2447 |
msgstr ""
|
2448 |
|
2449 |
-
#: includes/admin/reporting/graphing.php:
|
2450 |
msgid "To"
|
2451 |
msgstr ""
|
2452 |
|
2453 |
-
#: includes/admin/reporting/graphing.php:
|
2454 |
msgid "Exclude Taxes"
|
2455 |
msgstr ""
|
2456 |
|
2457 |
-
#: includes/admin/reporting/graphing.php:
|
2458 |
msgid "Filter"
|
2459 |
msgstr ""
|
2460 |
|
2461 |
#: includes/admin/reporting/logs.php:144
|
2462 |
-
#: includes/admin/settings/register-settings.php:
|
2463 |
msgid "File Downloads"
|
2464 |
msgstr ""
|
2465 |
|
@@ -2578,7 +2832,7 @@ msgstr ""
|
|
2578 |
|
2579 |
#: includes/admin/reporting/reports.php:58
|
2580 |
#: includes/admin/settings/contextual-help.php:71
|
2581 |
-
#: includes/admin/settings/register-settings.php:
|
2582 |
msgid "Taxes"
|
2583 |
msgstr ""
|
2584 |
|
@@ -2653,10 +2907,10 @@ msgid "Download a CSV of earnings and sales over time."
|
|
2653 |
msgstr ""
|
2654 |
|
2655 |
#: includes/admin/reporting/reports.php:372
|
2656 |
-
#: includes/admin/reporting/reports.php:
|
2657 |
-
#: includes/admin/reporting/reports.php:
|
2658 |
-
#: includes/admin/reporting/reports.php:
|
2659 |
-
#: includes/admin/reporting/reports.php:
|
2660 |
msgid "Generate CSV"
|
2661 |
msgstr ""
|
2662 |
|
@@ -2668,41 +2922,41 @@ msgstr ""
|
|
2668 |
msgid "Download a CSV of all payments recorded."
|
2669 |
msgstr ""
|
2670 |
|
2671 |
-
#: includes/admin/reporting/reports.php:
|
2672 |
-
#: includes/admin/reporting/reports.php:
|
2673 |
msgid "Choose start date"
|
2674 |
msgstr ""
|
2675 |
|
2676 |
-
#: includes/admin/reporting/reports.php:
|
2677 |
-
#: includes/admin/reporting/reports.php:
|
2678 |
msgid "Choose end date"
|
2679 |
msgstr ""
|
2680 |
|
2681 |
-
#: includes/admin/reporting/reports.php:
|
2682 |
msgid "All Statuses"
|
2683 |
msgstr ""
|
2684 |
|
2685 |
-
#: includes/admin/reporting/reports.php:
|
2686 |
msgid "Export Customers in CSV"
|
2687 |
msgstr ""
|
2688 |
|
2689 |
-
#: includes/admin/reporting/reports.php:
|
2690 |
msgid "Download a CSV of customers."
|
2691 |
msgstr ""
|
2692 |
|
2693 |
-
#: includes/admin/reporting/reports.php:
|
2694 |
msgid "Export Download Products in CSV"
|
2695 |
msgstr ""
|
2696 |
|
2697 |
-
#: includes/admin/reporting/reports.php:
|
2698 |
msgid "Download a CSV of download products."
|
2699 |
msgstr ""
|
2700 |
|
2701 |
-
#: includes/admin/reporting/reports.php:
|
2702 |
msgid "Export Download History in CSV"
|
2703 |
msgstr ""
|
2704 |
|
2705 |
-
#: includes/admin/reporting/reports.php:
|
2706 |
msgid "Download a CSV of file downloads."
|
2707 |
msgstr ""
|
2708 |
|
@@ -2714,8 +2968,8 @@ msgid ""
|
|
2714 |
msgstr ""
|
2715 |
|
2716 |
#: includes/admin/settings/contextual-help.php:48
|
2717 |
-
#: includes/admin/settings/register-settings.php:
|
2718 |
-
#: includes/admin/settings/register-settings.php:
|
2719 |
msgid "Payment Gateways"
|
2720 |
msgstr ""
|
2721 |
|
@@ -2744,7 +2998,7 @@ msgid ""
|
|
2744 |
msgstr ""
|
2745 |
|
2746 |
#: includes/admin/settings/contextual-help.php:57
|
2747 |
-
#: includes/admin/settings/register-settings.php:
|
2748 |
msgid "Emails"
|
2749 |
msgstr ""
|
2750 |
|
@@ -2764,7 +3018,7 @@ msgid ""
|
|
2764 |
msgstr ""
|
2765 |
|
2766 |
#: includes/admin/settings/contextual-help.php:65
|
2767 |
-
#: includes/admin/settings/register-settings.php:
|
2768 |
msgid "Styles"
|
2769 |
msgstr ""
|
2770 |
|
@@ -2860,86 +3114,107 @@ msgstr ""
|
|
2860 |
msgid "A description of all the options are provided beside their input boxes."
|
2861 |
msgstr ""
|
2862 |
|
2863 |
-
#: includes/admin/settings/register-settings.php:
|
|
|
2864 |
msgid "Page Settings"
|
2865 |
msgstr ""
|
2866 |
|
2867 |
-
#: includes/admin/settings/register-settings.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2868 |
msgid "Checkout Page"
|
2869 |
msgstr ""
|
2870 |
|
2871 |
-
#: includes/admin/settings/register-settings.php:
|
2872 |
msgid ""
|
2873 |
"This is the checkout page where buyers will complete their purchases. The "
|
2874 |
"[download_checkout] short code must be on this page."
|
2875 |
msgstr ""
|
2876 |
|
2877 |
-
#: includes/admin/settings/register-settings.php:
|
2878 |
-
#: includes/admin/settings/register-settings.php:
|
2879 |
-
#: includes/admin/settings/register-settings.php:
|
2880 |
-
#: includes/admin/settings/register-settings.php:
|
2881 |
msgid "Select a page"
|
2882 |
msgstr ""
|
2883 |
|
2884 |
-
#: includes/admin/settings/register-settings.php:
|
2885 |
msgid "Success Page"
|
2886 |
msgstr ""
|
2887 |
|
2888 |
-
#: includes/admin/settings/register-settings.php:
|
2889 |
msgid ""
|
2890 |
"This is the page buyers are sent to after completing their purchases. The "
|
2891 |
"[edd_receipt] short code should be on this page."
|
2892 |
msgstr ""
|
2893 |
|
2894 |
-
#: includes/admin/settings/register-settings.php:
|
2895 |
msgid "Failed Transaction Page"
|
2896 |
msgstr ""
|
2897 |
|
2898 |
-
#: includes/admin/settings/register-settings.php:
|
2899 |
msgid ""
|
2900 |
"This is the page buyers are sent to if their transaction is cancelled or "
|
2901 |
-
"fails"
|
2902 |
msgstr ""
|
2903 |
|
2904 |
-
#: includes/admin/settings/register-settings.php:
|
2905 |
msgid "Purchase History Page"
|
2906 |
msgstr ""
|
2907 |
|
2908 |
-
#: includes/admin/settings/register-settings.php:
|
2909 |
msgid ""
|
2910 |
"This page shows a complete purchase history for the current user, including "
|
2911 |
-
"download links"
|
2912 |
msgstr ""
|
2913 |
|
2914 |
-
#: includes/admin/settings/register-settings.php:
|
2915 |
msgid "Store Location"
|
2916 |
msgstr ""
|
2917 |
|
2918 |
-
#: includes/admin/settings/register-settings.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2919 |
msgid "Base Country"
|
2920 |
msgstr ""
|
2921 |
|
2922 |
-
#: includes/admin/settings/register-settings.php:
|
2923 |
msgid "Where does your store operate from?"
|
2924 |
msgstr ""
|
2925 |
|
2926 |
-
#: includes/admin/settings/register-settings.php:
|
2927 |
msgid "Base State / Province"
|
2928 |
msgstr ""
|
2929 |
|
2930 |
-
#: includes/admin/settings/register-settings.php:
|
2931 |
msgid "What state / province does your store operate from?"
|
2932 |
msgstr ""
|
2933 |
|
2934 |
-
#: includes/admin/settings/register-settings.php:
|
2935 |
msgid "Tracking Settings"
|
2936 |
msgstr ""
|
2937 |
|
2938 |
-
#: includes/admin/settings/register-settings.php:
|
2939 |
msgid "Allow Usage Tracking?"
|
2940 |
msgstr ""
|
2941 |
|
2942 |
-
#: includes/admin/settings/register-settings.php:
|
2943 |
msgid ""
|
2944 |
"Allow Easy Digital Downloads to anonymously track how this plugin is used "
|
2945 |
"and help us make the plugin better. Opt-in to tracking and our newsletter "
|
@@ -2948,799 +3223,906 @@ msgid ""
|
|
2948 |
"sensitive data is tracked."
|
2949 |
msgstr ""
|
2950 |
|
2951 |
-
#: includes/admin/settings/register-settings.php:
|
2952 |
-
#: includes/admin/settings/register-settings.php:
|
2953 |
msgid "Currency Settings"
|
2954 |
msgstr ""
|
2955 |
|
2956 |
-
#: includes/admin/settings/register-settings.php:
|
2957 |
-
msgid "Currency"
|
2958 |
-
msgstr ""
|
2959 |
-
|
2960 |
-
#: includes/admin/settings/register-settings.php:325
|
2961 |
msgid ""
|
2962 |
"Choose your currency. Note that some payment gateways have currency "
|
2963 |
"restrictions."
|
2964 |
msgstr ""
|
2965 |
|
2966 |
-
#: includes/admin/settings/register-settings.php:
|
2967 |
msgid "Currency Position"
|
2968 |
msgstr ""
|
2969 |
|
2970 |
-
#: includes/admin/settings/register-settings.php:
|
2971 |
msgid "Choose the location of the currency sign."
|
2972 |
msgstr ""
|
2973 |
|
2974 |
-
#: includes/admin/settings/register-settings.php:
|
2975 |
msgid "Before - $10"
|
2976 |
msgstr ""
|
2977 |
|
2978 |
-
#: includes/admin/settings/register-settings.php:
|
2979 |
msgid "After - 10$"
|
2980 |
msgstr ""
|
2981 |
|
2982 |
-
#: includes/admin/settings/register-settings.php:
|
2983 |
msgid "Thousands Separator"
|
2984 |
msgstr ""
|
2985 |
|
2986 |
-
#: includes/admin/settings/register-settings.php:
|
2987 |
msgid "The symbol (usually , or .) to separate thousands"
|
2988 |
msgstr ""
|
2989 |
|
2990 |
-
#: includes/admin/settings/register-settings.php:
|
2991 |
msgid "Decimal Separator"
|
2992 |
msgstr ""
|
2993 |
|
2994 |
-
#: includes/admin/settings/register-settings.php:
|
2995 |
msgid "The symbol (usually , or .) to separate decimal points"
|
2996 |
msgstr ""
|
2997 |
|
2998 |
-
#: includes/admin/settings/register-settings.php:
|
2999 |
-
#: includes/admin/settings/register-settings.php:
|
|
|
3000 |
msgid "API Settings"
|
3001 |
msgstr ""
|
3002 |
|
3003 |
-
#: includes/admin/settings/register-settings.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3004 |
msgid "Allow User Keys"
|
3005 |
msgstr ""
|
3006 |
|
3007 |
-
#: includes/admin/settings/register-settings.php:
|
3008 |
msgid ""
|
3009 |
"Check this box to allow all users to generate API keys. Users with the "
|
3010 |
"'manage_shop_settings' capability are always allowed to generate keys."
|
3011 |
msgstr ""
|
3012 |
|
3013 |
-
#: includes/admin/settings/register-settings.php:
|
3014 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
3015 |
msgid "Gateway Settings"
|
3016 |
msgstr ""
|
3017 |
|
3018 |
-
#: includes/admin/settings/register-settings.php:
|
3019 |
msgid "Test Mode"
|
3020 |
msgstr ""
|
3021 |
|
3022 |
-
#: includes/admin/settings/register-settings.php:
|
3023 |
msgid ""
|
3024 |
"While in test mode no live transactions are processed. To fully use test "
|
3025 |
"mode, you must have a sandbox (test) account for the payment gateway you "
|
3026 |
"are testing."
|
3027 |
msgstr ""
|
3028 |
|
3029 |
-
#: includes/admin/settings/register-settings.php:
|
3030 |
msgid "Choose the payment gateways you want to enable."
|
3031 |
msgstr ""
|
3032 |
|
3033 |
-
#: includes/admin/settings/register-settings.php:
|
3034 |
msgid "Default Gateway"
|
3035 |
msgstr ""
|
3036 |
|
3037 |
-
#: includes/admin/settings/register-settings.php:
|
3038 |
msgid "This gateway will be loaded automatically with the checkout page."
|
3039 |
msgstr ""
|
3040 |
|
3041 |
-
#: includes/admin/settings/register-settings.php:
|
3042 |
msgid "Accepted Payment Method Icons"
|
3043 |
msgstr ""
|
3044 |
|
3045 |
-
#: includes/admin/settings/register-settings.php:
|
3046 |
msgid "Display icons for the selected payment methods"
|
3047 |
msgstr ""
|
3048 |
|
3049 |
-
#: includes/admin/settings/register-settings.php:
|
3050 |
msgid ""
|
3051 |
"You will also need to configure your gateway settings if you are accepting "
|
3052 |
"credit cards"
|
3053 |
msgstr ""
|
3054 |
|
3055 |
-
#: includes/admin/settings/register-settings.php:
|
3056 |
-
|
3057 |
-
msgstr ""
|
3058 |
-
|
3059 |
-
#: includes/admin/settings/register-settings.php:426
|
3060 |
-
msgid "PayPal Email"
|
3061 |
-
msgstr ""
|
3062 |
-
|
3063 |
-
#: includes/admin/settings/register-settings.php:427
|
3064 |
-
msgid "Enter your PayPal account's email"
|
3065 |
-
msgstr ""
|
3066 |
-
|
3067 |
-
#: includes/admin/settings/register-settings.php:433
|
3068 |
-
msgid "PayPal Page Style"
|
3069 |
-
msgstr ""
|
3070 |
-
|
3071 |
-
#: includes/admin/settings/register-settings.php:434
|
3072 |
-
msgid "Enter the name of the page style to use, or leave blank for default"
|
3073 |
-
msgstr ""
|
3074 |
-
|
3075 |
-
#: includes/admin/settings/register-settings.php:440
|
3076 |
-
msgid "Disable PayPal IPN Verification"
|
3077 |
-
msgstr ""
|
3078 |
-
|
3079 |
-
#: includes/admin/settings/register-settings.php:441
|
3080 |
-
msgid ""
|
3081 |
-
"If payments are not getting marked as complete, then check this box. This "
|
3082 |
-
"forces the site to use a slightly less secure method of verifying purchases."
|
3083 |
-
msgstr ""
|
3084 |
-
|
3085 |
-
#: includes/admin/settings/register-settings.php:453
|
3086 |
-
#: includes/admin/settings/register-settings.php:1121
|
3087 |
msgid "Email Settings"
|
3088 |
msgstr ""
|
3089 |
|
3090 |
-
#: includes/admin/settings/register-settings.php:
|
3091 |
msgid "Email Template"
|
3092 |
msgstr ""
|
3093 |
|
3094 |
-
#: includes/admin/settings/register-settings.php:
|
3095 |
msgid ""
|
3096 |
"Choose a template. Click \"Save Changes\" then \"Preview Purchase Receipt\" "
|
3097 |
"to see the new template."
|
3098 |
msgstr ""
|
3099 |
|
3100 |
-
#: includes/admin/settings/register-settings.php:
|
3101 |
msgid "Logo"
|
3102 |
msgstr ""
|
3103 |
|
3104 |
-
#: includes/admin/settings/register-settings.php:
|
3105 |
msgid ""
|
3106 |
"Upload or choose a logo to be displayed at the top of the purchase receipt "
|
3107 |
"emails. Displayed on HTML emails only."
|
3108 |
msgstr ""
|
3109 |
|
3110 |
-
#: includes/admin/settings/register-settings.php:
|
3111 |
-
#: includes/admin/settings/register-settings.php:
|
3112 |
msgid "Purchase Receipts"
|
3113 |
msgstr ""
|
3114 |
|
3115 |
-
#: includes/admin/settings/register-settings.php:
|
3116 |
msgid "From Name"
|
3117 |
msgstr ""
|
3118 |
|
3119 |
-
#: includes/admin/settings/register-settings.php:
|
3120 |
msgid ""
|
3121 |
"The name purchase receipts are said to come from. This should probably be "
|
3122 |
"your site or shop name."
|
3123 |
msgstr ""
|
3124 |
|
3125 |
-
#: includes/admin/settings/register-settings.php:
|
3126 |
msgid "From Email"
|
3127 |
msgstr ""
|
3128 |
|
3129 |
-
#: includes/admin/settings/register-settings.php:
|
3130 |
msgid ""
|
3131 |
"Email to send purchase receipts from. This will act as the \"from\" and "
|
3132 |
"\"reply-to\" address."
|
3133 |
msgstr ""
|
3134 |
|
3135 |
-
#: includes/admin/settings/register-settings.php:
|
3136 |
msgid "Purchase Email Subject"
|
3137 |
msgstr ""
|
3138 |
|
3139 |
-
#: includes/admin/settings/register-settings.php:
|
3140 |
msgid "Enter the subject line for the purchase receipt email"
|
3141 |
msgstr ""
|
3142 |
|
|
|
|
|
3143 |
#: includes/admin/settings/register-settings.php:501
|
3144 |
-
#: includes/admin/settings/register-settings.php:508
|
3145 |
-
#: includes/admin/settings/register-settings.php:512
|
3146 |
#: includes/emails/functions.php:36 includes/emails/functions.php:40
|
3147 |
#: includes/emails/functions.php:77 includes/emails/functions.php:81
|
3148 |
#: includes/emails/template.php:141
|
3149 |
msgid "Purchase Receipt"
|
3150 |
msgstr ""
|
3151 |
|
3152 |
-
#: includes/admin/settings/register-settings.php:
|
3153 |
msgid "Purchase Email Heading"
|
3154 |
msgstr ""
|
3155 |
|
3156 |
-
#: includes/admin/settings/register-settings.php:
|
3157 |
msgid "Enter the heading for the purchase receipt email"
|
3158 |
msgstr ""
|
3159 |
|
3160 |
-
#: includes/admin/settings/register-settings.php:
|
3161 |
msgid ""
|
3162 |
"Enter the text that is sent as purchase receipt email to users after "
|
3163 |
"completion of a successful purchase. HTML is accepted. Available template "
|
3164 |
"tags:"
|
3165 |
msgstr ""
|
3166 |
|
3167 |
-
#: includes/admin/settings/register-settings.php:
|
3168 |
#: includes/emails/template.php:159
|
3169 |
msgid "Dear"
|
3170 |
msgstr ""
|
3171 |
|
3172 |
-
#: includes/admin/settings/register-settings.php:
|
3173 |
#: includes/emails/template.php:160
|
3174 |
msgid ""
|
3175 |
"Thank you for your purchase. Please click on the link(s) below to download "
|
3176 |
"your files."
|
3177 |
msgstr ""
|
3178 |
|
3179 |
-
#: includes/admin/settings/register-settings.php:
|
3180 |
msgid "Sale Notifications"
|
3181 |
msgstr ""
|
3182 |
|
3183 |
-
#: includes/admin/settings/register-settings.php:
|
3184 |
msgid "Sale Notification Subject"
|
3185 |
msgstr ""
|
3186 |
|
3187 |
-
#: includes/admin/settings/register-settings.php:
|
3188 |
msgid "Enter the subject line for the sale notification email"
|
3189 |
msgstr ""
|
3190 |
|
3191 |
-
#: includes/admin/settings/register-settings.php:
|
3192 |
msgid "Sale Notification"
|
3193 |
msgstr ""
|
3194 |
|
3195 |
-
#: includes/admin/settings/register-settings.php:
|
3196 |
msgid ""
|
3197 |
"Enter the text that is sent as sale notification email after completion of "
|
3198 |
"a purchase. HTML is accepted. Available template tags:"
|
3199 |
msgstr ""
|
3200 |
|
3201 |
-
#: includes/admin/settings/register-settings.php:
|
3202 |
msgid "Sale Notification Emails"
|
3203 |
msgstr ""
|
3204 |
|
3205 |
-
#: includes/admin/settings/register-settings.php:
|
3206 |
msgid ""
|
3207 |
"Enter the email address(es) that should receive a notification anytime a "
|
3208 |
"sale is made, one per line"
|
3209 |
msgstr ""
|
3210 |
|
3211 |
-
#: includes/admin/settings/register-settings.php:
|
3212 |
msgid "Disable Admin Notifications"
|
3213 |
msgstr ""
|
3214 |
|
3215 |
-
#: includes/admin/settings/register-settings.php:
|
3216 |
msgid "Check this box if you do not want to receive sales notification emails."
|
3217 |
msgstr ""
|
3218 |
|
3219 |
-
#: includes/admin/settings/register-settings.php:
|
3220 |
-
#: includes/admin/settings/register-settings.php:
|
3221 |
msgid "Style Settings"
|
3222 |
msgstr ""
|
3223 |
|
3224 |
-
#: includes/admin/settings/register-settings.php:
|
3225 |
msgid "Disable Styles"
|
3226 |
msgstr ""
|
3227 |
|
3228 |
-
#: includes/admin/settings/register-settings.php:
|
3229 |
msgid ""
|
3230 |
"Check this to disable all included styling of buttons, checkout fields, and "
|
3231 |
"all other elements."
|
3232 |
msgstr ""
|
3233 |
|
3234 |
-
#: includes/admin/settings/register-settings.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3235 |
msgid "Buttons"
|
3236 |
msgstr ""
|
3237 |
|
3238 |
-
#: includes/admin/settings/register-settings.php:
|
3239 |
msgid "Options for add to cart and purchase buttons"
|
3240 |
msgstr ""
|
3241 |
|
3242 |
-
#: includes/admin/settings/register-settings.php:
|
3243 |
msgid "Default Button Style"
|
3244 |
msgstr ""
|
3245 |
|
3246 |
-
#: includes/admin/settings/register-settings.php:
|
3247 |
msgid "Choose the style you want to use for the buttons."
|
3248 |
msgstr ""
|
3249 |
|
3250 |
-
#: includes/admin/settings/register-settings.php:
|
3251 |
msgid "Default Button Color"
|
3252 |
msgstr ""
|
3253 |
|
3254 |
-
#: includes/admin/settings/register-settings.php:
|
3255 |
msgid "Choose the color you want to use for the buttons."
|
3256 |
msgstr ""
|
3257 |
|
3258 |
-
#: includes/admin/settings/register-settings.php:
|
3259 |
-
#: includes/admin/settings/register-settings.php:
|
3260 |
msgid "Tax Settings"
|
3261 |
msgstr ""
|
3262 |
|
3263 |
-
#: includes/admin/settings/register-settings.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3264 |
msgid "Enable Taxes"
|
3265 |
msgstr ""
|
3266 |
|
3267 |
-
#: includes/admin/settings/register-settings.php:
|
3268 |
msgid "Check this to enable taxes on purchases."
|
3269 |
msgstr ""
|
3270 |
|
3271 |
-
#: includes/admin/settings/register-settings.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3272 |
msgid "Tax Rates"
|
3273 |
msgstr ""
|
3274 |
|
3275 |
-
#: includes/admin/settings/register-settings.php:
|
3276 |
msgid "Enter tax rates for specific regions."
|
3277 |
msgstr ""
|
3278 |
|
3279 |
-
#: includes/admin/settings/register-settings.php:
|
|
|
3280 |
msgid "Fallback Tax Rate"
|
3281 |
msgstr ""
|
3282 |
|
3283 |
-
#: includes/admin/settings/register-settings.php:
|
3284 |
msgid ""
|
3285 |
"Enter a percentage, such as 6.5. Customers not in a specific rate will be "
|
3286 |
"charged this rate."
|
3287 |
msgstr ""
|
3288 |
|
3289 |
-
#: includes/admin/settings/register-settings.php:
|
3290 |
-
msgid "
|
|
|
|
|
3291 |
msgstr ""
|
3292 |
|
3293 |
#: includes/admin/settings/register-settings.php:623
|
|
|
|
|
|
|
|
|
3294 |
msgid "This option affects how you enter prices."
|
3295 |
msgstr ""
|
3296 |
|
3297 |
-
#: includes/admin/settings/register-settings.php:
|
3298 |
msgid "Yes, I will enter prices inclusive of tax"
|
3299 |
msgstr ""
|
3300 |
|
3301 |
-
#: includes/admin/settings/register-settings.php:
|
3302 |
msgid "No, I will enter prices exclusive of tax"
|
3303 |
msgstr ""
|
3304 |
|
3305 |
-
#: includes/admin/settings/register-settings.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3306 |
msgid "Display Tax Rate on Prices"
|
3307 |
msgstr ""
|
3308 |
|
3309 |
-
#: includes/admin/settings/register-settings.php:
|
3310 |
msgid "Some countries require a notice when product prices include tax."
|
3311 |
msgstr ""
|
3312 |
|
3313 |
-
#: includes/admin/settings/register-settings.php:
|
3314 |
msgid "Display during checkout"
|
3315 |
msgstr ""
|
3316 |
|
3317 |
-
#: includes/admin/settings/register-settings.php:
|
3318 |
msgid "Should prices on the checkout page be shown with or without tax?"
|
3319 |
msgstr ""
|
3320 |
|
3321 |
-
#: includes/admin/settings/register-settings.php:
|
3322 |
msgid "Including tax"
|
3323 |
msgstr ""
|
3324 |
|
3325 |
-
#: includes/admin/settings/register-settings.php:
|
3326 |
msgid "Excluding tax"
|
3327 |
msgstr ""
|
3328 |
|
3329 |
-
#: includes/admin/settings/register-settings.php:
|
3330 |
-
#: includes/admin/settings/register-settings.php:
|
3331 |
msgid "Misc Settings"
|
3332 |
msgstr ""
|
3333 |
|
3334 |
-
#: includes/admin/settings/register-settings.php:
|
3335 |
-
msgid "Enable
|
3336 |
msgstr ""
|
3337 |
|
3338 |
-
#: includes/admin/settings/register-settings.php:
|
3339 |
msgid "Check this to enable AJAX for the shopping cart."
|
3340 |
msgstr ""
|
3341 |
|
3342 |
#: includes/admin/settings/register-settings.php:676
|
3343 |
-
msgid "
|
3344 |
msgstr ""
|
3345 |
|
3346 |
#: includes/admin/settings/register-settings.php:677
|
3347 |
-
msgid "
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3348 |
msgstr ""
|
3349 |
|
3350 |
#: includes/admin/settings/register-settings.php:682
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3351 |
msgid "Item Quantities"
|
3352 |
msgstr ""
|
3353 |
|
3354 |
-
#: includes/admin/settings/register-settings.php:
|
3355 |
msgid "Allow item quantities to be changed."
|
3356 |
msgstr ""
|
3357 |
|
3358 |
-
#: includes/admin/settings/register-settings.php:
|
3359 |
msgid "Remove Data on Uninstall?"
|
3360 |
msgstr ""
|
3361 |
|
3362 |
-
#: includes/admin/settings/register-settings.php:
|
3363 |
msgid ""
|
3364 |
"Check this box if you would like EDD to completely remove all of its data "
|
3365 |
"when the plugin is deleted."
|
3366 |
msgstr ""
|
3367 |
|
3368 |
-
#: includes/admin/settings/register-settings.php:
|
3369 |
-
#: includes/admin/settings/register-settings.php:
|
3370 |
msgid "Checkout Settings"
|
3371 |
msgstr ""
|
3372 |
|
3373 |
-
#: includes/admin/settings/register-settings.php:
|
3374 |
msgid "Enforce SSL on Checkout"
|
3375 |
msgstr ""
|
3376 |
|
3377 |
-
#: includes/admin/settings/register-settings.php:
|
3378 |
msgid ""
|
3379 |
"Check this to force users to be redirected to the secure checkout page. You "
|
3380 |
"must have an SSL certificate installed to use this option."
|
3381 |
msgstr ""
|
3382 |
|
3383 |
-
#: includes/admin/settings/register-settings.php:
|
3384 |
msgid "Disable Guest Checkout"
|
3385 |
msgstr ""
|
3386 |
|
3387 |
-
#: includes/admin/settings/register-settings.php:
|
3388 |
msgid "Require that users be logged-in to purchase files."
|
3389 |
msgstr ""
|
3390 |
|
3391 |
-
#: includes/admin/settings/register-settings.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3392 |
msgid "Show Register / Login Form?"
|
3393 |
msgstr ""
|
3394 |
|
3395 |
-
#: includes/admin/settings/register-settings.php:
|
3396 |
msgid ""
|
3397 |
"Display the registration and login forms on the checkout page for "
|
3398 |
"non-logged-in users."
|
3399 |
msgstr ""
|
3400 |
|
3401 |
-
#: includes/admin/settings/register-settings.php:
|
3402 |
msgid "Registration and Login Forms"
|
3403 |
msgstr ""
|
3404 |
|
3405 |
-
#: includes/admin/settings/register-settings.php:
|
3406 |
msgid "Registration Form Only"
|
3407 |
msgstr ""
|
3408 |
|
3409 |
-
#: includes/admin/settings/register-settings.php:
|
3410 |
msgid "Login Form Only"
|
3411 |
msgstr ""
|
3412 |
|
3413 |
-
#: includes/admin/settings/register-settings.php:
|
3414 |
msgid "Multiple Discounts"
|
3415 |
msgstr ""
|
3416 |
|
3417 |
-
#: includes/admin/settings/register-settings.php:
|
3418 |
msgid "Allow customers to use multiple discounts on the same purchase?"
|
3419 |
msgstr ""
|
3420 |
|
3421 |
-
#: includes/admin/settings/register-settings.php:
|
3422 |
msgid "Enable Cart Saving"
|
3423 |
msgstr ""
|
3424 |
|
3425 |
-
#: includes/admin/settings/register-settings.php:
|
3426 |
msgid "Check this to enable cart saving on the checkout."
|
3427 |
msgstr ""
|
3428 |
|
3429 |
-
#: includes/admin/settings/register-settings.php:
|
3430 |
-
|
3431 |
-
msgid "Button Text"
|
3432 |
msgstr ""
|
3433 |
|
3434 |
#: includes/admin/settings/register-settings.php:745
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3435 |
msgid "Complete Purchase Text"
|
3436 |
msgstr ""
|
3437 |
|
3438 |
-
#: includes/admin/settings/register-settings.php:
|
3439 |
msgid "The button label for completing a purchase."
|
3440 |
msgstr ""
|
3441 |
|
3442 |
-
#: includes/admin/settings/register-settings.php:
|
3443 |
msgid "Add to Cart Text"
|
3444 |
msgstr ""
|
3445 |
|
3446 |
-
#: includes/admin/settings/register-settings.php:
|
3447 |
msgid "Text shown on the Add to Cart Buttons."
|
3448 |
msgstr ""
|
3449 |
|
3450 |
-
#: includes/admin/settings/register-settings.php:
|
3451 |
msgid "Buy Now Text"
|
3452 |
msgstr ""
|
3453 |
|
3454 |
-
#: includes/admin/settings/register-settings.php:
|
3455 |
msgid "Text shown on the Buy Now Buttons."
|
3456 |
msgstr ""
|
3457 |
|
3458 |
-
#: includes/admin/settings/register-settings.php:
|
3459 |
msgid "File Download Settings"
|
3460 |
msgstr ""
|
3461 |
|
3462 |
-
#: includes/admin/settings/register-settings.php:
|
|
|
3463 |
msgid "Download Method"
|
3464 |
msgstr ""
|
3465 |
|
3466 |
-
#: includes/admin/settings/register-settings.php:
|
3467 |
msgid "Select the file download method. Note, not all methods work on all servers."
|
3468 |
msgstr ""
|
3469 |
|
3470 |
-
#: includes/admin/settings/register-settings.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3471 |
msgid "Forced"
|
3472 |
msgstr ""
|
3473 |
|
3474 |
-
#: includes/admin/settings/register-settings.php:
|
3475 |
msgid "Redirect"
|
3476 |
msgstr ""
|
3477 |
|
3478 |
-
#: includes/admin/settings/register-settings.php:
|
3479 |
msgid "Symlink File Downloads?"
|
3480 |
msgstr ""
|
3481 |
|
3482 |
-
#: includes/admin/settings/register-settings.php:
|
3483 |
msgid ""
|
3484 |
"Check this if you are delivering really large files or having problems with "
|
3485 |
"file downloads completing."
|
3486 |
msgstr ""
|
3487 |
|
3488 |
-
#: includes/admin/settings/register-settings.php:
|
3489 |
msgid ""
|
3490 |
"The maximum number of times files can be downloaded for purchases. Can be "
|
3491 |
"overwritten for each %s."
|
3492 |
msgstr ""
|
3493 |
|
3494 |
-
#: includes/admin/settings/register-settings.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3495 |
msgid "Download Link Expiration"
|
3496 |
msgstr ""
|
3497 |
|
3498 |
-
#: includes/admin/settings/register-settings.php:
|
3499 |
msgid ""
|
3500 |
"How long should download links be valid for? Default is 24 hours from the "
|
3501 |
"time they are generated. Enter a time in hours."
|
3502 |
msgstr ""
|
3503 |
|
3504 |
-
#: includes/admin/settings/register-settings.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3505 |
msgid "Disable Redownload?"
|
3506 |
msgstr ""
|
3507 |
|
3508 |
-
#: includes/admin/settings/register-settings.php:
|
3509 |
msgid ""
|
3510 |
"Check this if you do not want to allow users to redownload items from their "
|
3511 |
"purchase history."
|
3512 |
msgstr ""
|
3513 |
|
3514 |
-
#: includes/admin/settings/register-settings.php:
|
3515 |
-
#: includes/admin/settings/register-settings.php:
|
3516 |
msgid "Accounting Settings"
|
3517 |
msgstr ""
|
3518 |
|
3519 |
-
#: includes/admin/settings/register-settings.php:
|
3520 |
msgid "Enable SKU Entry"
|
3521 |
msgstr ""
|
3522 |
|
3523 |
-
#: includes/admin/settings/register-settings.php:
|
3524 |
msgid ""
|
3525 |
"Check this box to allow entry of product SKUs. SKUs will be shown on "
|
3526 |
"purchase receipt and exported purchase histories."
|
3527 |
msgstr ""
|
3528 |
|
3529 |
-
#: includes/admin/settings/register-settings.php:
|
3530 |
msgid "Sequential Order Numbers"
|
3531 |
msgstr ""
|
3532 |
|
3533 |
-
#: includes/admin/settings/register-settings.php:
|
3534 |
msgid "Check this box to enable sequential order numbers."
|
3535 |
msgstr ""
|
3536 |
|
3537 |
-
#: includes/admin/settings/register-settings.php:
|
3538 |
msgid "Sequential Starting Number"
|
3539 |
msgstr ""
|
3540 |
|
3541 |
-
#: includes/admin/settings/register-settings.php:
|
3542 |
msgid "The number at which the sequence should begin."
|
3543 |
msgstr ""
|
3544 |
|
3545 |
-
#: includes/admin/settings/register-settings.php:
|
3546 |
msgid "Sequential Number Prefix"
|
3547 |
msgstr ""
|
3548 |
|
3549 |
-
#: includes/admin/settings/register-settings.php:
|
3550 |
msgid "A prefix to prepend to all sequential order numbers."
|
3551 |
msgstr ""
|
3552 |
|
3553 |
-
#: includes/admin/settings/register-settings.php:
|
3554 |
msgid "Sequential Number Postfix"
|
3555 |
msgstr ""
|
3556 |
|
3557 |
-
#: includes/admin/settings/register-settings.php:
|
3558 |
msgid "A postfix to append to all sequential order numbers."
|
3559 |
msgstr ""
|
3560 |
|
3561 |
-
#: includes/admin/settings/register-settings.php:
|
3562 |
msgid "Agreement Settings"
|
3563 |
msgstr ""
|
3564 |
|
3565 |
-
#: includes/admin/settings/register-settings.php:
|
3566 |
msgid "Agree to Terms"
|
3567 |
msgstr ""
|
3568 |
|
3569 |
-
#: includes/admin/settings/register-settings.php:
|
3570 |
msgid ""
|
3571 |
"Check this to show an agree to terms on the checkout that users must agree "
|
3572 |
"to before purchasing."
|
3573 |
msgstr ""
|
3574 |
|
3575 |
-
#: includes/admin/settings/register-settings.php:
|
3576 |
msgid "Agree to Terms Label"
|
3577 |
msgstr ""
|
3578 |
|
3579 |
-
#: includes/admin/settings/register-settings.php:
|
3580 |
msgid "Label shown next to the agree to terms check box."
|
3581 |
msgstr ""
|
3582 |
|
3583 |
-
#: includes/admin/settings/register-settings.php:
|
3584 |
msgid "Agreement Text"
|
3585 |
msgstr ""
|
3586 |
|
3587 |
-
#: includes/admin/settings/register-settings.php:
|
3588 |
msgid "If Agree to Terms is checked, enter the agreement terms here."
|
3589 |
msgstr ""
|
3590 |
|
3591 |
-
#: includes/admin/settings/register-settings.php:
|
3592 |
msgid "Settings updated."
|
3593 |
msgstr ""
|
3594 |
|
3595 |
-
#: includes/admin/settings/register-settings.php:
|
3596 |
msgid "Licenses"
|
3597 |
msgstr ""
|
3598 |
|
3599 |
-
#: includes/admin/settings/register-settings.php:
|
3600 |
msgid "Misc"
|
3601 |
msgstr ""
|
3602 |
|
3603 |
-
#: includes/admin/settings/register-settings.php:
|
3604 |
-
#: includes/gateways/functions.php:25
|
3605 |
msgid "PayPal Standard"
|
3606 |
msgstr ""
|
3607 |
|
3608 |
-
#: includes/admin/settings/register-settings.php:
|
3609 |
msgid "New Sale Notifications"
|
3610 |
msgstr ""
|
3611 |
|
3612 |
-
#: includes/admin/settings/register-settings.php:
|
3613 |
msgid "Main"
|
3614 |
msgstr ""
|
3615 |
|
3616 |
-
#: includes/admin/settings/register-settings.php:
|
3617 |
msgid "Terms of Agreement"
|
3618 |
msgstr ""
|
3619 |
|
3620 |
-
#: includes/admin/settings/register-settings.php:
|
3621 |
msgid "The callback function used for the %s setting is missing."
|
3622 |
msgstr ""
|
3623 |
|
3624 |
-
#: includes/admin/settings/register-settings.php:
|
3625 |
msgid "Upload File"
|
3626 |
msgstr ""
|
3627 |
|
3628 |
-
#: includes/admin/settings/register-settings.php:
|
3629 |
-
msgid "Apply rate to whole country, regardless of state / province"
|
3630 |
-
msgstr ""
|
3631 |
-
|
3632 |
-
#: includes/admin/settings/register-settings.php:1744
|
3633 |
msgid "Country Wide"
|
3634 |
msgstr ""
|
3635 |
|
3636 |
-
#: includes/admin/settings/register-settings.php:
|
3637 |
msgid "Rate"
|
3638 |
msgstr ""
|
3639 |
|
3640 |
-
#: includes/admin/settings/register-settings.php:
|
3641 |
-
#: includes/admin/settings/register-settings.php:
|
3642 |
msgid "Choose a country"
|
3643 |
msgstr ""
|
3644 |
|
3645 |
-
#: includes/admin/settings/register-settings.php:
|
3646 |
msgid "Choose a state"
|
3647 |
msgstr ""
|
3648 |
|
3649 |
-
#: includes/admin/settings/register-settings.php:
|
3650 |
-
#: includes/admin/settings/register-settings.php:
|
3651 |
msgid "Apply to whole country"
|
3652 |
msgstr ""
|
3653 |
|
3654 |
-
#: includes/admin/settings/register-settings.php:
|
3655 |
-
#: includes/admin/settings/register-settings.php:
|
3656 |
msgid "Remove Rate"
|
3657 |
msgstr ""
|
3658 |
|
3659 |
-
#: includes/admin/settings/register-settings.php:
|
3660 |
msgid "Add Tax Rate"
|
3661 |
msgstr ""
|
3662 |
|
3663 |
-
#: includes/admin/settings/register-settings.php:
|
3664 |
msgid ""
|
3665 |
-
"Your license key expired on %s. Please <a href=\"%s\"
|
3666 |
-
"
|
3667 |
msgstr ""
|
3668 |
|
3669 |
-
#: includes/admin/settings/register-settings.php:
|
3670 |
msgid ""
|
3671 |
-
"
|
3672 |
-
"
|
3673 |
msgstr ""
|
3674 |
|
3675 |
-
#: includes/admin/settings/register-settings.php:
|
3676 |
msgid ""
|
3677 |
-
"
|
3678 |
-
"
|
3679 |
-
"license key URLs."
|
3680 |
msgstr ""
|
3681 |
|
3682 |
-
#: includes/admin/settings/register-settings.php:
|
3683 |
-
msgid "
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3684 |
msgstr ""
|
3685 |
|
3686 |
-
#: includes/admin/settings/register-settings.php:
|
3687 |
msgid ""
|
3688 |
"Your license key has reached its activation limit. <a href=\"%s\">View "
|
3689 |
"possible upgrades</a> now."
|
3690 |
msgstr ""
|
3691 |
|
3692 |
-
#: includes/admin/settings/register-settings.php:
|
3693 |
msgid "License key never expires."
|
3694 |
msgstr ""
|
3695 |
|
3696 |
-
#: includes/admin/settings/register-settings.php:
|
3697 |
msgid ""
|
3698 |
"Your license key expires soon! It expires on %s. <a href=\"%s\" "
|
3699 |
-
"target=\"_blank\"
|
3700 |
msgstr ""
|
3701 |
|
3702 |
-
#: includes/admin/settings/register-settings.php:
|
3703 |
msgid "Your license key expires on %s."
|
3704 |
msgstr ""
|
3705 |
|
3706 |
-
#: includes/admin/settings/register-settings.php:
|
3707 |
-
msgid "
|
3708 |
msgstr ""
|
3709 |
|
3710 |
-
#: includes/admin/
|
3711 |
-
|
3712 |
-
msgid "Insert %s"
|
3713 |
msgstr ""
|
3714 |
|
3715 |
-
#: includes/admin/thickbox.php:
|
3716 |
-
msgid "Insert
|
3717 |
msgstr ""
|
3718 |
|
3719 |
-
#: includes/admin/thickbox.php:
|
3720 |
msgid "You must choose a download"
|
3721 |
msgstr ""
|
3722 |
|
3723 |
-
#: includes/admin/thickbox.php:
|
3724 |
msgid "Use the form below to insert the short code for purchasing a %s"
|
3725 |
msgstr ""
|
3726 |
|
3727 |
-
#: includes/admin/thickbox.php:
|
3728 |
msgid "Choose the button behavior"
|
3729 |
msgstr ""
|
3730 |
|
3731 |
-
#: includes/admin/thickbox.php:
|
3732 |
msgid "Direct Purchase Link"
|
3733 |
msgstr ""
|
3734 |
|
3735 |
-
#: includes/admin/thickbox.php:
|
3736 |
msgid "Choose a style"
|
3737 |
msgstr ""
|
3738 |
|
3739 |
-
#: includes/admin/thickbox.php:
|
3740 |
msgid "Choose a button color"
|
3741 |
msgstr ""
|
3742 |
|
3743 |
-
#: includes/admin/thickbox.php:
|
3744 |
msgid "Link text . . ."
|
3745 |
msgstr ""
|
3746 |
|
@@ -3803,104 +4185,304 @@ msgstr ""
|
|
3803 |
msgid "Please select an option"
|
3804 |
msgstr ""
|
3805 |
|
3806 |
-
#: includes/admin/tools.php:140
|
3807 |
-
msgid "Recount Store Earnings and Sales"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3808 |
msgstr ""
|
3809 |
|
3810 |
-
#: includes/admin/tools.php:
|
3811 |
-
msgid "
|
3812 |
msgstr ""
|
3813 |
|
3814 |
-
#: includes/admin/tools.php:
|
3815 |
-
msgid "
|
3816 |
msgstr ""
|
3817 |
|
3818 |
-
#: includes/admin/tools.php:
|
3819 |
-
msgid "
|
3820 |
msgstr ""
|
3821 |
|
3822 |
-
#: includes/admin/tools.php:
|
3823 |
-
msgid "
|
3824 |
msgstr ""
|
3825 |
|
3826 |
-
#: includes/admin/tools.php:
|
3827 |
-
msgid "
|
3828 |
msgstr ""
|
3829 |
|
3830 |
-
#: includes/admin/tools.php:
|
3831 |
-
msgid "
|
3832 |
msgstr ""
|
3833 |
|
3834 |
-
#: includes/admin/tools.php:
|
3835 |
-
msgid "
|
3836 |
msgstr ""
|
3837 |
|
3838 |
-
#: includes/admin/tools.php:
|
3839 |
-
msgid ""
|
3840 |
-
"<strong>Deletes</strong> all payment records, customers, and related log "
|
3841 |
-
"entries."
|
3842 |
msgstr ""
|
3843 |
|
3844 |
-
#: includes/admin/tools.php:
|
3845 |
-
msgid "
|
3846 |
msgstr ""
|
3847 |
|
3848 |
-
#: includes/admin/tools.php:
|
3849 |
-
msgid ""
|
3850 |
-
"Sometimes a database upgrade notice may not be cleared after an upgrade is "
|
3851 |
-
"completed due to conflicts with other extensions or other minor issues."
|
3852 |
msgstr ""
|
3853 |
|
3854 |
-
#: includes/admin/tools.php:
|
3855 |
-
msgid ""
|
3856 |
-
"If you're certain these upgrades have been completed, you can clear these "
|
3857 |
-
"upgrade notices by clicking the button below. If you have any questions "
|
3858 |
-
"about this, please contact the Easy Digital Downloads support team and "
|
3859 |
-
"we'll be happy to help."
|
3860 |
msgstr ""
|
3861 |
|
3862 |
-
#: includes/admin/tools.php:
|
3863 |
-
msgid ""
|
3864 |
-
"These API keys allow you to use the <a href=\"%s\">EDD REST API</a> to "
|
3865 |
-
"retrieve store data in JSON or XML for external applications or devices, "
|
3866 |
-
"such as the <a href=\"%s\">EDD mobile app</a>."
|
3867 |
msgstr ""
|
3868 |
|
3869 |
-
#: includes/admin/tools.php:
|
3870 |
msgid "Export Settings"
|
3871 |
msgstr ""
|
3872 |
|
3873 |
-
#: includes/admin/tools.php:
|
3874 |
msgid ""
|
3875 |
"Export the Easy Digital Downloads settings for this site as a .json file. "
|
3876 |
"This allows you to easily import the configuration into another site."
|
3877 |
msgstr ""
|
3878 |
|
3879 |
-
#: includes/admin/tools.php:
|
3880 |
msgid ""
|
3881 |
"To export shop data (purchases, customers, etc), visit the <a "
|
3882 |
"href=\"%s\">Reports</a> page."
|
3883 |
msgstr ""
|
3884 |
|
3885 |
-
#: includes/admin/tools.php:
|
3886 |
msgid "Import Settings"
|
3887 |
msgstr ""
|
3888 |
|
3889 |
-
#: includes/admin/tools.php:
|
3890 |
msgid ""
|
3891 |
"Import the Easy Digital Downloads settings from a .json file. This file can "
|
3892 |
"be obtained by exporting the settings on another site using the form above."
|
3893 |
msgstr ""
|
3894 |
|
3895 |
-
#: includes/admin/tools.php:
|
3896 |
msgid "Import"
|
3897 |
msgstr ""
|
3898 |
|
3899 |
-
#: includes/admin/tools.php:
|
3900 |
msgid "Please upload a valid .json file"
|
3901 |
msgstr ""
|
3902 |
|
3903 |
-
#: includes/admin/tools.php:
|
3904 |
msgid "Please upload a file to import"
|
3905 |
msgstr ""
|
3906 |
|
@@ -3920,92 +4502,92 @@ msgstr ""
|
|
3920 |
msgid "Do not allow"
|
3921 |
msgstr ""
|
3922 |
|
3923 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3924 |
msgid "The Payment History needs to be updated. %s"
|
3925 |
msgstr ""
|
3926 |
|
3927 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3928 |
msgid "Click to Upgrade"
|
3929 |
msgstr ""
|
3930 |
|
3931 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3932 |
msgid ""
|
3933 |
"The Purchase and File Download History in Easy Digital Downloads needs to "
|
3934 |
"be upgraded, click %shere%s to start the upgrade."
|
3935 |
msgstr ""
|
3936 |
|
3937 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3938 |
msgid ""
|
3939 |
"Easy Digital Downloads needs to upgrade the plugin pages, click %shere%s to "
|
3940 |
"start the upgrade."
|
3941 |
msgstr ""
|
3942 |
|
3943 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3944 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3945 |
msgid ""
|
3946 |
"Easy Digital Downloads needs to upgrade the database, click %shere%s to "
|
3947 |
"start the upgrade."
|
3948 |
msgstr ""
|
3949 |
|
3950 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3951 |
msgid ""
|
3952 |
"Easy Digital Downloads needs to complete a database upgrade that was "
|
3953 |
"previously started, click <a href=\"%s\">here</a> to resume the upgrade."
|
3954 |
msgstr ""
|
3955 |
|
3956 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3957 |
msgid ""
|
3958 |
"Easy Digital Downloads needs to upgrade past order numbers to make them "
|
3959 |
"sequential, click <a href=\"%s\">here</a> to start the upgrade."
|
3960 |
msgstr ""
|
3961 |
|
3962 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3963 |
msgid ""
|
3964 |
"Easy Digital Downloads needs to upgrade the customer database, click "
|
3965 |
"%shere%s to start the upgrade."
|
3966 |
msgstr ""
|
3967 |
|
3968 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3969 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3970 |
msgid ""
|
3971 |
"Easy Digital Downloads needs to upgrade the payment database, click <a "
|
3972 |
"href=\"%s\">here</a> to start the upgrade."
|
3973 |
msgstr ""
|
3974 |
|
3975 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3976 |
msgid ""
|
3977 |
"Easy Digital Downloads needs to upgrade the customer database, click <a "
|
3978 |
"href=\"%s\">here</a> to start the upgrade."
|
3979 |
msgstr ""
|
3980 |
|
3981 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3982 |
msgid ""
|
3983 |
"Easy Digital Downloads needs to upgrade the API Key database, click <a "
|
3984 |
"href=\"%s\">here</a> to start the upgrade."
|
3985 |
msgstr ""
|
3986 |
|
3987 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3988 |
msgid ""
|
3989 |
"Easy Digital Downloads needs to upgrade the payments database, click <a "
|
3990 |
"href=\"%s\">here</a> to start the upgrade."
|
3991 |
msgstr ""
|
3992 |
|
3993 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3994 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3995 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3996 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3997 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3998 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
3999 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
4000 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
4001 |
msgid "You do not have permission to do shop upgrades"
|
4002 |
msgstr ""
|
4003 |
|
4004 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
4005 |
msgid "Transaction Failed"
|
4006 |
msgstr ""
|
4007 |
|
4008 |
-
#: includes/admin/upgrades/upgrade-functions.php:
|
4009 |
msgid "Your transaction failed, please try again or contact site support."
|
4010 |
msgstr ""
|
4011 |
|
@@ -4058,337 +4640,338 @@ msgstr ""
|
|
4058 |
msgid "Credits"
|
4059 |
msgstr ""
|
4060 |
|
4061 |
-
#: includes/admin/welcome.php:186
|
4062 |
-
msgid "
|
4063 |
msgstr ""
|
4064 |
|
4065 |
#: includes/admin/welcome.php:192
|
4066 |
msgid ""
|
4067 |
-
"
|
4068 |
-
"
|
|
|
|
|
4069 |
msgstr ""
|
4070 |
|
4071 |
#: includes/admin/welcome.php:194
|
4072 |
-
msgid "Secure Checkout"
|
4073 |
-
msgstr ""
|
4074 |
-
|
4075 |
-
#: includes/admin/welcome.php:195
|
4076 |
msgid ""
|
4077 |
-
"
|
4078 |
-
"
|
4079 |
-
"
|
4080 |
msgstr ""
|
4081 |
|
4082 |
-
#: includes/admin/welcome.php:
|
4083 |
-
msgid "
|
4084 |
msgstr ""
|
4085 |
|
4086 |
-
#: includes/admin/welcome.php:
|
4087 |
msgid ""
|
4088 |
-
"
|
4089 |
-
"
|
4090 |
-
"
|
|
|
|
|
4091 |
msgstr ""
|
4092 |
|
4093 |
-
#: includes/admin/welcome.php:
|
4094 |
-
msgid "
|
4095 |
msgstr ""
|
4096 |
|
4097 |
-
#: includes/admin/welcome.php:
|
4098 |
msgid ""
|
4099 |
-
"
|
4100 |
-
"
|
4101 |
-
"
|
4102 |
msgstr ""
|
4103 |
|
4104 |
-
#: includes/admin/welcome.php:
|
4105 |
-
msgid "
|
4106 |
msgstr ""
|
4107 |
|
4108 |
-
#: includes/admin/welcome.php:
|
4109 |
msgid ""
|
4110 |
-
"
|
4111 |
-
"
|
|
|
4112 |
msgstr ""
|
4113 |
|
4114 |
-
#: includes/admin/welcome.php:
|
4115 |
-
msgid "
|
4116 |
msgstr ""
|
4117 |
|
4118 |
-
#: includes/admin/welcome.php:
|
4119 |
msgid ""
|
4120 |
-
"
|
4121 |
-
"
|
4122 |
-
"
|
|
|
4123 |
msgstr ""
|
4124 |
|
4125 |
-
#: includes/admin/welcome.php:
|
4126 |
-
msgid "
|
4127 |
msgstr ""
|
4128 |
|
4129 |
-
#: includes/admin/welcome.php:
|
4130 |
msgid ""
|
4131 |
-
"
|
4132 |
-
"
|
4133 |
-
"
|
|
|
|
|
4134 |
msgstr ""
|
4135 |
|
4136 |
-
#: includes/admin/welcome.php:
|
4137 |
-
msgid "
|
4138 |
msgstr ""
|
4139 |
|
4140 |
-
#: includes/admin/welcome.php:
|
4141 |
-
msgid "
|
4142 |
msgstr ""
|
4143 |
|
4144 |
-
#: includes/admin/welcome.php:
|
4145 |
msgid ""
|
4146 |
-
"
|
4147 |
-
"
|
4148 |
-
"
|
4149 |
-
|
4150 |
-
|
4151 |
-
#: includes/admin/welcome.php:234
|
4152 |
-
msgid "Standardized Customer Export"
|
4153 |
msgstr ""
|
4154 |
|
4155 |
-
#: includes/admin/welcome.php:
|
4156 |
msgid ""
|
4157 |
-
"
|
4158 |
-
"
|
4159 |
-
"
|
4160 |
msgstr ""
|
4161 |
|
4162 |
-
#: includes/admin/welcome.php:
|
4163 |
msgid "Additional Updates"
|
4164 |
msgstr ""
|
4165 |
|
4166 |
-
#: includes/admin/welcome.php:
|
4167 |
-
msgid "REST API
|
4168 |
msgstr ""
|
4169 |
|
4170 |
-
#: includes/admin/welcome.php:
|
4171 |
msgid ""
|
4172 |
-
"
|
4173 |
-
"
|
4174 |
msgstr ""
|
4175 |
|
4176 |
-
#: includes/admin/welcome.php:
|
4177 |
-
msgid "
|
4178 |
msgstr ""
|
4179 |
|
4180 |
-
#: includes/admin/welcome.php:
|
4181 |
msgid ""
|
4182 |
-
"
|
4183 |
-
"
|
4184 |
msgstr ""
|
4185 |
|
4186 |
-
#: includes/admin/welcome.php:
|
4187 |
-
msgid "Customer
|
4188 |
msgstr ""
|
4189 |
|
4190 |
-
#: includes/admin/welcome.php:
|
4191 |
msgid ""
|
4192 |
-
"
|
4193 |
-
"
|
4194 |
msgstr ""
|
4195 |
|
4196 |
-
#: includes/admin/welcome.php:
|
4197 |
-
msgid "
|
4198 |
msgstr ""
|
4199 |
|
4200 |
-
#: includes/admin/welcome.php:
|
4201 |
msgid ""
|
4202 |
-
"
|
4203 |
-
"
|
|
|
4204 |
msgstr ""
|
4205 |
|
4206 |
-
#: includes/admin/welcome.php:
|
4207 |
-
msgid "
|
4208 |
msgstr ""
|
4209 |
|
4210 |
-
#: includes/admin/welcome.php:
|
4211 |
-
msgid ""
|
4212 |
-
"Earnings and sales reports can now be shown exclusive of tax, allowing you "
|
4213 |
-
"to easily see how your store is performing after taxes."
|
4214 |
msgstr ""
|
4215 |
|
4216 |
-
#: includes/admin/welcome.php:
|
4217 |
-
msgid "
|
4218 |
msgstr ""
|
4219 |
|
4220 |
-
#: includes/admin/welcome.php:
|
4221 |
msgid ""
|
4222 |
-
"
|
4223 |
-
"
|
4224 |
msgstr ""
|
4225 |
|
4226 |
-
#: includes/admin/welcome.php:
|
4227 |
msgid "Go to Easy Digital Downloads Settings"
|
4228 |
msgstr ""
|
4229 |
|
4230 |
-
#: includes/admin/welcome.php:
|
4231 |
msgid "View the Full Changelog"
|
4232 |
msgstr ""
|
4233 |
|
4234 |
-
#: includes/admin/welcome.php:
|
4235 |
msgid "Full Changelog"
|
4236 |
msgstr ""
|
4237 |
|
4238 |
-
#: includes/admin/welcome.php:
|
4239 |
msgid ""
|
4240 |
"Use the tips below to get started using Easy Digital Downloads. You will be "
|
4241 |
"up and running in no time!"
|
4242 |
msgstr ""
|
4243 |
|
4244 |
-
#: includes/admin/welcome.php:
|
4245 |
msgid "Creating Your First Download Product"
|
4246 |
msgstr ""
|
4247 |
|
4248 |
-
#: includes/admin/welcome.php:
|
4249 |
msgid "%s → Add New"
|
4250 |
msgstr ""
|
4251 |
|
4252 |
-
#: includes/admin/welcome.php:
|
4253 |
msgid ""
|
4254 |
"The %s menu is your access point for all aspects of your Easy Digital "
|
4255 |
"Downloads product creation and setup. To create your first product, simply "
|
4256 |
"click Add New and then fill out the product details."
|
4257 |
msgstr ""
|
4258 |
|
4259 |
-
#: includes/admin/welcome.php:
|
4260 |
-
msgid "Download Files"
|
4261 |
-
msgstr ""
|
4262 |
-
|
4263 |
-
#: includes/admin/welcome.php:339
|
4264 |
msgid ""
|
4265 |
"Uploading the downloadable files is simple. Click <em>Upload File</em> in "
|
4266 |
"the Download Files section and choose your download file. To add more than "
|
4267 |
"one file, simply click the <em>Add New</em> button."
|
4268 |
msgstr ""
|
4269 |
|
4270 |
-
#: includes/admin/welcome.php:
|
4271 |
msgid "Display a Product Grid"
|
4272 |
msgstr ""
|
4273 |
|
4274 |
-
#: includes/admin/welcome.php:
|
4275 |
msgid "Flexible Product Grids"
|
4276 |
msgstr ""
|
4277 |
|
4278 |
-
#: includes/admin/welcome.php:
|
4279 |
msgid ""
|
4280 |
"The [downloads] shortcode will display a product grid that works with any "
|
4281 |
"theme, no matter the size. It is even responsive!"
|
4282 |
msgstr ""
|
4283 |
|
4284 |
-
#: includes/admin/welcome.php:
|
4285 |
msgid "Change the Number of Columns"
|
4286 |
msgstr ""
|
4287 |
|
4288 |
-
#: includes/admin/welcome.php:
|
4289 |
msgid ""
|
4290 |
"You can easily change the number of columns by adding the columns=\"x\" "
|
4291 |
"parameter:"
|
4292 |
msgstr ""
|
4293 |
|
4294 |
-
#: includes/admin/welcome.php:
|
4295 |
msgid "Additional Display Options"
|
4296 |
msgstr ""
|
4297 |
|
4298 |
-
#: includes/admin/welcome.php:
|
4299 |
msgid ""
|
4300 |
"The product grids can be customized in any way you wish and there is <a "
|
4301 |
"href=\"%s\">extensive documentation</a> to assist you."
|
4302 |
msgstr ""
|
4303 |
|
4304 |
-
#: includes/admin/welcome.php:
|
4305 |
msgid "Purchase Buttons Anywhere"
|
4306 |
msgstr ""
|
4307 |
|
4308 |
-
#: includes/admin/welcome.php:
|
4309 |
msgid "The <em>[purchase_link]</em> Shortcode"
|
4310 |
msgstr ""
|
4311 |
|
4312 |
-
#: includes/admin/welcome.php:
|
4313 |
msgid ""
|
4314 |
"With easily accessible shortcodes to display purchase buttons, you can add "
|
4315 |
"a Buy Now or Add to Cart button for any product anywhere on your site in "
|
4316 |
"seconds."
|
4317 |
msgstr ""
|
4318 |
|
4319 |
-
#: includes/admin/welcome.php:
|
4320 |
msgid "Buy Now Buttons"
|
4321 |
msgstr ""
|
4322 |
|
4323 |
-
#: includes/admin/welcome.php:
|
4324 |
msgid ""
|
4325 |
"Purchase buttons can behave as either Add to Cart or Buy Now buttons. With "
|
4326 |
"Buy Now buttons customers are taken straight to PayPal, giving them the "
|
4327 |
"most frictionless purchasing experience possible."
|
4328 |
msgstr ""
|
4329 |
|
4330 |
-
#: includes/admin/welcome.php:
|
4331 |
msgid "Need Help?"
|
4332 |
msgstr ""
|
4333 |
|
4334 |
-
#: includes/admin/welcome.php:
|
4335 |
msgid "Phenomenal Support"
|
4336 |
msgstr ""
|
4337 |
|
4338 |
-
#: includes/admin/welcome.php:
|
4339 |
msgid ""
|
4340 |
"We do our best to provide the best support we can. If you encounter a "
|
4341 |
"problem or have a question, simply open a ticket using our <a "
|
4342 |
-
"href=\"https://easydigitaldownloads.com/support
|
|
|
|
|
4343 |
msgstr ""
|
4344 |
|
4345 |
-
#: includes/admin/welcome.php:
|
4346 |
msgid "Need Even Faster Support?"
|
4347 |
msgstr ""
|
4348 |
|
4349 |
-
#: includes/admin/welcome.php:
|
4350 |
msgid ""
|
4351 |
-
"Our <a
|
4352 |
-
"
|
4353 |
-
"
|
|
|
|
|
4354 |
msgstr ""
|
4355 |
|
4356 |
-
#: includes/admin/welcome.php:
|
4357 |
msgid "Stay Up to Date"
|
4358 |
msgstr ""
|
4359 |
|
4360 |
-
#: includes/admin/welcome.php:
|
4361 |
msgid "Get Notified of Extension Releases"
|
4362 |
msgstr ""
|
4363 |
|
4364 |
-
#: includes/admin/welcome.php:
|
4365 |
msgid ""
|
4366 |
"New extensions that make Easy Digital Downloads even more powerful are "
|
4367 |
"released nearly every single week. Subscribe to the newsletter to stay up "
|
4368 |
-
"to date with our latest releases. <a
|
4369 |
-
"target=\"_blank\">Sign
|
|
|
4370 |
msgstr ""
|
4371 |
|
4372 |
-
#: includes/admin/welcome.php:
|
4373 |
msgid "Get Alerted About New Tutorials"
|
4374 |
msgstr ""
|
4375 |
|
4376 |
-
#: includes/admin/welcome.php:
|
4377 |
msgid ""
|
4378 |
-
"<a href=\"
|
4379 |
-
"hear about the latest tutorial
|
4380 |
-
"Digital Downloads further."
|
4381 |
msgstr ""
|
4382 |
|
4383 |
-
#: includes/admin/welcome.php:
|
4384 |
msgid "Extensions for Everything"
|
4385 |
msgstr ""
|
4386 |
|
4387 |
-
#: includes/admin/welcome.php:
|
4388 |
msgid "Over 250 Extensions"
|
4389 |
msgstr ""
|
4390 |
|
4391 |
-
#: includes/admin/welcome.php:
|
4392 |
msgid ""
|
4393 |
"Add-on plugins are available that greatly extend the default functionality "
|
4394 |
"of Easy Digital Downloads. There are extensions for payment processors, "
|
@@ -4396,26 +4979,28 @@ msgid ""
|
|
4396 |
"many, many more."
|
4397 |
msgstr ""
|
4398 |
|
4399 |
-
#: includes/admin/welcome.php:
|
4400 |
msgid "Visit the Extension Store"
|
4401 |
msgstr ""
|
4402 |
|
4403 |
-
#: includes/admin/welcome.php:
|
4404 |
msgid ""
|
4405 |
-
"<a
|
4406 |
-
"
|
4407 |
-
"extensions
|
4408 |
-
"
|
|
|
|
|
4409 |
msgstr ""
|
4410 |
|
4411 |
-
#: includes/admin/welcome.php:
|
4412 |
msgid ""
|
4413 |
"Easy Digital Downloads is created by a worldwide team of developers who aim "
|
4414 |
"to provide the #1 eCommerce platform for selling digital goods through "
|
4415 |
"WordPress."
|
4416 |
msgstr ""
|
4417 |
|
4418 |
-
#: includes/admin/welcome.php:
|
4419 |
msgid "No valid changelog was found."
|
4420 |
msgstr ""
|
4421 |
|
@@ -4431,117 +5016,118 @@ msgstr ""
|
|
4431 |
msgid "No users found"
|
4432 |
msgstr ""
|
4433 |
|
4434 |
-
#: includes/api/class-edd-api.php:
|
4435 |
-
|
|
|
4436 |
msgstr ""
|
4437 |
|
4438 |
-
#: includes/api/class-edd-api.php:
|
4439 |
-
|
|
|
4440 |
msgstr ""
|
4441 |
|
4442 |
-
#: includes/api/class-edd-api.php:
|
4443 |
-
msgid "
|
4444 |
msgstr ""
|
4445 |
|
4446 |
-
#: includes/api/class-edd-api.php:
|
4447 |
-
msgid "
|
4448 |
msgstr ""
|
4449 |
|
4450 |
-
#: includes/api/class-edd-api.php:
|
4451 |
-
msgid "
|
4452 |
msgstr ""
|
4453 |
|
4454 |
-
#: includes/api/class-edd-api.php:
|
4455 |
-
msgid "
|
4456 |
msgstr ""
|
4457 |
|
4458 |
-
#: includes/api/class-edd-api.php:
|
4459 |
-
msgid "
|
4460 |
msgstr ""
|
4461 |
|
4462 |
-
#: includes/api/class-edd-api.php:
|
4463 |
-
|
4464 |
-
msgid "Product %s not found!"
|
4465 |
msgstr ""
|
4466 |
|
4467 |
-
#: includes/api/class-edd-api.php:
|
4468 |
-
msgid "
|
4469 |
msgstr ""
|
4470 |
|
4471 |
-
#: includes/api/class-edd-api.php:
|
4472 |
msgid "Invalid or no date range specified!"
|
4473 |
msgstr ""
|
4474 |
|
4475 |
-
#: includes/api/class-edd-api.php:
|
4476 |
msgid "No discounts found!"
|
4477 |
msgstr ""
|
4478 |
|
4479 |
-
#: includes/api/class-edd-api.php:
|
4480 |
msgid "Discount %s not found!"
|
4481 |
msgstr ""
|
4482 |
|
4483 |
-
#: includes/api/class-edd-api.php:
|
4484 |
msgid "No download logs found!"
|
4485 |
msgstr ""
|
4486 |
|
4487 |
-
#: includes/api/class-edd-api.php:
|
4488 |
msgid "Easy Digital Downloads API Keys"
|
4489 |
msgstr ""
|
4490 |
|
4491 |
-
#: includes/api/class-edd-api.php:
|
4492 |
msgid "Generate API Key"
|
4493 |
msgstr ""
|
4494 |
|
4495 |
-
#: includes/api/class-edd-api.php:
|
4496 |
msgid "Public key:"
|
4497 |
msgstr ""
|
4498 |
|
4499 |
-
#: includes/api/class-edd-api.php:
|
4500 |
msgid "Secret key:"
|
4501 |
msgstr ""
|
4502 |
|
4503 |
-
#: includes/api/class-edd-api.php:
|
4504 |
msgid "Token:"
|
4505 |
msgstr ""
|
4506 |
|
4507 |
-
#: includes/api/class-edd-api.php:
|
4508 |
msgid "Revoke API Keys"
|
4509 |
msgstr ""
|
4510 |
|
4511 |
-
#: includes/api/class-edd-api.php:
|
4512 |
msgid "User ID Required"
|
4513 |
msgstr ""
|
4514 |
|
4515 |
-
#: includes/api/class-edd-api.php:
|
4516 |
msgid "You do not have permission to %s API keys for this user"
|
4517 |
msgstr ""
|
4518 |
|
4519 |
-
#: includes/cart/functions.php:
|
4520 |
msgid "includes %s tax"
|
4521 |
msgstr ""
|
4522 |
|
4523 |
-
#: includes/cart/functions.php:
|
4524 |
msgid "excludes %s tax"
|
4525 |
msgstr ""
|
4526 |
|
4527 |
-
#: includes/cart/functions.php:
|
4528 |
-
#: templates/shortcode-profile-editor.php:
|
4529 |
msgid "Success"
|
4530 |
msgstr ""
|
4531 |
|
4532 |
-
#: includes/cart/functions.php:
|
4533 |
msgid "Cart saved successfully. You can restore your cart using this URL:"
|
4534 |
msgstr ""
|
4535 |
|
4536 |
-
#: includes/cart/functions.php:
|
4537 |
msgid "Cart restoration failed. Invalid token."
|
4538 |
msgstr ""
|
4539 |
|
4540 |
-
#: includes/cart/functions.php:
|
4541 |
msgid "The cart cannot be restored. Invalid token."
|
4542 |
msgstr ""
|
4543 |
|
4544 |
-
#: includes/cart/functions.php:
|
4545 |
msgid "Cart restored successfully."
|
4546 |
msgstr ""
|
4547 |
|
@@ -4577,11 +5163,6 @@ msgstr ""
|
|
4577 |
msgid "Personal Info"
|
4578 |
msgstr ""
|
4579 |
|
4580 |
-
#: includes/checkout/template.php:180 templates/shortcode-profile-editor.php:56
|
4581 |
-
#: templates/shortcode-register.php:24
|
4582 |
-
msgid "Email Address"
|
4583 |
-
msgstr ""
|
4584 |
-
|
4585 |
#: includes/checkout/template.php:185
|
4586 |
msgid "We will send the purchase receipt to this address."
|
4587 |
msgstr ""
|
@@ -4792,7 +5373,7 @@ msgstr ""
|
|
4792 |
msgid "Enter a coupon code if you have one."
|
4793 |
msgstr ""
|
4794 |
|
4795 |
-
#: includes/checkout/template.php:723 includes/process-purchase.php:
|
4796 |
#: includes/scripts.php:55
|
4797 |
msgid "Enter discount"
|
4798 |
msgstr ""
|
@@ -4853,7 +5434,7 @@ msgid "Disabled"
|
|
4853 |
msgstr ""
|
4854 |
|
4855 |
#: includes/class-edd-cli.php:63
|
4856 |
-
msgid "
|
4857 |
msgstr ""
|
4858 |
|
4859 |
#: includes/class-edd-cli.php:64
|
@@ -4985,8 +5566,8 @@ msgstr ""
|
|
4985 |
msgid "Customer User ID: %s"
|
4986 |
msgstr ""
|
4987 |
|
4988 |
-
#: includes/class-edd-cli.php:318 includes/user-functions.php:
|
4989 |
-
#: includes/user-functions.php:
|
4990 |
msgid "Username: %s"
|
4991 |
msgstr ""
|
4992 |
|
@@ -5063,7 +5644,7 @@ msgid " Product: %s - %s"
|
|
5063 |
msgstr ""
|
5064 |
|
5065 |
#: includes/class-edd-cli.php:419 includes/class-edd-html-elements.php:208
|
5066 |
-
#: includes/shortcodes.php:
|
5067 |
msgid "No discounts found"
|
5068 |
msgstr ""
|
5069 |
|
@@ -5147,7 +5728,7 @@ msgstr ""
|
|
5147 |
msgid "Once Weekly"
|
5148 |
msgstr ""
|
5149 |
|
5150 |
-
#: includes/class-edd-customer.php:
|
5151 |
msgid "Can't get property %s"
|
5152 |
msgstr ""
|
5153 |
|
@@ -5155,7 +5736,7 @@ msgstr ""
|
|
5155 |
msgid "New Download Product"
|
5156 |
msgstr ""
|
5157 |
|
5158 |
-
#: includes/class-edd-html-elements.php:43 includes/scripts.php:
|
5159 |
msgid "Choose a %s"
|
5160 |
msgstr ""
|
5161 |
|
@@ -5176,21 +5757,20 @@ msgid "Enter username"
|
|
5176 |
msgstr ""
|
5177 |
|
5178 |
#: includes/class-edd-license-handler.php:163
|
5179 |
-
msgid "%1$s
|
5180 |
msgstr ""
|
5181 |
|
5182 |
#: includes/class-edd-license-handler.php:196
|
5183 |
msgid ""
|
5184 |
"Enter your extension license keys here to receive updates for purchased "
|
5185 |
"extensions. If your license key has expired, please <a href=\"%s\" "
|
5186 |
-
"target=\"_blank\"
|
5187 |
msgstr ""
|
5188 |
|
5189 |
#: includes/class-edd-license-handler.php:421
|
5190 |
msgid ""
|
5191 |
"You have invalid or expired license keys for Easy Digital Downloads. Please "
|
5192 |
-
"go to the <a href=\"%s\"
|
5193 |
-
"correct this issue."
|
5194 |
msgstr ""
|
5195 |
|
5196 |
#: includes/class-edd-license-handler.php:460
|
@@ -5543,31 +6123,31 @@ msgstr ""
|
|
5543 |
msgid "This discount is not active."
|
5544 |
msgstr ""
|
5545 |
|
5546 |
-
#: includes/discount-functions.php:
|
5547 |
msgid "This discount is not active yet."
|
5548 |
msgstr ""
|
5549 |
|
5550 |
-
#: includes/discount-functions.php:
|
5551 |
msgid "This discount has reached its maximum usage."
|
5552 |
msgstr ""
|
5553 |
|
5554 |
-
#: includes/discount-functions.php:
|
5555 |
msgid "Minimum order of %s not met."
|
5556 |
msgstr ""
|
5557 |
|
5558 |
-
#: includes/discount-functions.php:
|
5559 |
msgid "The product requirements for this discount are not met."
|
5560 |
msgstr ""
|
5561 |
|
5562 |
-
#: includes/discount-functions.php:
|
5563 |
msgid "This discount is not valid for the cart contents."
|
5564 |
msgstr ""
|
5565 |
|
5566 |
-
#: includes/discount-functions.php:
|
5567 |
msgid "This discount has already been redeemed."
|
5568 |
msgstr ""
|
5569 |
|
5570 |
-
#: includes/discount-functions.php:
|
5571 |
msgid "This discount is invalid."
|
5572 |
msgstr ""
|
5573 |
|
@@ -5660,14 +6240,6 @@ msgstr ""
|
|
5660 |
msgid "These are some sample notes added to a product."
|
5661 |
msgstr ""
|
5662 |
|
5663 |
-
#: includes/emails/template.php:93
|
5664 |
-
msgid "%1$sView it in your browser.%2$s"
|
5665 |
-
msgstr ""
|
5666 |
-
|
5667 |
-
#: includes/emails/template.php:113
|
5668 |
-
msgid "Purchase Receipt Preview"
|
5669 |
-
msgstr ""
|
5670 |
-
|
5671 |
#: includes/emails/template.php:113
|
5672 |
msgid "Preview Purchase Receipt"
|
5673 |
msgstr ""
|
@@ -5693,6 +6265,10 @@ msgstr ""
|
|
5693 |
msgid "Amazon"
|
5694 |
msgstr ""
|
5695 |
|
|
|
|
|
|
|
|
|
5696 |
#: includes/gateways/amazon-payments.php:282
|
5697 |
msgid "Amazon Payments Settings"
|
5698 |
msgstr ""
|
@@ -5787,12 +6363,12 @@ msgstr ""
|
|
5787 |
|
5788 |
#: includes/gateways/amazon-payments.php:1017
|
5789 |
#: includes/gateways/amazon-payments.php:1071
|
5790 |
-
#: includes/gateways/paypal-standard.php:
|
5791 |
-
#: includes/gateways/paypal-standard.php:
|
5792 |
-
#: includes/gateways/paypal-standard.php:
|
5793 |
-
#: includes/gateways/paypal-standard.php:
|
5794 |
-
#: includes/gateways/paypal-standard.php:
|
5795 |
-
#: includes/gateways/paypal-standard.php:
|
5796 |
msgid "IPN Error"
|
5797 |
msgstr ""
|
5798 |
|
@@ -5833,7 +6409,7 @@ msgstr ""
|
|
5833 |
msgid "The requested price ID does not exist."
|
5834 |
msgstr ""
|
5835 |
|
5836 |
-
#: includes/gateways/manual.php:33 includes/gateways/paypal-standard.php:
|
5837 |
msgid "Nonce verification has failed"
|
5838 |
msgstr ""
|
5839 |
|
@@ -5843,48 +6419,139 @@ msgid ""
|
|
5843 |
"Payment data: %s"
|
5844 |
msgstr ""
|
5845 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
5846 |
#: includes/gateways/paypal-standard.php:57
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
5847 |
msgid "Payment creation failed before sending buyer to PayPal. Payment data: %s"
|
5848 |
msgstr ""
|
5849 |
|
5850 |
-
#: includes/gateways/paypal-standard.php:
|
5851 |
-
#: includes/gateways/paypal-standard.php:
|
5852 |
msgid "Invalid IPN verification response. IPN data: %s"
|
5853 |
msgstr ""
|
5854 |
|
5855 |
-
#: includes/gateways/paypal-standard.php:
|
5856 |
msgid "Invalid business email in IPN response. IPN data: %s"
|
5857 |
msgstr ""
|
5858 |
|
5859 |
-
#: includes/gateways/paypal-standard.php:
|
5860 |
msgid "Payment failed due to invalid PayPal business email."
|
5861 |
msgstr ""
|
5862 |
|
5863 |
-
#: includes/gateways/paypal-standard.php:
|
5864 |
msgid "Invalid currency in IPN response. IPN data: %s"
|
5865 |
msgstr ""
|
5866 |
|
5867 |
-
#: includes/gateways/paypal-standard.php:
|
5868 |
msgid "Payment failed due to invalid currency in PayPal IPN."
|
5869 |
msgstr ""
|
5870 |
|
5871 |
-
#: includes/gateways/paypal-standard.php:
|
5872 |
msgid "Invalid payment amount in IPN response. IPN data: %s"
|
5873 |
msgstr ""
|
5874 |
|
5875 |
-
#: includes/gateways/paypal-standard.php:
|
5876 |
msgid "Payment failed due to invalid amount in PayPal IPN."
|
5877 |
msgstr ""
|
5878 |
|
5879 |
-
#: includes/gateways/paypal-standard.php:
|
5880 |
msgid "Invalid purchase key in IPN response. IPN data: %s"
|
5881 |
msgstr ""
|
5882 |
|
5883 |
-
#: includes/gateways/paypal-standard.php:
|
5884 |
msgid "Payment failed due to invalid purchase key in PayPal IPN."
|
5885 |
msgstr ""
|
5886 |
|
5887 |
-
#: includes/gateways/paypal-standard.php:
|
5888 |
#: tests/helpers/class-helper-payment.php:131
|
5889 |
#: tests/helpers/class-helper-payment.php:234
|
5890 |
#: tests/helpers/class-helper-payment.php:342
|
@@ -5894,80 +6561,96 @@ msgstr ""
|
|
5894 |
msgid "PayPal Transaction ID: %s"
|
5895 |
msgstr ""
|
5896 |
|
5897 |
-
#: includes/gateways/paypal-standard.php:
|
5898 |
msgid "Payment made via eCheck and will clear automatically in 5-8 days"
|
5899 |
msgstr ""
|
5900 |
|
5901 |
-
#: includes/gateways/paypal-standard.php:
|
5902 |
msgid ""
|
5903 |
"Payment requires a confirmed customer address and must be accepted manually "
|
5904 |
"through PayPal"
|
5905 |
msgstr ""
|
5906 |
|
5907 |
-
#: includes/gateways/paypal-standard.php:
|
5908 |
msgid ""
|
5909 |
"Payment must be accepted manually through PayPal due to international "
|
5910 |
"account regulations"
|
5911 |
msgstr ""
|
5912 |
|
5913 |
-
#: includes/gateways/paypal-standard.php:
|
5914 |
msgid ""
|
5915 |
"Payment received in non-shop currency and must be accepted manually through "
|
5916 |
"PayPal"
|
5917 |
msgstr ""
|
5918 |
|
5919 |
-
#: includes/gateways/paypal-standard.php:
|
5920 |
msgid ""
|
5921 |
"Payment is being reviewed by PayPal staff as high-risk or in possible "
|
5922 |
"violation of government regulations"
|
5923 |
msgstr ""
|
5924 |
|
5925 |
-
#: includes/gateways/paypal-standard.php:
|
5926 |
msgid "Payment was sent to non-confirmed or non-registered email address."
|
5927 |
msgstr ""
|
5928 |
|
5929 |
-
#: includes/gateways/paypal-standard.php:
|
5930 |
msgid "PayPal account must be upgraded before this payment can be accepted"
|
5931 |
msgstr ""
|
5932 |
|
5933 |
-
#: includes/gateways/paypal-standard.php:
|
5934 |
msgid ""
|
5935 |
"PayPal account is not verified. Verify account in order to accept this "
|
5936 |
"payment"
|
5937 |
msgstr ""
|
5938 |
|
5939 |
-
#: includes/gateways/paypal-standard.php:
|
5940 |
msgid ""
|
5941 |
"Payment is pending for unknown reasons. Contact PayPal support for "
|
5942 |
"assistance"
|
5943 |
msgstr ""
|
5944 |
|
5945 |
-
#: includes/gateways/paypal-standard.php:
|
5946 |
msgid "Partial PayPal refund processed: %s"
|
5947 |
msgstr ""
|
5948 |
|
5949 |
-
#: includes/gateways/paypal-standard.php:
|
5950 |
msgid "PayPal Payment #%s Refunded for reason: %s"
|
5951 |
msgstr ""
|
5952 |
|
5953 |
-
#: includes/gateways/paypal-standard.php:
|
5954 |
msgid "PayPal Refund Transaction ID: %s"
|
5955 |
msgstr ""
|
5956 |
|
5957 |
-
#: includes/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
5958 |
#: templates/widget-cart-checkout.php:6 templates/widget-cart-empty.php:7
|
5959 |
msgid "Checkout"
|
5960 |
msgstr ""
|
5961 |
|
5962 |
-
#: includes/install.php:
|
5963 |
msgid "Purchase Confirmation"
|
5964 |
msgstr ""
|
5965 |
|
5966 |
-
#: includes/install.php:
|
5967 |
msgid "Thank you for your purchase! [edd_receipt]"
|
5968 |
msgstr ""
|
5969 |
|
5970 |
-
#: includes/install.php:
|
5971 |
msgid "Purchase History"
|
5972 |
msgstr ""
|
5973 |
|
@@ -5975,16 +6658,16 @@ msgstr ""
|
|
5975 |
msgid "The password you entered is incorrect"
|
5976 |
msgstr ""
|
5977 |
|
5978 |
-
#: includes/login-register.php:87 includes/process-purchase.php:
|
5979 |
msgid "The username you entered does not exist"
|
5980 |
msgstr ""
|
5981 |
|
5982 |
#: includes/login-register.php:140 includes/login-register.php:148
|
5983 |
-
#: includes/process-purchase.php:
|
5984 |
msgid "Invalid username"
|
5985 |
msgstr ""
|
5986 |
|
5987 |
-
#: includes/login-register.php:144 includes/process-purchase.php:
|
5988 |
msgid "Username already taken"
|
5989 |
msgstr ""
|
5990 |
|
@@ -5992,8 +6675,8 @@ msgstr ""
|
|
5992 |
msgid "Email address already taken"
|
5993 |
msgstr ""
|
5994 |
|
5995 |
-
#: includes/login-register.php:156 includes/process-purchase.php:
|
5996 |
-
#: includes/process-purchase.php:
|
5997 |
msgid "Invalid email"
|
5998 |
msgstr ""
|
5999 |
|
@@ -6145,18 +6828,14 @@ msgstr ""
|
|
6145 |
msgid "Status changed from %s to %s"
|
6146 |
msgstr ""
|
6147 |
|
6148 |
-
#: includes/payments/functions.php:
|
6149 |
msgid "Complete"
|
6150 |
msgstr ""
|
6151 |
|
6152 |
-
#: includes/payments/functions.php:
|
6153 |
msgid "EDD Bot"
|
6154 |
msgstr ""
|
6155 |
|
6156 |
-
#: includes/payments/functions.php:1578
|
6157 |
-
msgid "Delete this payment note"
|
6158 |
-
msgstr ""
|
6159 |
-
|
6160 |
#: includes/plugin-compatibility.php:73 tests/tests-plugin-compatibility.php:85
|
6161 |
msgid "No Caching on Checkout?"
|
6162 |
msgstr ""
|
@@ -6457,95 +7136,91 @@ msgstr ""
|
|
6457 |
msgid "Your cart is empty"
|
6458 |
msgstr ""
|
6459 |
|
6460 |
-
#: includes/process-purchase.php:
|
6461 |
msgid "The selected payment gateway is not enabled"
|
6462 |
msgstr ""
|
6463 |
|
6464 |
-
#: includes/process-purchase.php:
|
6465 |
msgid "One or more of the discounts you entered is invalid"
|
6466 |
msgstr ""
|
6467 |
|
6468 |
-
#: includes/process-purchase.php:
|
6469 |
msgid "You must agree to the terms of use"
|
6470 |
msgstr ""
|
6471 |
|
6472 |
-
#: includes/process-purchase.php:
|
6473 |
msgid "Please enter a valid email address"
|
6474 |
msgstr ""
|
6475 |
|
6476 |
-
#: includes/process-purchase.php:
|
6477 |
msgid "Please enter your first name"
|
6478 |
msgstr ""
|
6479 |
|
6480 |
-
#: includes/process-purchase.php:
|
6481 |
msgid "Please enter your zip / postal code"
|
6482 |
msgstr ""
|
6483 |
|
6484 |
-
#: includes/process-purchase.php:
|
6485 |
msgid "Please enter your billing city"
|
6486 |
msgstr ""
|
6487 |
|
6488 |
-
#: includes/process-purchase.php:
|
6489 |
msgid "Please select your billing country"
|
6490 |
msgstr ""
|
6491 |
|
6492 |
-
#: includes/process-purchase.php:
|
6493 |
msgid "Please enter billing state / province"
|
6494 |
msgstr ""
|
6495 |
|
6496 |
-
#: includes/process-purchase.php:
|
6497 |
msgid "The user information is invalid"
|
6498 |
msgstr ""
|
6499 |
|
6500 |
-
#: includes/process-purchase.php:
|
6501 |
msgid "Invalid username. Only lowercase letters (a-z) and numbers are allowed"
|
6502 |
msgstr ""
|
6503 |
|
6504 |
-
#: includes/process-purchase.php:
|
6505 |
msgid "You must register or login to complete your purchase"
|
6506 |
msgstr ""
|
6507 |
|
6508 |
-
#: includes/process-purchase.php:
|
6509 |
msgid "Email already used"
|
6510 |
msgstr ""
|
6511 |
|
6512 |
-
#: includes/process-purchase.php:
|
6513 |
msgid "Enter an email"
|
6514 |
msgstr ""
|
6515 |
|
6516 |
-
#: includes/process-purchase.php:
|
6517 |
msgid "Passwords don't match"
|
6518 |
msgstr ""
|
6519 |
|
6520 |
-
#: includes/process-purchase.php:
|
6521 |
msgid "Enter a password"
|
6522 |
msgstr ""
|
6523 |
|
6524 |
-
#: includes/process-purchase.php:
|
6525 |
msgid "Enter the password confirmation"
|
6526 |
msgstr ""
|
6527 |
|
6528 |
-
#: includes/process-purchase.php:
|
6529 |
msgid "You must login or register to complete your purchase"
|
6530 |
msgstr ""
|
6531 |
|
6532 |
-
#: includes/process-purchase.php:
|
6533 |
msgid "The password you entered is incorrect. %sReset Password%s"
|
6534 |
msgstr ""
|
6535 |
|
6536 |
-
#: includes/process-purchase.php:
|
6537 |
-
msgid "Lost Password"
|
6538 |
-
msgstr ""
|
6539 |
-
|
6540 |
-
#: includes/process-purchase.php:601
|
6541 |
msgid "You must be logged into an account to purchase"
|
6542 |
msgstr ""
|
6543 |
|
6544 |
-
#: includes/process-purchase.php:
|
6545 |
msgid "The zip / postal code you entered for your billing address is invalid"
|
6546 |
msgstr ""
|
6547 |
|
6548 |
-
#: includes/process-purchase.php:
|
6549 |
msgid "An internal error has occurred, please try again or contact support."
|
6550 |
msgstr ""
|
6551 |
|
@@ -6585,120 +7260,130 @@ msgstr ""
|
|
6585 |
msgid "Loading"
|
6586 |
msgstr ""
|
6587 |
|
6588 |
-
#: includes/scripts.php:
|
6589 |
msgid "Add New Download"
|
6590 |
msgstr ""
|
6591 |
|
6592 |
-
#: includes/scripts.php:
|
6593 |
msgid "Use This File"
|
6594 |
msgstr ""
|
6595 |
|
6596 |
-
#: includes/scripts.php:
|
6597 |
msgid "Sorry, not available for variable priced products."
|
6598 |
msgstr ""
|
6599 |
|
6600 |
-
#: includes/scripts.php:
|
6601 |
msgid "Are you sure you wish to delete this payment?"
|
6602 |
msgstr ""
|
6603 |
|
6604 |
-
#: includes/scripts.php:
|
6605 |
msgid "Are you sure you wish to delete this note?"
|
6606 |
msgstr ""
|
6607 |
|
6608 |
-
#: includes/scripts.php:
|
6609 |
msgid "Are you sure you wish to delete this tax rate?"
|
6610 |
msgstr ""
|
6611 |
|
6612 |
-
#: includes/scripts.php:
|
6613 |
msgid "Are you sure you wish to revoke this API key?"
|
6614 |
msgstr ""
|
6615 |
|
6616 |
-
#: includes/scripts.php:
|
6617 |
msgid "Are you sure you wish to regenerate this API key?"
|
6618 |
msgstr ""
|
6619 |
|
6620 |
-
#: includes/scripts.php:
|
6621 |
msgid "Are you sure you wish to resend the purchase receipt?"
|
6622 |
msgstr ""
|
6623 |
|
6624 |
-
#: includes/scripts.php:
|
6625 |
msgid "Copy these links to your clipboard and give them to your customer"
|
6626 |
msgstr ""
|
6627 |
|
6628 |
-
#: includes/scripts.php:
|
6629 |
msgid "Are you sure you wish to delete this %s?"
|
6630 |
msgstr ""
|
6631 |
|
6632 |
-
#: includes/scripts.php:
|
6633 |
msgid "You must have at least one price"
|
6634 |
msgstr ""
|
6635 |
|
6636 |
-
#: includes/scripts.php:
|
6637 |
msgid "You must have at least one field"
|
6638 |
msgstr ""
|
6639 |
|
6640 |
-
#: includes/scripts.php:
|
6641 |
msgid "Payments must contain at least one item"
|
6642 |
msgstr ""
|
6643 |
|
6644 |
-
#: includes/scripts.php:
|
6645 |
msgid "Choose one or more %s"
|
6646 |
msgstr ""
|
6647 |
|
6648 |
-
#: includes/scripts.php:
|
6649 |
msgid "Item price must be numeric"
|
6650 |
msgstr ""
|
6651 |
|
6652 |
-
#: includes/scripts.php:
|
6653 |
msgid "Quantity must be numeric"
|
6654 |
msgstr ""
|
6655 |
|
6656 |
-
#: includes/scripts.php:
|
6657 |
msgid "Type to search %s"
|
6658 |
msgstr ""
|
6659 |
|
6660 |
-
#: includes/scripts.php:
|
6661 |
msgid "You must choose a method."
|
6662 |
msgstr ""
|
6663 |
|
6664 |
-
#: includes/scripts.php:
|
6665 |
msgid "Required fields not completed."
|
6666 |
msgstr ""
|
6667 |
|
6668 |
-
#: includes/scripts.php:
|
6669 |
msgid ""
|
6670 |
"Are you sure you want to reset your store? This process is <strong><em>not "
|
6671 |
"reversible</em></strong>. Please be sure you have a recent backup."
|
6672 |
msgstr ""
|
6673 |
|
6674 |
-
#: includes/scripts.php:
|
6675 |
msgid "Type to search all %s"
|
6676 |
msgstr ""
|
6677 |
|
6678 |
-
#: includes/
|
|
|
|
|
|
|
|
|
|
|
|
|
6679 |
msgid "Purchase All Items"
|
6680 |
msgstr ""
|
6681 |
|
6682 |
-
#: includes/shortcodes.php:
|
6683 |
msgid "Sorry, trouble retrieving payment receipt."
|
6684 |
msgstr ""
|
6685 |
|
6686 |
-
#: includes/shortcodes.php:
|
6687 |
msgid "You must be logged in to view this payment receipt."
|
6688 |
msgstr ""
|
6689 |
|
6690 |
-
#: includes/shortcodes.php:
|
6691 |
msgid "The passwords you entered do not match. Please try again."
|
6692 |
msgstr ""
|
6693 |
|
6694 |
-
#: includes/shortcodes.php:
|
6695 |
msgid "The email you entered is invalid. Please enter a valid email."
|
6696 |
msgstr ""
|
6697 |
|
6698 |
-
#: includes/shortcodes.php:
|
6699 |
msgid "The email you entered belongs to another user. Please use another."
|
6700 |
msgstr ""
|
6701 |
|
|
|
|
|
|
|
|
|
6702 |
#: includes/template-functions.php:134
|
6703 |
msgid "Free"
|
6704 |
msgstr ""
|
@@ -6715,87 +7400,91 @@ msgstr ""
|
|
6715 |
msgid "Excluding %1$s% tax"
|
6716 |
msgstr ""
|
6717 |
|
6718 |
-
#: includes/template-functions.php:
|
6719 |
msgid "White"
|
6720 |
msgstr ""
|
6721 |
|
6722 |
-
#: includes/template-functions.php:
|
6723 |
msgid "Gray"
|
6724 |
msgstr ""
|
6725 |
|
6726 |
-
#: includes/template-functions.php:
|
6727 |
msgid "Blue"
|
6728 |
msgstr ""
|
6729 |
|
6730 |
-
#: includes/template-functions.php:
|
6731 |
msgid "Red"
|
6732 |
msgstr ""
|
6733 |
|
6734 |
-
#: includes/template-functions.php:
|
6735 |
msgid "Green"
|
6736 |
msgstr ""
|
6737 |
|
6738 |
-
#: includes/template-functions.php:
|
6739 |
msgid "Yellow"
|
6740 |
msgstr ""
|
6741 |
|
6742 |
-
#: includes/template-functions.php:
|
6743 |
msgid "Orange"
|
6744 |
msgstr ""
|
6745 |
|
6746 |
-
#: includes/template-functions.php:
|
6747 |
msgid "Dark Gray"
|
6748 |
msgstr ""
|
6749 |
|
6750 |
-
#: includes/template-functions.php:
|
6751 |
msgid "Inherit"
|
6752 |
msgstr ""
|
6753 |
|
6754 |
-
#: includes/template-functions.php:
|
6755 |
msgid "Button"
|
6756 |
msgstr ""
|
6757 |
|
6758 |
-
#: includes/template-functions.php:
|
6759 |
msgid "Plain Text"
|
6760 |
msgstr ""
|
6761 |
|
6762 |
-
#: includes/user-functions.php:
|
6763 |
msgid "[%s] New User Registration"
|
6764 |
msgstr ""
|
6765 |
|
6766 |
-
#: includes/user-functions.php:
|
6767 |
msgid "New user registration"
|
6768 |
msgstr ""
|
6769 |
|
6770 |
-
#: includes/user-functions.php:
|
6771 |
msgid "E-mail: %s"
|
6772 |
msgstr ""
|
6773 |
|
6774 |
-
#: includes/user-functions.php:
|
6775 |
msgid "[%s] Your username and password"
|
6776 |
msgstr ""
|
6777 |
|
6778 |
-
#: includes/user-functions.php:
|
6779 |
msgid "Your account info"
|
6780 |
msgstr ""
|
6781 |
|
6782 |
-
#: includes/user-functions.php:
|
6783 |
-
msgid "Password
|
6784 |
msgstr ""
|
6785 |
|
6786 |
-
#: includes/user-functions.php:
|
6787 |
-
msgid "
|
6788 |
msgstr ""
|
6789 |
|
6790 |
-
#: includes/user-functions.php:
|
|
|
|
|
|
|
|
|
6791 |
msgid "Click Here to Log In"
|
6792 |
msgstr ""
|
6793 |
|
6794 |
-
#: includes/user-functions.php:
|
6795 |
msgid "Verify your account"
|
6796 |
msgstr ""
|
6797 |
|
6798 |
-
#: includes/user-functions.php:
|
6799 |
msgid ""
|
6800 |
"Hello %s,\n"
|
6801 |
"\n"
|
@@ -6805,29 +7494,25 @@ msgid ""
|
|
6805 |
"Link missing? Visit the following URL: %s"
|
6806 |
msgstr ""
|
6807 |
|
6808 |
-
#: includes/user-functions.php:
|
6809 |
msgid ""
|
6810 |
"Sorry but your account verification link has expired. <a href=\"#\">Click "
|
6811 |
"here</a> to request a new verification URL."
|
6812 |
msgstr ""
|
6813 |
|
6814 |
-
#: includes/user-functions.php:
|
6815 |
-
msgid "Nonce verification failed."
|
6816 |
-
msgstr ""
|
6817 |
-
|
6818 |
-
#: includes/user-functions.php:820
|
6819 |
msgid "You must be logged in to verify your account."
|
6820 |
msgstr ""
|
6821 |
|
6822 |
-
#: includes/user-functions.php:
|
6823 |
msgid "Notice"
|
6824 |
msgstr ""
|
6825 |
|
6826 |
-
#: includes/user-functions.php:
|
6827 |
msgid "Your account has already been verified."
|
6828 |
msgstr ""
|
6829 |
|
6830 |
-
#: includes/user-functions.php:
|
6831 |
msgid "Invalid verification token provided."
|
6832 |
msgstr ""
|
6833 |
|
@@ -6919,14 +7604,6 @@ msgstr ""
|
|
6919 |
msgid "Item Price"
|
6920 |
msgstr ""
|
6921 |
|
6922 |
-
#: templates/checkout_cart.php:94 templates/shortcode-receipt.php:98
|
6923 |
-
msgid "Subtotal"
|
6924 |
-
msgstr ""
|
6925 |
-
|
6926 |
-
#: templates/checkout_cart.php:121
|
6927 |
-
msgid "Total"
|
6928 |
-
msgstr ""
|
6929 |
-
|
6930 |
#: templates/history-downloads.php:3 templates/history-purchases.php:3
|
6931 |
msgid "Your account has been successfully verified!"
|
6932 |
msgstr ""
|
@@ -6965,10 +7642,6 @@ msgstr ""
|
|
6965 |
msgid "Log into Your Account"
|
6966 |
msgstr ""
|
6967 |
|
6968 |
-
#: templates/shortcode-login.php:15 templates/shortcode-login.php:16
|
6969 |
-
msgid "Username or Email"
|
6970 |
-
msgstr ""
|
6971 |
-
|
6972 |
#: templates/shortcode-login.php:26
|
6973 |
msgid "Log In"
|
6974 |
msgstr ""
|
@@ -6981,59 +7654,63 @@ msgstr ""
|
|
6981 |
msgid "You are already logged in"
|
6982 |
msgstr ""
|
6983 |
|
6984 |
-
#: templates/shortcode-profile-editor.php:
|
6985 |
msgid "Saved cart"
|
6986 |
msgstr ""
|
6987 |
|
6988 |
-
#: templates/shortcode-profile-editor.php:
|
6989 |
msgid "You have a saved cart, <a href=\"%s\">click here</a> to restore it."
|
6990 |
msgstr ""
|
6991 |
|
6992 |
-
#: templates/shortcode-profile-editor.php:
|
6993 |
msgid "Your profile has been edited successfully."
|
6994 |
msgstr ""
|
6995 |
|
6996 |
-
#: templates/shortcode-profile-editor.php:
|
6997 |
msgid "Change your Name"
|
6998 |
msgstr ""
|
6999 |
|
7000 |
-
#: templates/shortcode-profile-editor.php:
|
7001 |
msgid "Display Name"
|
7002 |
msgstr ""
|
7003 |
|
7004 |
-
#: templates/shortcode-profile-editor.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
7005 |
msgid "Change your Billing Address"
|
7006 |
msgstr ""
|
7007 |
|
7008 |
-
#: templates/shortcode-profile-editor.php:
|
7009 |
msgid "Line 1"
|
7010 |
msgstr ""
|
7011 |
|
7012 |
-
#: templates/shortcode-profile-editor.php:
|
7013 |
msgid "Line 2"
|
7014 |
msgstr ""
|
7015 |
|
7016 |
-
#: templates/shortcode-profile-editor.php:
|
7017 |
msgid "Change your Password"
|
7018 |
msgstr ""
|
7019 |
|
7020 |
-
#: templates/shortcode-profile-editor.php:
|
7021 |
msgid "New Password"
|
7022 |
msgstr ""
|
7023 |
|
7024 |
-
#: templates/shortcode-profile-editor.php:
|
7025 |
msgid "Re-enter Password"
|
7026 |
msgstr ""
|
7027 |
|
7028 |
-
#: templates/shortcode-profile-editor.php:
|
7029 |
-
msgid "Please note after changing your password, you must log back in."
|
7030 |
-
msgstr ""
|
7031 |
-
|
7032 |
-
#: templates/shortcode-profile-editor.php:103
|
7033 |
msgid "Save Changes"
|
7034 |
msgstr ""
|
7035 |
|
7036 |
-
#: templates/shortcode-profile-editor.php:
|
7037 |
msgid "You need to login to edit your profile."
|
7038 |
msgstr ""
|
7039 |
|
@@ -7089,22 +7766,22 @@ msgstr ""
|
|
7089 |
msgid "The easiest way to sell digital products with WordPress."
|
7090 |
msgstr ""
|
7091 |
|
7092 |
-
#: includes/admin/payments/view-order-details.php:
|
7093 |
msgctxt "Address City"
|
7094 |
msgid "City:"
|
7095 |
msgstr ""
|
7096 |
|
7097 |
-
#: includes/admin/payments/view-order-details.php:
|
7098 |
msgctxt "Zip / Postal code of address"
|
7099 |
msgid "Zip / Postal Code:"
|
7100 |
msgstr ""
|
7101 |
|
7102 |
-
#: includes/admin/payments/view-order-details.php:
|
7103 |
msgctxt "Address country"
|
7104 |
msgid "Country:"
|
7105 |
msgstr ""
|
7106 |
|
7107 |
-
#: includes/admin/payments/view-order-details.php:
|
7108 |
msgctxt "State / province of address"
|
7109 |
msgid "State / Province:"
|
7110 |
msgstr ""
|
@@ -7144,7 +7821,7 @@ msgctxt "download post type name"
|
|
7144 |
msgid "%2$s"
|
7145 |
msgstr ""
|
7146 |
|
7147 |
-
#: includes/shortcodes.php:
|
7148 |
msgctxt "download post type name"
|
7149 |
msgid "No %s found"
|
7150 |
msgstr ""
|
2 |
# This file is distributed under the same license as the Easy Digital Downloads package.
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
+
"Project-Id-Version: Easy Digital Downloads 2.6\n"
|
6 |
"Report-Msgid-Bugs-To: https://easydigitaldownloads.com/\n"
|
7 |
+
"POT-Creation-Date: 2016-06-23 16:41:55+00:00\n"
|
8 |
"MIME-Version: 1.0\n"
|
9 |
"Content-Type: text/plain; charset=utf-8\n"
|
10 |
"Content-Transfer-Encoding: 8bit\n"
|
11 |
"PO-Revision-Date: 2016-MO-DA HO:MI+ZONE\n"
|
12 |
"Last-Translator: WP-Translations (http://wp-translations.org/)\n"
|
13 |
"Language-Team: WP-Translations <wpt@wp-translations.org>\n"
|
14 |
+
"X-Generator: grunt-wp-i18n 0.5.4\n"
|
15 |
"X-Poedit-KeywordsList: "
|
16 |
"__;_e;_x:1,2c;_ex:1,2c;_n:1,2;_nx:1,2,4c;_n_noop:1,2;_nx_noop:1,2,3c;esc_"
|
17 |
"attr__;esc_html__;esc_attr_e;esc_html_e;esc_attr_x:1,2c;esc_html_x:1,2c;\n"
|
24 |
"X-Poedit-Bookmarks: \n"
|
25 |
"X-Textdomain-Support: yes\n"
|
26 |
|
27 |
+
#: easy-digital-downloads.php:172 easy-digital-downloads.php:184
|
28 |
msgid "Cheatin’ huh?"
|
29 |
msgstr ""
|
30 |
|
38 |
"or %5$supdate now%6$s."
|
39 |
msgstr ""
|
40 |
|
41 |
+
#: includes/EDD_SL_Plugin_Updater.php:349
|
42 |
msgid "You do not have permission to install plugin updates"
|
43 |
msgstr ""
|
44 |
|
45 |
+
#: includes/EDD_SL_Plugin_Updater.php:349
|
46 |
+
#: includes/admin/customers/customer-actions.php:284
|
47 |
+
#: includes/admin/customers/customer-actions.php:328
|
48 |
+
#: includes/admin/customers/customer-actions.php:586
|
49 |
#: includes/admin/discounts/discount-actions.php:30
|
50 |
#: includes/admin/discounts/discount-actions.php:92
|
51 |
#: includes/admin/discounts/discount-actions.php:144
|
55 |
#: includes/admin/discounts/discount-actions.php:194
|
56 |
#: includes/admin/discounts/edit-discount.php:16
|
57 |
#: includes/admin/downloads/dashboard-columns.php:171
|
58 |
+
#: includes/admin/import/class-batch-import-downloads.php:65
|
59 |
+
#: includes/admin/import/class-batch-import-payments.php:76
|
60 |
+
#: includes/admin/import/class-batch-import.php:159
|
61 |
#: includes/admin/payments/actions.php:25
|
62 |
#: includes/admin/payments/actions.php:145
|
63 |
#: includes/admin/payments/actions.php:291
|
80 |
#: includes/admin/tools/class-edd-tools-recount-single-customer-stats.php:149
|
81 |
#: includes/admin/tools/class-edd-tools-recount-store-earnings.php:154
|
82 |
#: includes/admin/tools/class-edd-tools-reset-stats.php:180
|
83 |
+
#: includes/admin/tools.php:901 includes/admin/tools.php:907
|
84 |
+
#: includes/admin/upgrades/upgrade-functions.php:194
|
85 |
+
#: includes/admin/upgrades/upgrade-functions.php:510
|
86 |
+
#: includes/admin/upgrades/upgrade-functions.php:592
|
87 |
+
#: includes/admin/upgrades/upgrade-functions.php:703
|
88 |
+
#: includes/admin/upgrades/upgrade-functions.php:800
|
89 |
+
#: includes/admin/upgrades/upgrade-functions.php:874
|
90 |
+
#: includes/admin/upgrades/upgrade-functions.php:1002
|
91 |
+
#: includes/admin/upgrades/upgrade-functions.php:1087
|
92 |
+
#: includes/api/class-edd-api.php:1836 includes/api/class-edd-api.php:1841
|
93 |
+
#: includes/api/class-edd-api.php:1853 includes/api/class-edd-api.php:1855
|
94 |
+
#: includes/cart/functions.php:1178 includes/cart/functions.php:1195
|
95 |
#: includes/class-edd-license-handler.php:304
|
96 |
#: includes/deprecated-functions.php:517 includes/deprecated-functions.php:532
|
97 |
#: includes/deprecated-functions.php:542 includes/download-functions.php:1228
|
98 |
#: includes/emails/actions.php:49 includes/emails/template.php:245
|
99 |
#: includes/error-tracking.php:36 includes/gateways/functions.php:221
|
100 |
+
#: includes/gateways/manual.php:33 includes/gateways/paypal-standard.php:155
|
101 |
#: includes/process-download.php:254 includes/process-download.php:787
|
102 |
+
#: includes/query-filters.php:48 includes/user-functions.php:809
|
103 |
+
#: includes/user-functions.php:834 includes/user-functions.php:887
|
104 |
msgid "Error"
|
105 |
msgstr ""
|
106 |
|
132 |
msgstr ""
|
133 |
|
134 |
#: includes/admin/admin-pages.php:38
|
135 |
+
#: includes/admin/customers/class-customer-table.php:73
|
136 |
#: includes/admin/customers/customers.php:63
|
137 |
msgid "Customers"
|
138 |
msgstr ""
|
164 |
msgid "Easy Digital Download Info and Tools"
|
165 |
msgstr ""
|
166 |
|
167 |
+
#: includes/admin/admin-pages.php:42 includes/admin/customers/customers.php:613
|
168 |
msgid "Tools"
|
169 |
msgstr ""
|
170 |
|
174 |
|
175 |
#: includes/admin/admin-pages.php:43 includes/admin/plugins.php:58
|
176 |
#: includes/admin/settings/contextual-help.php:87
|
177 |
+
#: includes/admin/settings/register-settings.php:1142
|
178 |
msgid "Extensions"
|
179 |
msgstr ""
|
180 |
|
204 |
|
205 |
#: includes/admin/class-api-keys-table.php:176
|
206 |
#: includes/checkout/template.php:466 includes/checkout/template.php:472
|
207 |
+
#: includes/checkout/template.php:538 templates/shortcode-login.php:15
|
208 |
+
#: templates/shortcode-register.php:18
|
209 |
msgid "Username"
|
210 |
msgstr ""
|
211 |
|
348 |
msgid "User successfully verified"
|
349 |
msgstr ""
|
350 |
|
351 |
+
#: includes/admin/class-edd-notices.php:193
|
352 |
+
msgid "Customer email added"
|
353 |
+
msgstr ""
|
354 |
+
|
355 |
+
#: includes/admin/class-edd-notices.php:196
|
356 |
+
msgid "Customer email removed"
|
357 |
+
msgstr ""
|
358 |
+
|
359 |
+
#: includes/admin/class-edd-notices.php:199
|
360 |
+
msgid "Failed to remove customer email"
|
361 |
+
msgstr ""
|
362 |
+
|
363 |
+
#: includes/admin/class-edd-notices.php:202
|
364 |
+
msgid "Primary email updated for customer"
|
365 |
+
msgstr ""
|
366 |
+
|
367 |
+
#: includes/admin/class-edd-notices.php:205
|
368 |
+
msgid "Failed to set primary email"
|
369 |
+
msgstr ""
|
370 |
+
|
371 |
+
#: includes/admin/customers/class-customer-table.php:72
|
372 |
#: includes/admin/payments/class-payments-table.php:227
|
373 |
msgid "Customer"
|
374 |
msgstr ""
|
375 |
|
376 |
+
#: includes/admin/customers/class-customer-table.php:155
|
377 |
msgid "Unnamed Customer"
|
378 |
msgstr ""
|
379 |
|
380 |
+
#: includes/admin/customers/class-customer-table.php:159
|
381 |
msgid "View"
|
382 |
msgstr ""
|
383 |
|
384 |
+
#: includes/admin/customers/class-customer-table.php:160
|
385 |
msgid "Download log"
|
386 |
msgstr ""
|
387 |
|
388 |
+
#: includes/admin/customers/class-customer-table.php:161
|
389 |
#: includes/admin/discounts/class-discount-codes-table.php:221
|
390 |
#: includes/admin/discounts/class-discount-codes-table.php:289
|
391 |
#: includes/admin/payments/class-payments-table.php:323
|
392 |
#: includes/admin/payments/class-payments-table.php:395
|
393 |
+
#: includes/payments/functions.php:1596
|
394 |
msgid "Delete"
|
395 |
msgstr ""
|
396 |
|
397 |
+
#: includes/admin/customers/class-customer-table.php:165
|
398 |
msgid "(Pending Verification)"
|
399 |
msgstr ""
|
400 |
|
401 |
+
#: includes/admin/customers/class-customer-table.php:179
|
402 |
#: includes/admin/discounts/add-discount.php:23
|
403 |
#: includes/admin/discounts/class-discount-codes-table.php:145
|
404 |
#: includes/admin/discounts/edit-discount.php:37
|
410 |
msgid "Name"
|
411 |
msgstr ""
|
412 |
|
413 |
+
#: includes/admin/customers/class-customer-table.php:180
|
414 |
+
msgid "Primary Email"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
415 |
msgstr ""
|
416 |
|
417 |
+
#: includes/admin/customers/class-customer-table.php:181
|
418 |
msgid "Purchases"
|
419 |
msgstr ""
|
420 |
|
421 |
+
#: includes/admin/customers/class-customer-table.php:182
|
422 |
msgid "Total Spent"
|
423 |
msgstr ""
|
424 |
|
425 |
+
#: includes/admin/customers/class-customer-table.php:183
|
426 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:45
|
427 |
msgid "Date Created"
|
428 |
msgstr ""
|
429 |
|
430 |
#: includes/admin/customers/customer-actions.php:17
|
431 |
#: includes/admin/customers/customer-actions.php:169
|
432 |
+
#: includes/admin/customers/customer-actions.php:362
|
433 |
+
#: includes/admin/customers/customer-actions.php:517
|
434 |
msgid "You do not have permission to edit this customer."
|
435 |
msgstr ""
|
436 |
|
437 |
#: includes/admin/customers/customer-actions.php:29
|
438 |
+
#: includes/admin/customers/customer-actions.php:374
|
439 |
+
#: includes/admin/customers/customer-actions.php:442
|
440 |
+
#: includes/admin/customers/customer-actions.php:528
|
441 |
msgid "Cheatin' eh?!"
|
442 |
msgstr ""
|
443 |
|
453 |
msgid "The User ID %d does not exist. Please assign an existing user."
|
454 |
msgstr ""
|
455 |
|
456 |
+
#: includes/admin/customers/customer-actions.php:179
|
457 |
+
msgid "Email address is required."
|
458 |
msgstr ""
|
459 |
|
460 |
+
#: includes/admin/customers/customer-actions.php:181
|
461 |
+
msgid "Customer ID is required."
|
462 |
msgstr ""
|
463 |
|
464 |
+
#: includes/admin/customers/customer-actions.php:183
|
465 |
+
msgid "An error has occured. Please try again."
|
466 |
msgstr ""
|
467 |
|
468 |
+
#: includes/admin/customers/customer-actions.php:190
|
469 |
+
#: includes/user-functions.php:834
|
470 |
+
msgid "Nonce verification failed."
|
471 |
msgstr ""
|
472 |
|
473 |
+
#: includes/admin/customers/customer-actions.php:197
|
474 |
+
msgid "Invalid email address."
|
475 |
msgstr ""
|
476 |
|
477 |
+
#: includes/admin/customers/customer-actions.php:213
|
478 |
+
msgid "Email already assocaited with this customer."
|
479 |
+
msgstr ""
|
480 |
+
|
481 |
+
#: includes/admin/customers/customer-actions.php:220
|
482 |
+
msgid "Email address is already associated with another customer."
|
483 |
msgstr ""
|
484 |
|
485 |
+
#: includes/admin/customers/customer-actions.php:230
|
486 |
+
msgid "Email successfully added to customer."
|
487 |
+
msgstr ""
|
488 |
+
|
489 |
+
#: includes/admin/customers/customer-actions.php:284
|
490 |
+
#: includes/admin/customers/customer-actions.php:328
|
491 |
+
#: includes/admin/customers/customer-actions.php:586
|
492 |
+
#: includes/admin/import/import-functions.php:31
|
493 |
+
#: includes/admin/import/import-functions.php:98
|
494 |
#: includes/admin/reporting/export/export-actions.php:23
|
495 |
#: includes/admin/reporting/pdf-reports.php:33
|
496 |
+
#: includes/api/class-edd-api.php:1836
|
497 |
#: includes/class-edd-license-handler.php:304
|
498 |
msgid "Nonce verification failed"
|
499 |
msgstr ""
|
500 |
|
501 |
+
#: includes/admin/customers/customer-actions.php:378
|
502 |
+
msgid "A note is required"
|
503 |
+
msgstr ""
|
504 |
+
|
505 |
+
#: includes/admin/customers/customer-actions.php:429
|
506 |
+
msgid "You do not have permission to delete this customer."
|
507 |
+
msgstr ""
|
508 |
+
|
509 |
+
#: includes/admin/customers/customer-actions.php:446
|
510 |
+
msgid "Please confirm you want to delete this customer"
|
511 |
+
msgstr ""
|
512 |
+
|
513 |
+
#: includes/admin/customers/customer-actions.php:487
|
514 |
+
msgid "Error deleting customer"
|
515 |
+
msgstr ""
|
516 |
+
|
517 |
+
#: includes/admin/customers/customer-actions.php:494
|
518 |
+
msgid "Invalid Customer ID"
|
519 |
+
msgstr ""
|
520 |
+
|
521 |
+
#: includes/admin/customers/customer-actions.php:552
|
522 |
+
msgid "Failed to disconnect user from customer"
|
523 |
+
msgstr ""
|
524 |
+
|
525 |
#: includes/admin/customers/customer-functions.php:37
|
526 |
msgid "Customer Profile"
|
527 |
msgstr ""
|
535 |
msgstr ""
|
536 |
|
537 |
#: includes/admin/customers/customer-functions.php:55
|
538 |
+
#: includes/admin/customers/customers.php:587
|
539 |
msgid "Delete Customer"
|
540 |
msgstr ""
|
541 |
|
565 |
msgstr ""
|
566 |
|
567 |
#: includes/admin/customers/customers.php:115
|
568 |
+
#: includes/admin/payments/view-order-details.php:420
|
569 |
msgid "Customer Details"
|
570 |
msgstr ""
|
571 |
|
572 |
+
#: includes/admin/customers/customers.php:181
|
573 |
msgid "Edit Customer"
|
574 |
msgstr ""
|
575 |
|
576 |
+
#: includes/admin/customers/customers.php:207
|
577 |
msgid "Customer Address"
|
578 |
msgstr ""
|
579 |
|
580 |
+
#: includes/admin/customers/customers.php:218
|
581 |
msgid "Address 1"
|
582 |
msgstr ""
|
583 |
|
584 |
+
#: includes/admin/customers/customers.php:219
|
585 |
msgid "Address 2"
|
586 |
msgstr ""
|
587 |
|
588 |
+
#: includes/admin/customers/customers.php:220
|
589 |
#: includes/admin/reporting/class-export-payments.php:68
|
590 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:48
|
591 |
+
#: includes/admin/tools.php:564 includes/checkout/template.php:355
|
592 |
+
#: templates/shortcode-profile-editor.php:132
|
593 |
msgid "City"
|
594 |
msgstr ""
|
595 |
|
596 |
+
#: includes/admin/customers/customers.php:247
|
597 |
+
#: includes/admin/settings/register-settings.php:1832
|
598 |
+
#: includes/admin/tools.php:573 includes/checkout/template.php:417
|
599 |
+
#: templates/shortcode-profile-editor.php:145
|
600 |
msgid "State / Province"
|
601 |
msgstr ""
|
602 |
|
603 |
+
#: includes/admin/customers/customers.php:249
|
604 |
msgid "Postal"
|
605 |
msgstr ""
|
606 |
|
607 |
+
#: includes/admin/customers/customers.php:256
|
608 |
msgid "Customer Name"
|
609 |
msgstr ""
|
610 |
|
611 |
+
#: includes/admin/customers/customers.php:258
|
612 |
msgid "Customer Email"
|
613 |
msgstr ""
|
614 |
|
615 |
+
#: includes/admin/customers/customers.php:261
|
616 |
msgid "Customer since"
|
617 |
msgstr ""
|
618 |
|
619 |
+
#: includes/admin/customers/customers.php:286
|
620 |
msgid "User ID"
|
621 |
msgstr ""
|
622 |
|
623 |
+
#: includes/admin/customers/customers.php:290
|
624 |
#: includes/admin/reporting/class-export-payments.php:187
|
625 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:217
|
626 |
msgid "none"
|
627 |
msgstr ""
|
628 |
|
629 |
+
#: includes/admin/customers/customers.php:293
|
|
|
|
|
|
|
|
|
630 |
msgid "Disconnect User"
|
631 |
msgstr ""
|
632 |
|
633 |
+
#: includes/admin/customers/customers.php:305
|
634 |
msgid "Update Customer"
|
635 |
msgstr ""
|
636 |
|
637 |
+
#: includes/admin/customers/customers.php:306
|
638 |
+
#: includes/admin/customers/customers.php:588
|
639 |
+
#: includes/admin/payments/view-order-details.php:454
|
640 |
+
#: includes/admin/thickbox.php:131 includes/class-edd-html-elements.php:586
|
641 |
msgid "Cancel"
|
642 |
msgstr ""
|
643 |
|
644 |
+
#: includes/admin/customers/customers.php:319
|
|
|
|
|
|
|
|
|
645 |
msgid "%d Completed Sale"
|
646 |
msgid_plural "%d Completed Sales"
|
647 |
msgstr[0] ""
|
648 |
msgstr[1] ""
|
649 |
|
650 |
+
#: includes/admin/customers/customers.php:324
|
651 |
msgid "Lifetime Value"
|
652 |
msgstr ""
|
653 |
|
654 |
+
#: includes/admin/customers/customers.php:337
|
655 |
+
msgid "Customer Emails"
|
656 |
+
msgstr ""
|
657 |
+
|
658 |
+
#: includes/admin/customers/customers.php:338
|
659 |
+
msgid ""
|
660 |
+
"This customer can use any of the emails listed here when making new "
|
661 |
+
"purchases."
|
662 |
+
msgstr ""
|
663 |
+
|
664 |
+
#: includes/admin/customers/customers.php:356
|
665 |
+
#: includes/admin/payments/class-payments-table.php:223
|
666 |
+
#: includes/admin/reporting/class-export-customers.php:68
|
667 |
+
#: includes/admin/reporting/class-export-customers.php:79
|
668 |
+
#: includes/admin/reporting/class-export-payments.php:63
|
669 |
+
#: includes/admin/reporting/export/class-batch-export-customers.php:44
|
670 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:42
|
671 |
+
#: includes/admin/tools.php:375 templates/shortcode-register.php:23
|
672 |
+
msgid "Email"
|
673 |
+
msgstr ""
|
674 |
+
|
675 |
+
#: includes/admin/customers/customers.php:357
|
676 |
+
#: includes/admin/customers/customers.php:416
|
677 |
+
#: includes/admin/customers/customers.php:449 templates/checkout_cart.php:13
|
678 |
+
msgid "Actions"
|
679 |
+
msgstr ""
|
680 |
+
|
681 |
+
#: includes/admin/customers/customers.php:377
|
682 |
+
#: includes/admin/customers/customers.php:390
|
683 |
+
msgid "Make Primary"
|
684 |
+
msgstr ""
|
685 |
+
|
686 |
+
#: includes/admin/customers/customers.php:379
|
687 |
+
#: includes/admin/payments/view-order-details.php:360
|
688 |
+
#: includes/admin/settings/register-settings.php:1835 includes/scripts.php:216
|
689 |
+
#: templates/checkout_cart.php:57 templates/checkout_cart.php:75
|
690 |
+
#: templates/shortcode-profile-editor.php:114
|
691 |
+
msgid "Remove"
|
692 |
+
msgstr ""
|
693 |
+
|
694 |
+
#: includes/admin/customers/customers.php:389
|
695 |
+
#: includes/checkout/template.php:180
|
696 |
+
msgid "Email Address"
|
697 |
+
msgstr ""
|
698 |
+
|
699 |
+
#: includes/admin/customers/customers.php:391
|
700 |
+
msgid "Add Email"
|
701 |
+
msgstr ""
|
702 |
+
|
703 |
+
#: includes/admin/customers/customers.php:398
|
704 |
+
msgid "No Emails Found"
|
705 |
+
msgstr ""
|
706 |
+
|
707 |
+
#: includes/admin/customers/customers.php:403
|
708 |
msgid "Recent Payments"
|
709 |
msgstr ""
|
710 |
|
711 |
+
#: includes/admin/customers/customers.php:412
|
712 |
#: includes/admin/downloads/metabox.php:346
|
713 |
+
#: includes/admin/downloads/metabox.php:615
|
714 |
#: includes/admin/payments/class-payments-table.php:222
|
715 |
#: includes/admin/reporting/class-export-payments.php:61
|
716 |
#: includes/admin/reporting/class-export.php:69
|
717 |
#: includes/admin/reporting/export/class-batch-export-customers.php:42
|
718 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:42
|
|
|
719 |
#: templates/history-purchases.php:18
|
720 |
msgid "ID"
|
721 |
msgstr ""
|
722 |
|
723 |
+
#: includes/admin/customers/customers.php:413
|
724 |
#: includes/admin/discounts/add-discount.php:56
|
725 |
#: includes/admin/discounts/class-discount-codes-table.php:147
|
726 |
#: includes/admin/discounts/edit-discount.php:70
|
727 |
#: includes/admin/payments/class-payments-table.php:225
|
728 |
#: includes/admin/reporting/class-export-payments.php:74
|
729 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:55
|
730 |
#: templates/history-purchases.php:20
|
731 |
msgid "Amount"
|
732 |
msgstr ""
|
733 |
|
734 |
+
#: includes/admin/customers/customers.php:414
|
735 |
#: includes/admin/downloads/dashboard-columns.php:37
|
736 |
#: includes/admin/payments/class-payments-table.php:226
|
737 |
#: includes/admin/reporting/class-api-requests-logs-list-table.php:94
|
741 |
#: includes/admin/reporting/class-export.php:70
|
742 |
#: includes/admin/reporting/class-file-downloads-logs-list-table.php:150
|
743 |
#: includes/admin/reporting/class-gateway-error-logs-list-table.php:134
|
744 |
+
#: includes/admin/reporting/class-sales-logs-list-table.php:136
|
745 |
#: includes/admin/reporting/export/class-batch-export-file-downloads.php:42
|
746 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:61
|
747 |
+
#: includes/admin/tools.php:465 templates/history-purchases.php:19
|
748 |
+
#: templates/shortcode-receipt.php:59
|
749 |
msgid "Date"
|
750 |
msgstr ""
|
751 |
|
752 |
+
#: includes/admin/customers/customers.php:415
|
753 |
#: includes/admin/discounts/class-discount-codes-table.php:151
|
754 |
#: includes/admin/discounts/edit-discount.php:175
|
755 |
#: includes/admin/payments/class-payments-table.php:228
|
756 |
#: includes/admin/reporting/class-export-payments.php:82
|
757 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:49
|
758 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:66
|
759 |
+
#: includes/admin/tools.php:492
|
760 |
msgid "Status"
|
761 |
msgstr ""
|
762 |
|
763 |
+
#: includes/admin/customers/customers.php:429
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
764 |
msgid "View Details"
|
765 |
msgstr ""
|
766 |
|
767 |
+
#: includes/admin/customers/customers.php:436
|
768 |
msgid "No Payments Found"
|
769 |
msgstr ""
|
770 |
|
771 |
+
#: includes/admin/customers/customers.php:441
|
772 |
+
#: includes/admin/payments/view-order-details.php:293
|
773 |
msgid "Purchased %s"
|
774 |
msgstr ""
|
775 |
|
776 |
+
#: includes/admin/customers/customers.php:459 includes/admin/welcome.php:492
|
|
|
777 |
msgid "View %s"
|
778 |
msgstr ""
|
779 |
|
780 |
+
#: includes/admin/customers/customers.php:465
|
781 |
msgid "No %s Found"
|
782 |
msgstr ""
|
783 |
|
784 |
+
#: includes/admin/customers/customers.php:501
|
785 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:57
|
786 |
msgid "Notes"
|
787 |
msgstr ""
|
788 |
|
789 |
+
#: includes/admin/customers/customers.php:539
|
790 |
msgid "No Customer Notes"
|
791 |
msgstr ""
|
792 |
|
793 |
+
#: includes/admin/customers/customers.php:572
|
794 |
msgid "Are you sure you want to delete this customer?"
|
795 |
msgstr ""
|
796 |
|
797 |
+
#: includes/admin/customers/customers.php:577
|
798 |
msgid "Delete all associated payments and records?"
|
799 |
msgstr ""
|
800 |
|
801 |
+
#: includes/admin/customers/customers.php:616 includes/admin/tools.php:143
|
802 |
msgid "Recount Customer Stats"
|
803 |
msgstr ""
|
804 |
|
805 |
+
#: includes/admin/customers/customers.php:617
|
806 |
msgid ""
|
807 |
"Use this tool to recalculate the purchase count and total value of the "
|
808 |
"customer."
|
809 |
msgstr ""
|
810 |
|
811 |
+
#: includes/admin/customers/customers.php:624 includes/admin/tools.php:130
|
812 |
msgid "Recount Stats"
|
813 |
msgstr ""
|
814 |
|
815 |
+
#: includes/admin/customers/customers.php:654
|
816 |
msgid "This customer's user account is pending verification."
|
817 |
msgstr ""
|
818 |
|
819 |
+
#: includes/admin/customers/customers.php:656
|
|
|
|
|
|
|
|
|
820 |
msgid "Verify account."
|
821 |
msgstr ""
|
822 |
|
835 |
#: includes/admin/reporting/class-download-reports-table.php:112
|
836 |
#: includes/admin/reporting/class-export-earnings.php:64
|
837 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:59
|
838 |
+
#: includes/admin/reporting/graphing.php:257
|
839 |
+
#: includes/admin/reporting/graphing.php:591
|
840 |
#: includes/admin/reporting/pdf-reports.php:206
|
841 |
#: includes/admin/reporting/reports.php:54
|
842 |
msgid "Earnings"
|
850 |
msgstr[1] ""
|
851 |
|
852 |
#: includes/admin/dashboard-widgets.php:80
|
853 |
+
#: includes/admin/reporting/graphing.php:632 includes/class-edd-stats.php:89
|
854 |
msgid "Last Month"
|
855 |
msgstr ""
|
856 |
|
857 |
#: includes/admin/dashboard-widgets.php:105
|
858 |
+
#: includes/admin/reporting/graphing.php:627 includes/class-edd-stats.php:84
|
859 |
msgid "Today"
|
860 |
msgstr ""
|
861 |
|
864 |
#: includes/admin/reporting/class-download-reports-table.php:111
|
865 |
#: includes/admin/reporting/class-export-earnings.php:63
|
866 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:58
|
867 |
+
#: includes/admin/reporting/graphing.php:258
|
868 |
+
#: includes/admin/reporting/graphing.php:592
|
869 |
#: includes/admin/reporting/logs.php:145
|
870 |
#: includes/admin/reporting/pdf-reports.php:223
|
871 |
msgid "Sales"
|
877 |
|
878 |
#: includes/admin/dashboard-widgets.php:138
|
879 |
#: includes/admin/reporting/class-categories-reports-table.php:85
|
880 |
+
#: includes/admin/tools.php:792
|
881 |
msgid "Total Earnings"
|
882 |
msgstr ""
|
883 |
|
895 |
msgid "View All"
|
896 |
msgstr ""
|
897 |
|
|
|
|
|
|
|
|
|
|
|
898 |
#: includes/admin/discounts/add-discount.php:15 includes/post-types.php:106
|
899 |
msgid "Add New Discount"
|
900 |
msgstr ""
|
985 |
|
986 |
#: includes/admin/discounts/add-discount.php:97
|
987 |
#: includes/admin/discounts/edit-discount.php:112
|
988 |
+
msgid ""
|
989 |
+
"Select %s relevant to this discount. If left blank, this discount can be "
|
990 |
+
"used on any product."
|
991 |
msgstr ""
|
992 |
|
993 |
#: includes/admin/discounts/add-discount.php:103
|
1066 |
#: includes/admin/discounts/class-discount-codes-table.php:127
|
1067 |
#: includes/admin/payments/class-payments-table.php:200
|
1068 |
#: includes/admin/reporting/class-file-downloads-logs-list-table.php:348
|
1069 |
+
#: includes/admin/reporting/class-sales-logs-list-table.php:291
|
1070 |
msgid "All"
|
1071 |
msgstr ""
|
1072 |
|
1154 |
|
1155 |
#: includes/admin/discounts/contextual-help.php:38
|
1156 |
#: includes/admin/settings/contextual-help.php:42
|
1157 |
+
#: includes/admin/settings/register-settings.php:1135
|
1158 |
#: includes/admin/tools.php:68
|
1159 |
msgid "General"
|
1160 |
msgstr ""
|
1489 |
msgid "Set ID %s as default price"
|
1490 |
msgstr ""
|
1491 |
|
1492 |
+
#: includes/admin/downloads/metabox.php:455
|
1493 |
+
msgid "Remove price option %s"
|
1494 |
+
msgstr ""
|
1495 |
+
|
1496 |
#: includes/admin/downloads/metabox.php:474
|
1497 |
msgid "Product Type Options:"
|
1498 |
msgstr ""
|
1501 |
msgid "Select a product type"
|
1502 |
msgstr ""
|
1503 |
|
1504 |
+
#: includes/admin/downloads/metabox.php:486
|
1505 |
+
msgid ""
|
1506 |
+
"<strong>Product Type</strong>: Sell this item as a single product, or use "
|
1507 |
+
"the Bundle type to sell a collection of products."
|
1508 |
+
msgstr ""
|
1509 |
+
|
1510 |
+
#: includes/admin/downloads/metabox.php:509
|
1511 |
msgid "Bundled %s:"
|
1512 |
msgstr ""
|
1513 |
|
1514 |
+
#: includes/admin/downloads/metabox.php:536
|
1515 |
+
msgid "Remove bundle option %s"
|
1516 |
+
msgstr ""
|
1517 |
+
|
1518 |
+
#: includes/admin/downloads/metabox.php:560
|
1519 |
+
msgid "Remove bundle option"
|
1520 |
+
msgstr ""
|
1521 |
+
|
1522 |
+
#: includes/admin/downloads/metabox.php:567
|
1523 |
+
#: includes/admin/downloads/metabox.php:645
|
1524 |
msgid "Add New File"
|
1525 |
msgstr ""
|
1526 |
|
1527 |
+
#: includes/admin/downloads/metabox.php:599
|
1528 |
msgid "File Downloads:"
|
1529 |
msgstr ""
|
1530 |
|
1531 |
+
#: includes/admin/downloads/metabox.php:609
|
1532 |
+
#: includes/admin/downloads/metabox.php:694
|
1533 |
msgid "File Name"
|
1534 |
msgstr ""
|
1535 |
|
1536 |
+
#: includes/admin/downloads/metabox.php:610
|
1537 |
msgid "File URL"
|
1538 |
msgstr ""
|
1539 |
|
1540 |
+
#: includes/admin/downloads/metabox.php:612
|
1541 |
msgid "Price Assignment"
|
1542 |
msgstr ""
|
1543 |
|
1544 |
+
#: includes/admin/downloads/metabox.php:613
|
1545 |
+
msgid ""
|
1546 |
+
"<strong>Price Assignment</strong>: With variable pricing enabled, you can "
|
1547 |
+
"choose to allow certain price variations access to specific files, or allow "
|
1548 |
+
"all price variations to access a file."
|
1549 |
+
msgstr ""
|
1550 |
+
|
1551 |
+
#: includes/admin/downloads/metabox.php:704
|
1552 |
msgid "Upload or enter the file URL"
|
1553 |
msgstr ""
|
1554 |
|
1555 |
+
#: includes/admin/downloads/metabox.php:709
|
1556 |
msgid "Insert File"
|
1557 |
msgstr ""
|
1558 |
|
1559 |
+
#: includes/admin/downloads/metabox.php:709
|
1560 |
msgid "Insert"
|
1561 |
msgstr ""
|
1562 |
|
1563 |
+
#: includes/admin/downloads/metabox.php:709
|
1564 |
msgid "Upload a File"
|
1565 |
msgstr ""
|
1566 |
|
1567 |
+
#: includes/admin/downloads/metabox.php:741
|
1568 |
+
msgid "Remove file option %s"
|
1569 |
+
msgstr ""
|
1570 |
+
|
1571 |
+
#: includes/admin/downloads/metabox.php:764
|
1572 |
msgid "Insert into %s"
|
1573 |
msgstr ""
|
1574 |
|
1575 |
+
#: includes/admin/downloads/metabox.php:790
|
1576 |
msgid "File Download Limit:"
|
1577 |
msgstr ""
|
1578 |
|
1579 |
+
#: includes/admin/downloads/metabox.php:797
|
1580 |
msgid "Leave blank for global setting or 0 for unlimited"
|
1581 |
msgstr ""
|
1582 |
|
1583 |
+
#: includes/admin/downloads/metabox.php:799
|
1584 |
+
msgid ""
|
1585 |
+
"<strong>File Download Limit</strong>: Limit the number of times a customer "
|
1586 |
+
"who purchased this product can access their download links."
|
1587 |
+
msgstr ""
|
1588 |
+
|
1589 |
+
#: includes/admin/downloads/metabox.php:821
|
1590 |
msgid "Ignore Tax:"
|
1591 |
msgstr ""
|
1592 |
|
1593 |
+
#: includes/admin/downloads/metabox.php:827
|
1594 |
msgid "Mark this product as exclusive of tax"
|
1595 |
msgstr ""
|
1596 |
|
1597 |
+
#: includes/admin/downloads/metabox.php:847
|
1598 |
+
#: includes/admin/settings/register-settings.php:759
|
1599 |
+
#: includes/admin/thickbox.php:58 includes/checkout/template.php:844
|
1600 |
#: includes/scripts.php:60 includes/shortcodes.php:49
|
1601 |
#: includes/template-functions.php:67
|
1602 |
msgid "Purchase"
|
1603 |
msgstr ""
|
1604 |
|
1605 |
+
#: includes/admin/downloads/metabox.php:854
|
1606 |
msgid "Purchase Shortcode:"
|
1607 |
msgstr ""
|
1608 |
|
1609 |
+
#: includes/admin/downloads/metabox.php:855
|
1610 |
+
msgid ""
|
1611 |
+
"<strong>Purchse Shortcode</strong>: Use this shortcode to output a purchase "
|
1612 |
+
"link for this product in the location of your choosing."
|
1613 |
msgstr ""
|
1614 |
|
1615 |
#: includes/admin/downloads/metabox.php:876
|
1616 |
+
msgid "Accounting Options:"
|
1617 |
+
msgstr ""
|
1618 |
+
|
1619 |
+
#: includes/admin/downloads/metabox.php:884
|
1620 |
msgid "Enter an SKU for this %s."
|
1621 |
msgstr ""
|
1622 |
|
1623 |
+
#: includes/admin/downloads/metabox.php:903
|
1624 |
msgid "Button Options:"
|
1625 |
msgstr ""
|
1626 |
|
1627 |
+
#: includes/admin/downloads/metabox.php:910
|
1628 |
msgid "Disable the automatic output of the purchase button"
|
1629 |
msgstr ""
|
1630 |
|
1631 |
#: includes/admin/downloads/metabox.php:911
|
1632 |
+
msgid ""
|
1633 |
+
"<strong>Automatic Output</strong>: By default, the purchase buttons will be "
|
1634 |
+
"displayed at the bottom of the download, when disabled you will need to use "
|
1635 |
+
"the Purchase link shortcode below to output the ability to buy the product "
|
1636 |
+
"where you prefer."
|
1637 |
+
msgstr ""
|
1638 |
+
|
1639 |
+
#: includes/admin/downloads/metabox.php:920
|
1640 |
+
#: includes/admin/settings/register-settings.php:766
|
1641 |
+
#: includes/admin/thickbox.php:96
|
1642 |
msgid "Add to Cart"
|
1643 |
msgstr ""
|
1644 |
|
1645 |
+
#: includes/admin/downloads/metabox.php:921
|
1646 |
+
#: includes/admin/settings/register-settings.php:773 includes/shortcodes.php:47
|
1647 |
#: includes/template-functions.php:67
|
1648 |
msgid "Buy Now"
|
1649 |
msgstr ""
|
1650 |
|
1651 |
+
#: includes/admin/downloads/metabox.php:927
|
1652 |
msgid "Purchase button behavior"
|
1653 |
msgstr ""
|
1654 |
|
1655 |
+
#: includes/admin/downloads/metabox.php:928
|
1656 |
+
msgid ""
|
1657 |
+
"<strong>Button Behavior</strong>: Add to Cart buttons follow a traditional "
|
1658 |
+
"eCommerce flow. A Buy Now button bypasses most of the process, taking the "
|
1659 |
+
"customer directly from button click to payment, greatly speeding up the "
|
1660 |
+
"process of getting the product."
|
1661 |
+
msgstr ""
|
1662 |
+
|
1663 |
+
#: includes/admin/downloads/metabox.php:965
|
1664 |
msgid ""
|
1665 |
"Special notes or instructions for this product. These notes will be added "
|
1666 |
"to the purchase receipt."
|
1667 |
msgstr ""
|
1668 |
|
1669 |
+
#: includes/admin/downloads/metabox.php:992
|
1670 |
msgid "Sales:"
|
1671 |
msgstr ""
|
1672 |
|
1673 |
+
#: includes/admin/downloads/metabox.php:997
|
1674 |
msgid "Earnings:"
|
1675 |
msgstr ""
|
1676 |
|
1677 |
+
#: includes/admin/downloads/metabox.php:1004
|
1678 |
msgid "View File Download Log"
|
1679 |
msgstr ""
|
1680 |
|
1681 |
+
#: includes/admin/import/class-batch-import-downloads.php:65
|
1682 |
+
#: includes/admin/import/class-batch-import-payments.php:76
|
1683 |
+
#: includes/admin/import/class-batch-import.php:159
|
1684 |
+
msgid "You do not have permission to import data."
|
1685 |
+
msgstr ""
|
1686 |
+
|
1687 |
+
#: includes/admin/import/class-batch-import-payments.php:269
|
1688 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:53
|
1689 |
+
msgid "Products (Raw)"
|
1690 |
+
msgstr ""
|
1691 |
+
|
1692 |
+
#: includes/admin/import/class-batch-import-payments.php:580
|
1693 |
+
msgid "payments"
|
1694 |
+
msgstr ""
|
1695 |
+
|
1696 |
+
#: includes/admin/import/import-functions.php:35
|
1697 |
+
#: includes/admin/import/import-functions.php:102
|
1698 |
+
msgid "Missing import parameters. Import class must be specified."
|
1699 |
+
msgstr ""
|
1700 |
+
|
1701 |
+
#: includes/admin/import/import-functions.php:39
|
1702 |
+
msgid "Missing import file. Please provide an import file."
|
1703 |
+
msgstr ""
|
1704 |
+
|
1705 |
+
#: includes/admin/import/import-functions.php:43
|
1706 |
+
msgid "The file you uploaded does not appear to be a CSV file."
|
1707 |
+
msgstr ""
|
1708 |
+
|
1709 |
+
#: includes/admin/import/import-functions.php:47
|
1710 |
+
#: includes/admin/import/import-functions.php:106
|
1711 |
+
msgid "Something went wrong during the upload process, please try again."
|
1712 |
+
msgstr ""
|
1713 |
+
|
1714 |
+
#: includes/admin/import/import-functions.php:60
|
1715 |
+
#: includes/admin/import/import-functions.php:117
|
1716 |
+
msgid "You do not have permission to import data"
|
1717 |
+
msgstr ""
|
1718 |
+
|
1719 |
+
#: includes/admin/import/import-functions.php:143
|
1720 |
+
msgid "No data found for import parameters"
|
1721 |
+
msgstr ""
|
1722 |
+
|
1723 |
+
#: includes/admin/import/import-functions.php:151
|
1724 |
+
msgid "Import complete! <a href=\"%s\">View imported %s</a>."
|
1725 |
+
msgstr ""
|
1726 |
+
|
1727 |
#: includes/admin/payments/actions.php:25
|
1728 |
#: includes/admin/payments/actions.php:291
|
1729 |
#: includes/admin/payments/actions.php:307
|
1766 |
msgstr ""
|
1767 |
|
1768 |
#: includes/admin/payments/class-payments-table.php:202
|
1769 |
+
#: includes/payments/functions.php:639
|
1770 |
msgid "Pending"
|
1771 |
msgstr ""
|
1772 |
|
1773 |
#: includes/admin/payments/class-payments-table.php:203
|
1774 |
+
#: includes/payments/functions.php:641
|
1775 |
msgid "Refunded"
|
1776 |
msgstr ""
|
1777 |
|
1778 |
#: includes/admin/payments/class-payments-table.php:204
|
1779 |
+
#: includes/payments/functions.php:644
|
1780 |
msgid "Revoked"
|
1781 |
msgstr ""
|
1782 |
|
1783 |
#: includes/admin/payments/class-payments-table.php:205
|
1784 |
+
#: includes/payments/functions.php:642
|
1785 |
msgid "Failed"
|
1786 |
msgstr ""
|
1787 |
|
1788 |
#: includes/admin/payments/class-payments-table.php:206
|
1789 |
+
#: includes/payments/functions.php:643
|
1790 |
msgid "Abandoned"
|
1791 |
msgstr ""
|
1792 |
|
1974 |
msgid "Status:"
|
1975 |
msgstr ""
|
1976 |
|
1977 |
+
#: includes/admin/payments/view-order-details.php:83
|
1978 |
+
msgid ""
|
1979 |
+
"<strong>Pending</strong>: payment is still processing or was abandoned by "
|
1980 |
+
"customer. Successful payments will be marked as Complete automatically once "
|
1981 |
+
"processing is finalized."
|
1982 |
+
msgstr ""
|
1983 |
+
|
1984 |
+
#: includes/admin/payments/view-order-details.php:84
|
1985 |
+
msgid "<strong>Complete</strong>: all processing is completed for this purchase."
|
1986 |
+
msgstr ""
|
1987 |
+
|
1988 |
#: includes/admin/payments/view-order-details.php:85
|
1989 |
+
msgid ""
|
1990 |
+
"<strong>Revoked</strong>: access to purchased items is disabled, perhaps "
|
1991 |
+
"due to policy violation or fraud."
|
1992 |
+
msgstr ""
|
1993 |
+
|
1994 |
+
#: includes/admin/payments/view-order-details.php:86
|
1995 |
+
msgid ""
|
1996 |
+
"<strong>Refunded</strong>: the purchase amount is returned to the customer "
|
1997 |
+
"and access to items is disabled."
|
1998 |
+
msgstr ""
|
1999 |
+
|
2000 |
+
#: includes/admin/payments/view-order-details.php:87
|
2001 |
+
msgid ""
|
2002 |
+
"<strong>Abandoned</strong>: the purchase attempt was not completed by the "
|
2003 |
+
"customer."
|
2004 |
+
msgstr ""
|
2005 |
+
|
2006 |
+
#: includes/admin/payments/view-order-details.php:88
|
2007 |
+
msgid ""
|
2008 |
+
"<strong>Failed</strong>: customer clicked Cancel before completing the "
|
2009 |
+
"purchase."
|
2010 |
+
msgstr ""
|
2011 |
+
|
2012 |
+
#: includes/admin/payments/view-order-details.php:97
|
2013 |
msgid "Date:"
|
2014 |
msgstr ""
|
2015 |
|
2016 |
+
#: includes/admin/payments/view-order-details.php:104
|
2017 |
msgid "Time:"
|
2018 |
msgstr ""
|
2019 |
|
2020 |
+
#: includes/admin/payments/view-order-details.php:114
|
2021 |
#: includes/admin/reporting/class-export-payments.php:76
|
2022 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:57
|
2023 |
msgid "Discount Code"
|
2024 |
msgstr ""
|
2025 |
|
2026 |
+
#: includes/admin/payments/view-order-details.php:115
|
2027 |
+
#: includes/admin/settings/register-settings.php:730
|
2028 |
msgid "None"
|
2029 |
msgstr ""
|
2030 |
|
2031 |
+
#: includes/admin/payments/view-order-details.php:123
|
2032 |
#: templates/shortcode-receipt.php:66
|
2033 |
msgid "Fees"
|
2034 |
msgstr ""
|
2035 |
|
2036 |
+
#: includes/admin/payments/view-order-details.php:135
|
2037 |
#: includes/admin/reporting/class-export-payments.php:75
|
2038 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:56
|
2039 |
+
#: includes/admin/tools.php:510 templates/checkout_cart.php:120
|
2040 |
+
#: templates/shortcode-receipt.php:90
|
2041 |
msgid "Tax"
|
2042 |
msgstr ""
|
2043 |
|
2044 |
+
#: includes/admin/payments/view-order-details.php:143
|
2045 |
#: templates/shortcode-receipt.php:105
|
2046 |
msgid "Total Price"
|
2047 |
msgstr ""
|
2048 |
|
2049 |
+
#: includes/admin/payments/view-order-details.php:150
|
2050 |
msgid "Recalculate Totals"
|
2051 |
msgstr ""
|
2052 |
|
2053 |
+
#: includes/admin/payments/view-order-details.php:151
|
2054 |
msgid "Recalculate"
|
2055 |
msgstr ""
|
2056 |
|
2057 |
+
#: includes/admin/payments/view-order-details.php:165
|
2058 |
msgid "Delete Payment"
|
2059 |
msgstr ""
|
2060 |
|
2061 |
+
#: includes/admin/payments/view-order-details.php:167
|
2062 |
msgid "Save Payment"
|
2063 |
msgstr ""
|
2064 |
|
2065 |
+
#: includes/admin/payments/view-order-details.php:180
|
2066 |
msgid "Resend Receipt"
|
2067 |
msgstr ""
|
2068 |
|
2069 |
+
#: includes/admin/payments/view-order-details.php:181
|
2070 |
+
msgid ""
|
2071 |
+
"<strong>Resend Receipt</strong>: This will send a new copy of the purchase "
|
2072 |
+
"receipt to the customer’s email address. If download URLs are "
|
2073 |
+
"included in the receipt, new file download URLs will also be included with "
|
2074 |
+
"the receipt."
|
2075 |
+
msgstr ""
|
2076 |
+
|
2077 |
+
#: includes/admin/payments/view-order-details.php:192
|
2078 |
msgid "Payment Meta"
|
2079 |
msgstr ""
|
2080 |
|
2081 |
+
#: includes/admin/payments/view-order-details.php:203
|
2082 |
msgid "Gateway:"
|
2083 |
msgstr ""
|
2084 |
|
2085 |
+
#: includes/admin/payments/view-order-details.php:211
|
2086 |
msgid "Key:"
|
2087 |
msgstr ""
|
2088 |
|
2089 |
+
#: includes/admin/payments/view-order-details.php:218
|
2090 |
msgid "IP:"
|
2091 |
msgstr ""
|
2092 |
|
2093 |
+
#: includes/admin/payments/view-order-details.php:226
|
2094 |
msgid "Transaction ID:"
|
2095 |
msgstr ""
|
2096 |
|
2097 |
+
#: includes/admin/payments/view-order-details.php:236
|
2098 |
+
msgid "Unlimited file downloads"
|
|
|
|
|
2099 |
msgstr ""
|
2100 |
|
2101 |
+
#: includes/admin/payments/view-order-details.php:237
|
2102 |
+
msgid ""
|
2103 |
+
"<strong>Unlimited file downloads</strong>: checking this box will override "
|
2104 |
+
"all other file download limits for this purchase, granting the customer "
|
2105 |
+
"unliimited downloads of all files included on the purchase."
|
2106 |
msgstr ""
|
2107 |
|
2108 |
+
#: includes/admin/payments/view-order-details.php:252
|
2109 |
#: includes/admin/reporting/reports.php:33 includes/class-edd-logging.php:48
|
2110 |
msgid "Logs"
|
2111 |
msgstr ""
|
2112 |
|
2113 |
+
#: includes/admin/payments/view-order-details.php:260
|
2114 |
msgid "View file download log for purchase"
|
2115 |
msgstr ""
|
2116 |
|
2117 |
+
#: includes/admin/payments/view-order-details.php:264
|
2118 |
msgid "View customer download log"
|
2119 |
msgstr ""
|
2120 |
|
2121 |
+
#: includes/admin/payments/view-order-details.php:268
|
2122 |
msgid "View all purchases of customer"
|
2123 |
msgstr ""
|
2124 |
|
2125 |
+
#: includes/admin/payments/view-order-details.php:350
|
2126 |
#: templates/widget-cart-checkout.php:5 templates/widget-cart-empty.php:6
|
2127 |
msgid "Total:"
|
2128 |
msgstr ""
|
2129 |
|
2130 |
+
#: includes/admin/payments/view-order-details.php:358
|
|
|
2131 |
msgid "Copy Download Link(s)"
|
2132 |
msgstr ""
|
2133 |
|
2134 |
+
#: includes/admin/payments/view-order-details.php:379
|
|
|
|
|
|
|
|
|
|
|
|
|
2135 |
#: includes/emails/class-edd-email-tags.php:407
|
2136 |
#: includes/emails/class-edd-email-tags.php:518
|
2137 |
#: templates/shortcode-receipt.php:128
|
2138 |
msgid "Quantity"
|
2139 |
msgstr ""
|
2140 |
|
2141 |
+
#: includes/admin/payments/view-order-details.php:390
|
2142 |
msgid "Item Price: "
|
2143 |
msgstr ""
|
2144 |
|
2145 |
+
#: includes/admin/payments/view-order-details.php:398
|
2146 |
msgid "Add %s to Payment"
|
2147 |
msgstr ""
|
2148 |
|
2149 |
+
#: includes/admin/payments/view-order-details.php:409
|
2150 |
msgid "No %s included with this purchase"
|
2151 |
msgstr ""
|
2152 |
|
2153 |
+
#: includes/admin/payments/view-order-details.php:436
|
2154 |
msgid "View Customer Details"
|
2155 |
msgstr ""
|
2156 |
|
2157 |
+
#: includes/admin/payments/view-order-details.php:439
|
2158 |
msgid "New Customer"
|
2159 |
msgstr ""
|
2160 |
|
2161 |
+
#: includes/admin/payments/view-order-details.php:445
|
2162 |
msgid "Name:"
|
2163 |
msgstr ""
|
2164 |
|
2165 |
+
#: includes/admin/payments/view-order-details.php:449
|
2166 |
msgid "Email:"
|
2167 |
msgstr ""
|
2168 |
|
2169 |
+
#: includes/admin/payments/view-order-details.php:457
|
2170 |
msgid "Click \"Save Payment\" to create new customer"
|
2171 |
msgstr ""
|
2172 |
|
2173 |
+
#: includes/admin/payments/view-order-details.php:472
|
2174 |
#: includes/checkout/template.php:329
|
2175 |
msgid "Billing Address"
|
2176 |
msgstr ""
|
2177 |
|
2178 |
+
#: includes/admin/payments/view-order-details.php:482
|
2179 |
msgid "Street Address Line 1:"
|
2180 |
msgstr ""
|
2181 |
|
2182 |
+
#: includes/admin/payments/view-order-details.php:486
|
2183 |
msgid "Street Address Line 2:"
|
2184 |
msgstr ""
|
2185 |
|
2186 |
+
#: includes/admin/payments/view-order-details.php:514
|
2187 |
+
#: includes/admin/settings/register-settings.php:298
|
2188 |
msgid "Select a country"
|
2189 |
msgstr ""
|
2190 |
|
2191 |
+
#: includes/admin/payments/view-order-details.php:530
|
2192 |
+
#: includes/admin/settings/register-settings.php:306
|
2193 |
msgid "Select a state"
|
2194 |
msgstr ""
|
2195 |
|
2196 |
+
#: includes/admin/payments/view-order-details.php:550
|
2197 |
msgid "Payment Notes"
|
2198 |
msgstr ""
|
2199 |
|
2200 |
+
#: includes/admin/payments/view-order-details.php:565
|
2201 |
msgid "No payment notes"
|
2202 |
msgstr ""
|
2203 |
|
2204 |
+
#: includes/admin/payments/view-order-details.php:571
|
2205 |
msgid "Add Note"
|
2206 |
msgstr ""
|
2207 |
|
2208 |
#: includes/admin/plugins.php:27
|
2209 |
+
#: includes/admin/settings/register-settings.php:1190
|
2210 |
msgid "General Settings"
|
2211 |
msgstr ""
|
2212 |
|
2217 |
#: includes/admin/reporting/class-api-requests-logs-list-table.php:89
|
2218 |
#: includes/admin/reporting/class-file-downloads-logs-list-table.php:144
|
2219 |
#: includes/admin/reporting/class-gateway-error-logs-list-table.php:129
|
2220 |
+
#: includes/admin/reporting/class-sales-logs-list-table.php:131
|
2221 |
msgid "Log ID"
|
2222 |
msgstr ""
|
2223 |
|
2237 |
msgid "Request Speed"
|
2238 |
msgstr ""
|
2239 |
|
|
|
|
|
|
|
|
|
2240 |
#: includes/admin/reporting/class-api-requests-logs-list-table.php:137
|
2241 |
msgid "View Request"
|
2242 |
msgstr ""
|
2295 |
|
2296 |
#: includes/admin/reporting/class-export-customers.php:66
|
2297 |
#: includes/admin/reporting/class-export-payments.php:64
|
2298 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:44
|
2299 |
+
#: includes/admin/tools.php:384 includes/checkout/template.php:191
|
2300 |
+
#: templates/shortcode-profile-editor.php:33
|
2301 |
msgid "First Name"
|
2302 |
msgstr ""
|
2303 |
|
2304 |
#: includes/admin/reporting/class-export-customers.php:67
|
2305 |
#: includes/admin/reporting/class-export-payments.php:65
|
2306 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:45
|
2307 |
+
#: includes/admin/tools.php:393 includes/checkout/template.php:201
|
2308 |
+
#: templates/shortcode-profile-editor.php:36
|
2309 |
msgid "Last Name"
|
2310 |
msgstr ""
|
2311 |
|
2329 |
#: includes/admin/reporting/class-export-download-history.php:66
|
2330 |
#: includes/admin/reporting/class-file-downloads-logs-list-table.php:149
|
2331 |
#: includes/admin/reporting/export/class-batch-export-file-downloads.php:44
|
2332 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:64
|
2333 |
+
#: includes/admin/tools.php:420
|
2334 |
msgid "IP Address"
|
2335 |
msgstr ""
|
2336 |
|
2347 |
|
2348 |
#: includes/admin/reporting/class-export-payments.php:62
|
2349 |
#: includes/admin/reporting/export/class-batch-export-payments.php:41
|
2350 |
+
#: includes/admin/tools.php:456
|
2351 |
msgid "Payment Number"
|
2352 |
msgstr ""
|
2353 |
|
2354 |
#: includes/admin/reporting/class-export-payments.php:66
|
2355 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:46
|
2356 |
msgid "Address"
|
2357 |
msgstr ""
|
2358 |
|
2359 |
#: includes/admin/reporting/class-export-payments.php:67
|
2360 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:47
|
2361 |
msgid "Address (Line 2)"
|
2362 |
msgstr ""
|
2363 |
|
2364 |
#: includes/admin/reporting/class-export-payments.php:69
|
2365 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:49
|
2366 |
msgid "State"
|
2367 |
msgstr ""
|
2368 |
|
2369 |
#: includes/admin/reporting/class-export-payments.php:70
|
2370 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:50
|
2371 |
+
#: includes/admin/settings/register-settings.php:1831
|
2372 |
+
#: includes/admin/tools.php:591 templates/shortcode-profile-editor.php:138
|
2373 |
msgid "Country"
|
2374 |
msgstr ""
|
2375 |
|
2376 |
#: includes/admin/reporting/class-export-payments.php:71
|
2377 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:51
|
2378 |
+
#: includes/admin/tools.php:582 includes/checkout/template.php:365
|
2379 |
+
#: templates/shortcode-profile-editor.php:135
|
2380 |
msgid "Zip / Postal Code"
|
2381 |
msgstr ""
|
2382 |
|
2383 |
#: includes/admin/reporting/class-export-payments.php:72
|
|
|
2384 |
#: templates/shortcode-receipt.php:119
|
2385 |
msgid "Products"
|
2386 |
msgstr ""
|
2387 |
|
2388 |
#: includes/admin/reporting/class-export-payments.php:73
|
2389 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:54
|
2390 |
msgid "SKUs"
|
2391 |
msgstr ""
|
2392 |
|
2393 |
#: includes/admin/reporting/class-export-payments.php:77
|
2394 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:58
|
2395 |
+
#: includes/admin/tools.php:447 templates/shortcode-receipt.php:53
|
2396 |
msgid "Payment Method"
|
2397 |
msgstr ""
|
2398 |
|
2399 |
#: includes/admin/reporting/class-export-payments.php:78
|
2400 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:59
|
2401 |
+
#: includes/admin/tools.php:528
|
2402 |
msgid "Transaction ID"
|
2403 |
msgstr ""
|
2404 |
|
2405 |
#: includes/admin/reporting/class-export-payments.php:79
|
2406 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:60
|
2407 |
+
#: includes/admin/tools.php:474
|
2408 |
msgid "Purchase Key"
|
2409 |
msgstr ""
|
2410 |
|
2411 |
#: includes/admin/reporting/class-export-payments.php:81
|
2412 |
#: includes/admin/reporting/class-file-downloads-logs-list-table.php:146
|
2413 |
+
#: includes/admin/reporting/class-sales-logs-list-table.php:132
|
2414 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:62
|
2415 |
+
#: includes/admin/tools.php:537
|
2416 |
msgid "User"
|
2417 |
msgstr ""
|
2418 |
|
2419 |
#: includes/admin/reporting/class-export-payments.php:192
|
2420 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:222
|
2421 |
msgid "guest"
|
2422 |
msgstr ""
|
2423 |
|
2433 |
|
2434 |
#: includes/admin/reporting/class-file-downloads-logs-list-table.php:147
|
2435 |
#: includes/admin/reporting/class-gateway-error-logs-list-table.php:130
|
2436 |
+
#: includes/admin/reporting/class-sales-logs-list-table.php:135
|
2437 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:40
|
2438 |
msgid "Payment ID"
|
2439 |
msgstr ""
|
2440 |
|
2441 |
#: includes/admin/reporting/class-gateway-error-logs-list-table.php:79
|
2442 |
+
#: includes/gateways/manual.php:73 includes/gateways/paypal-standard.php:178
|
2443 |
msgid "Payment Error"
|
2444 |
msgstr ""
|
2445 |
|
2468 |
msgid "Pending / Failed Sales"
|
2469 |
msgstr ""
|
2470 |
|
2471 |
+
#: includes/admin/reporting/class-sales-logs-list-table.php:134
|
2472 |
msgid "Item Amount"
|
2473 |
msgstr ""
|
2474 |
|
2479 |
msgstr ""
|
2480 |
|
2481 |
#: includes/admin/reporting/contextual-help.php:48
|
2482 |
+
#: includes/admin/reporting/reports.php:31 includes/admin/tools.php:819
|
2483 |
msgid "Export"
|
2484 |
msgstr ""
|
2485 |
|
2575 |
msgstr ""
|
2576 |
|
2577 |
#: includes/admin/reporting/export/class-batch-export-downloads.php:54
|
2578 |
+
#: includes/admin/settings/register-settings.php:802
|
2579 |
+
#: includes/admin/tools.php:774
|
2580 |
msgid "File Download Limit"
|
2581 |
msgstr ""
|
2582 |
|
2591 |
msgid "SKU"
|
2592 |
msgstr ""
|
2593 |
|
2594 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:43
|
2595 |
+
#: includes/admin/tools.php:402
|
2596 |
+
msgid "Customer ID"
|
2597 |
+
msgstr ""
|
2598 |
+
|
2599 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:52
|
2600 |
+
msgid "Products (Verbose)"
|
2601 |
+
msgstr ""
|
2602 |
+
|
2603 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:63
|
2604 |
+
#: includes/admin/settings/register-settings.php:333
|
2605 |
+
msgid "Currency"
|
2606 |
+
msgstr ""
|
2607 |
+
|
2608 |
+
#: includes/admin/reporting/export/class-batch-export-payments.php:65
|
2609 |
+
#: includes/admin/tools.php:429
|
2610 |
+
msgid "Mode (Live|Test)"
|
2611 |
+
msgstr ""
|
2612 |
+
|
2613 |
#: includes/admin/reporting/export/export-functions.php:49
|
2614 |
msgid "Export location or file not writable"
|
2615 |
msgstr ""
|
2622 |
msgid "Batch Processing Complete"
|
2623 |
msgstr ""
|
2624 |
|
2625 |
+
#: includes/admin/reporting/graphing.php:267
|
2626 |
msgid "Earnings Over Time"
|
2627 |
msgstr ""
|
2628 |
|
2629 |
+
#: includes/admin/reporting/graphing.php:285
|
2630 |
+
#: includes/admin/reporting/graphing.php:608
|
2631 |
msgid "Total earnings for period shown: "
|
2632 |
msgstr ""
|
2633 |
|
2634 |
+
#: includes/admin/reporting/graphing.php:293
|
2635 |
+
#: includes/admin/reporting/graphing.php:609
|
2636 |
msgid "Total sales for period shown: "
|
2637 |
msgstr ""
|
2638 |
|
2639 |
+
#: includes/admin/reporting/graphing.php:299
|
2640 |
msgid "Estimated monthly earnings: "
|
2641 |
msgstr ""
|
2642 |
|
2643 |
+
#: includes/admin/reporting/graphing.php:307
|
2644 |
msgid "Estimated monthly sales: "
|
2645 |
msgstr ""
|
2646 |
|
2647 |
+
#: includes/admin/reporting/graphing.php:314
|
2648 |
msgid "Excludes sales tax."
|
2649 |
msgstr ""
|
2650 |
|
2651 |
+
#: includes/admin/reporting/graphing.php:598
|
2652 |
msgid "Earnings Over Time for %s"
|
2653 |
msgstr ""
|
2654 |
|
2655 |
+
#: includes/admin/reporting/graphing.php:610
|
2656 |
msgid "Average monthly earnings: %s"
|
2657 |
msgstr ""
|
2658 |
|
2659 |
+
#: includes/admin/reporting/graphing.php:611
|
2660 |
msgid "Average monthly sales: %s"
|
2661 |
msgstr ""
|
2662 |
|
2663 |
+
#: includes/admin/reporting/graphing.php:628 includes/class-edd-stats.php:85
|
2664 |
msgid "Yesterday"
|
2665 |
msgstr ""
|
2666 |
|
2667 |
+
#: includes/admin/reporting/graphing.php:629 includes/class-edd-stats.php:86
|
2668 |
msgid "This Week"
|
2669 |
msgstr ""
|
2670 |
|
2671 |
+
#: includes/admin/reporting/graphing.php:630 includes/class-edd-stats.php:87
|
2672 |
msgid "Last Week"
|
2673 |
msgstr ""
|
2674 |
|
2675 |
+
#: includes/admin/reporting/graphing.php:631 includes/class-edd-stats.php:88
|
2676 |
msgid "This Month"
|
2677 |
msgstr ""
|
2678 |
|
2679 |
+
#: includes/admin/reporting/graphing.php:633 includes/class-edd-stats.php:90
|
2680 |
msgid "This Quarter"
|
2681 |
msgstr ""
|
2682 |
|
2683 |
+
#: includes/admin/reporting/graphing.php:634 includes/class-edd-stats.php:91
|
2684 |
msgid "Last Quarter"
|
2685 |
msgstr ""
|
2686 |
|
2687 |
+
#: includes/admin/reporting/graphing.php:635 includes/class-edd-stats.php:92
|
2688 |
msgid "This Year"
|
2689 |
msgstr ""
|
2690 |
|
2691 |
+
#: includes/admin/reporting/graphing.php:636 includes/class-edd-stats.php:93
|
2692 |
msgid "Last Year"
|
2693 |
msgstr ""
|
2694 |
|
2695 |
+
#: includes/admin/reporting/graphing.php:637
|
2696 |
msgid "Custom"
|
2697 |
msgstr ""
|
2698 |
|
2699 |
+
#: includes/admin/reporting/graphing.php:669
|
2700 |
msgid "From"
|
2701 |
msgstr ""
|
2702 |
|
2703 |
+
#: includes/admin/reporting/graphing.php:685
|
2704 |
msgid "To"
|
2705 |
msgstr ""
|
2706 |
|
2707 |
+
#: includes/admin/reporting/graphing.php:705
|
2708 |
msgid "Exclude Taxes"
|
2709 |
msgstr ""
|
2710 |
|
2711 |
+
#: includes/admin/reporting/graphing.php:710
|
2712 |
msgid "Filter"
|
2713 |
msgstr ""
|
2714 |
|
2715 |
#: includes/admin/reporting/logs.php:144
|
2716 |
+
#: includes/admin/settings/register-settings.php:1217
|
2717 |
msgid "File Downloads"
|
2718 |
msgstr ""
|
2719 |
|
2832 |
|
2833 |
#: includes/admin/reporting/reports.php:58
|
2834 |
#: includes/admin/settings/contextual-help.php:71
|
2835 |
+
#: includes/admin/settings/register-settings.php:1139
|
2836 |
msgid "Taxes"
|
2837 |
msgstr ""
|
2838 |
|
2907 |
msgstr ""
|
2908 |
|
2909 |
#: includes/admin/reporting/reports.php:372
|
2910 |
+
#: includes/admin/reporting/reports.php:397
|
2911 |
+
#: includes/admin/reporting/reports.php:413
|
2912 |
+
#: includes/admin/reporting/reports.php:425
|
2913 |
+
#: includes/admin/reporting/reports.php:439
|
2914 |
msgid "Generate CSV"
|
2915 |
msgstr ""
|
2916 |
|
2922 |
msgid "Download a CSV of all payments recorded."
|
2923 |
msgstr ""
|
2924 |
|
2925 |
+
#: includes/admin/reporting/reports.php:383
|
2926 |
+
#: includes/admin/reporting/reports.php:435
|
2927 |
msgid "Choose start date"
|
2928 |
msgstr ""
|
2929 |
|
2930 |
+
#: includes/admin/reporting/reports.php:384
|
2931 |
+
#: includes/admin/reporting/reports.php:436
|
2932 |
msgid "Choose end date"
|
2933 |
msgstr ""
|
2934 |
|
2935 |
+
#: includes/admin/reporting/reports.php:386
|
2936 |
msgid "All Statuses"
|
2937 |
msgstr ""
|
2938 |
|
2939 |
+
#: includes/admin/reporting/reports.php:406
|
2940 |
msgid "Export Customers in CSV"
|
2941 |
msgstr ""
|
2942 |
|
2943 |
+
#: includes/admin/reporting/reports.php:408
|
2944 |
msgid "Download a CSV of customers."
|
2945 |
msgstr ""
|
2946 |
|
2947 |
+
#: includes/admin/reporting/reports.php:419
|
2948 |
msgid "Export Download Products in CSV"
|
2949 |
msgstr ""
|
2950 |
|
2951 |
+
#: includes/admin/reporting/reports.php:421
|
2952 |
msgid "Download a CSV of download products."
|
2953 |
msgstr ""
|
2954 |
|
2955 |
+
#: includes/admin/reporting/reports.php:431
|
2956 |
msgid "Export Download History in CSV"
|
2957 |
msgstr ""
|
2958 |
|
2959 |
+
#: includes/admin/reporting/reports.php:433
|
2960 |
msgid "Download a CSV of file downloads."
|
2961 |
msgstr ""
|
2962 |
|
2968 |
msgstr ""
|
2969 |
|
2970 |
#: includes/admin/settings/contextual-help.php:48
|
2971 |
+
#: includes/admin/settings/register-settings.php:407
|
2972 |
+
#: includes/admin/settings/register-settings.php:1136
|
2973 |
msgid "Payment Gateways"
|
2974 |
msgstr ""
|
2975 |
|
2998 |
msgstr ""
|
2999 |
|
3000 |
#: includes/admin/settings/contextual-help.php:57
|
3001 |
+
#: includes/admin/settings/register-settings.php:1137
|
3002 |
msgid "Emails"
|
3003 |
msgstr ""
|
3004 |
|
3018 |
msgstr ""
|
3019 |
|
3020 |
#: includes/admin/settings/contextual-help.php:65
|
3021 |
+
#: includes/admin/settings/register-settings.php:1138
|
3022 |
msgid "Styles"
|
3023 |
msgstr ""
|
3024 |
|
3114 |
msgid "A description of all the options are provided beside their input boxes."
|
3115 |
msgstr ""
|
3116 |
|
3117 |
+
#: includes/admin/settings/register-settings.php:241
|
3118 |
+
#: includes/admin/settings/register-settings.php:244
|
3119 |
msgid "Page Settings"
|
3120 |
msgstr ""
|
3121 |
|
3122 |
+
#: includes/admin/settings/register-settings.php:245
|
3123 |
+
msgid ""
|
3124 |
+
"Easy Digital Downloads uses the pages below for handling the display of "
|
3125 |
+
"checkout, purchase confirmation, purchase history, and purchase failures. "
|
3126 |
+
"If pages are deleted or removed in some way, they can be recreated manually "
|
3127 |
+
"from the Pages menu. When re-creating the pages, enter the shortcode shown "
|
3128 |
+
"in the page content area."
|
3129 |
+
msgstr ""
|
3130 |
+
|
3131 |
+
#: includes/admin/settings/register-settings.php:249
|
3132 |
msgid "Checkout Page"
|
3133 |
msgstr ""
|
3134 |
|
3135 |
+
#: includes/admin/settings/register-settings.php:250
|
3136 |
msgid ""
|
3137 |
"This is the checkout page where buyers will complete their purchases. The "
|
3138 |
"[download_checkout] short code must be on this page."
|
3139 |
msgstr ""
|
3140 |
|
3141 |
+
#: includes/admin/settings/register-settings.php:254
|
3142 |
+
#: includes/admin/settings/register-settings.php:263
|
3143 |
+
#: includes/admin/settings/register-settings.php:272
|
3144 |
+
#: includes/admin/settings/register-settings.php:281
|
3145 |
msgid "Select a page"
|
3146 |
msgstr ""
|
3147 |
|
3148 |
+
#: includes/admin/settings/register-settings.php:258
|
3149 |
msgid "Success Page"
|
3150 |
msgstr ""
|
3151 |
|
3152 |
+
#: includes/admin/settings/register-settings.php:259
|
3153 |
msgid ""
|
3154 |
"This is the page buyers are sent to after completing their purchases. The "
|
3155 |
"[edd_receipt] short code should be on this page."
|
3156 |
msgstr ""
|
3157 |
|
3158 |
+
#: includes/admin/settings/register-settings.php:267
|
3159 |
msgid "Failed Transaction Page"
|
3160 |
msgstr ""
|
3161 |
|
3162 |
+
#: includes/admin/settings/register-settings.php:268
|
3163 |
msgid ""
|
3164 |
"This is the page buyers are sent to if their transaction is cancelled or "
|
3165 |
+
"fails."
|
3166 |
msgstr ""
|
3167 |
|
3168 |
+
#: includes/admin/settings/register-settings.php:276
|
3169 |
msgid "Purchase History Page"
|
3170 |
msgstr ""
|
3171 |
|
3172 |
+
#: includes/admin/settings/register-settings.php:277
|
3173 |
msgid ""
|
3174 |
"This page shows a complete purchase history for the current user, including "
|
3175 |
+
"download links. The [purchase_history] short code should be on this page."
|
3176 |
msgstr ""
|
3177 |
|
3178 |
+
#: includes/admin/settings/register-settings.php:285
|
3179 |
msgid "Store Location"
|
3180 |
msgstr ""
|
3181 |
|
3182 |
+
#: includes/admin/settings/register-settings.php:288
|
3183 |
+
msgid "Store Location Settings"
|
3184 |
+
msgstr ""
|
3185 |
+
|
3186 |
+
#: includes/admin/settings/register-settings.php:289
|
3187 |
+
msgid ""
|
3188 |
+
"Easy Digital Downloads will use the following Country and State to pre-fill "
|
3189 |
+
"fields at checkout. This will also pre-calculate any taxes defined if the "
|
3190 |
+
"location below has taxes enabled."
|
3191 |
+
msgstr ""
|
3192 |
+
|
3193 |
+
#: includes/admin/settings/register-settings.php:293
|
3194 |
msgid "Base Country"
|
3195 |
msgstr ""
|
3196 |
|
3197 |
+
#: includes/admin/settings/register-settings.php:294
|
3198 |
msgid "Where does your store operate from?"
|
3199 |
msgstr ""
|
3200 |
|
3201 |
+
#: includes/admin/settings/register-settings.php:302
|
3202 |
msgid "Base State / Province"
|
3203 |
msgstr ""
|
3204 |
|
3205 |
+
#: includes/admin/settings/register-settings.php:303
|
3206 |
msgid "What state / province does your store operate from?"
|
3207 |
msgstr ""
|
3208 |
|
3209 |
+
#: includes/admin/settings/register-settings.php:310
|
3210 |
msgid "Tracking Settings"
|
3211 |
msgstr ""
|
3212 |
|
3213 |
+
#: includes/admin/settings/register-settings.php:316
|
3214 |
msgid "Allow Usage Tracking?"
|
3215 |
msgstr ""
|
3216 |
|
3217 |
+
#: includes/admin/settings/register-settings.php:318
|
3218 |
msgid ""
|
3219 |
"Allow Easy Digital Downloads to anonymously track how this plugin is used "
|
3220 |
"and help us make the plugin better. Opt-in to tracking and our newsletter "
|
3223 |
"sensitive data is tracked."
|
3224 |
msgstr ""
|
3225 |
|
3226 |
+
#: includes/admin/settings/register-settings.php:327
|
3227 |
+
#: includes/admin/settings/register-settings.php:1191
|
3228 |
msgid "Currency Settings"
|
3229 |
msgstr ""
|
3230 |
|
3231 |
+
#: includes/admin/settings/register-settings.php:334
|
|
|
|
|
|
|
|
|
3232 |
msgid ""
|
3233 |
"Choose your currency. Note that some payment gateways have currency "
|
3234 |
"restrictions."
|
3235 |
msgstr ""
|
3236 |
|
3237 |
+
#: includes/admin/settings/register-settings.php:341
|
3238 |
msgid "Currency Position"
|
3239 |
msgstr ""
|
3240 |
|
3241 |
+
#: includes/admin/settings/register-settings.php:342
|
3242 |
msgid "Choose the location of the currency sign."
|
3243 |
msgstr ""
|
3244 |
|
3245 |
+
#: includes/admin/settings/register-settings.php:345
|
3246 |
msgid "Before - $10"
|
3247 |
msgstr ""
|
3248 |
|
3249 |
+
#: includes/admin/settings/register-settings.php:346
|
3250 |
msgid "After - 10$"
|
3251 |
msgstr ""
|
3252 |
|
3253 |
+
#: includes/admin/settings/register-settings.php:351
|
3254 |
msgid "Thousands Separator"
|
3255 |
msgstr ""
|
3256 |
|
3257 |
+
#: includes/admin/settings/register-settings.php:352
|
3258 |
msgid "The symbol (usually , or .) to separate thousands"
|
3259 |
msgstr ""
|
3260 |
|
3261 |
+
#: includes/admin/settings/register-settings.php:359
|
3262 |
msgid "Decimal Separator"
|
3263 |
msgstr ""
|
3264 |
|
3265 |
+
#: includes/admin/settings/register-settings.php:360
|
3266 |
msgid "The symbol (usually , or .) to separate decimal points"
|
3267 |
msgstr ""
|
3268 |
|
3269 |
+
#: includes/admin/settings/register-settings.php:369
|
3270 |
+
#: includes/admin/settings/register-settings.php:372
|
3271 |
+
#: includes/admin/settings/register-settings.php:1192
|
3272 |
msgid "API Settings"
|
3273 |
msgstr ""
|
3274 |
|
3275 |
+
#: includes/admin/settings/register-settings.php:373
|
3276 |
+
msgid ""
|
3277 |
+
"The Easy Digital Downloads REST API provides access to store data through "
|
3278 |
+
"our API endpoints. Enable this setting if you would like all user accounts "
|
3279 |
+
"to be able to generate their own API keys."
|
3280 |
+
msgstr ""
|
3281 |
+
|
3282 |
+
#: includes/admin/settings/register-settings.php:377
|
3283 |
msgid "Allow User Keys"
|
3284 |
msgstr ""
|
3285 |
|
3286 |
+
#: includes/admin/settings/register-settings.php:378
|
3287 |
msgid ""
|
3288 |
"Check this box to allow all users to generate API keys. Users with the "
|
3289 |
"'manage_shop_settings' capability are always allowed to generate keys."
|
3290 |
msgstr ""
|
3291 |
|
3292 |
+
#: includes/admin/settings/register-settings.php:383
|
3293 |
+
msgid ""
|
3294 |
+
"Visit the <a href=\"%s\" target=\"_blank\">REST API documentation</a> for "
|
3295 |
+
"further information."
|
3296 |
+
msgstr ""
|
3297 |
+
|
3298 |
+
#: includes/admin/settings/register-settings.php:395
|
3299 |
+
#: includes/admin/settings/register-settings.php:1195
|
3300 |
msgid "Gateway Settings"
|
3301 |
msgstr ""
|
3302 |
|
3303 |
+
#: includes/admin/settings/register-settings.php:401
|
3304 |
msgid "Test Mode"
|
3305 |
msgstr ""
|
3306 |
|
3307 |
+
#: includes/admin/settings/register-settings.php:402
|
3308 |
msgid ""
|
3309 |
"While in test mode no live transactions are processed. To fully use test "
|
3310 |
"mode, you must have a sandbox (test) account for the payment gateway you "
|
3311 |
"are testing."
|
3312 |
msgstr ""
|
3313 |
|
3314 |
+
#: includes/admin/settings/register-settings.php:408
|
3315 |
msgid "Choose the payment gateways you want to enable."
|
3316 |
msgstr ""
|
3317 |
|
3318 |
+
#: includes/admin/settings/register-settings.php:414
|
3319 |
msgid "Default Gateway"
|
3320 |
msgstr ""
|
3321 |
|
3322 |
+
#: includes/admin/settings/register-settings.php:415
|
3323 |
msgid "This gateway will be loaded automatically with the checkout page."
|
3324 |
msgstr ""
|
3325 |
|
3326 |
+
#: includes/admin/settings/register-settings.php:421
|
3327 |
msgid "Accepted Payment Method Icons"
|
3328 |
msgstr ""
|
3329 |
|
3330 |
+
#: includes/admin/settings/register-settings.php:422
|
3331 |
msgid "Display icons for the selected payment methods"
|
3332 |
msgstr ""
|
3333 |
|
3334 |
+
#: includes/admin/settings/register-settings.php:422
|
3335 |
msgid ""
|
3336 |
"You will also need to configure your gateway settings if you are accepting "
|
3337 |
"credit cards"
|
3338 |
msgstr ""
|
3339 |
|
3340 |
+
#: includes/admin/settings/register-settings.php:442
|
3341 |
+
#: includes/admin/settings/register-settings.php:1199
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3342 |
msgid "Email Settings"
|
3343 |
msgstr ""
|
3344 |
|
3345 |
+
#: includes/admin/settings/register-settings.php:447
|
3346 |
msgid "Email Template"
|
3347 |
msgstr ""
|
3348 |
|
3349 |
+
#: includes/admin/settings/register-settings.php:448
|
3350 |
msgid ""
|
3351 |
"Choose a template. Click \"Save Changes\" then \"Preview Purchase Receipt\" "
|
3352 |
"to see the new template."
|
3353 |
msgstr ""
|
3354 |
|
3355 |
+
#: includes/admin/settings/register-settings.php:454
|
3356 |
msgid "Logo"
|
3357 |
msgstr ""
|
3358 |
|
3359 |
+
#: includes/admin/settings/register-settings.php:455
|
3360 |
msgid ""
|
3361 |
"Upload or choose a logo to be displayed at the top of the purchase receipt "
|
3362 |
"emails. Displayed on HTML emails only."
|
3363 |
msgstr ""
|
3364 |
|
3365 |
+
#: includes/admin/settings/register-settings.php:468
|
3366 |
+
#: includes/admin/settings/register-settings.php:1200
|
3367 |
msgid "Purchase Receipts"
|
3368 |
msgstr ""
|
3369 |
|
3370 |
+
#: includes/admin/settings/register-settings.php:473
|
3371 |
msgid "From Name"
|
3372 |
msgstr ""
|
3373 |
|
3374 |
+
#: includes/admin/settings/register-settings.php:474
|
3375 |
msgid ""
|
3376 |
"The name purchase receipts are said to come from. This should probably be "
|
3377 |
"your site or shop name."
|
3378 |
msgstr ""
|
3379 |
|
3380 |
+
#: includes/admin/settings/register-settings.php:480
|
3381 |
msgid "From Email"
|
3382 |
msgstr ""
|
3383 |
|
3384 |
+
#: includes/admin/settings/register-settings.php:481
|
3385 |
msgid ""
|
3386 |
"Email to send purchase receipts from. This will act as the \"from\" and "
|
3387 |
"\"reply-to\" address."
|
3388 |
msgstr ""
|
3389 |
|
3390 |
+
#: includes/admin/settings/register-settings.php:487
|
3391 |
msgid "Purchase Email Subject"
|
3392 |
msgstr ""
|
3393 |
|
3394 |
+
#: includes/admin/settings/register-settings.php:488
|
3395 |
msgid "Enter the subject line for the purchase receipt email"
|
3396 |
msgstr ""
|
3397 |
|
3398 |
+
#: includes/admin/settings/register-settings.php:490
|
3399 |
+
#: includes/admin/settings/register-settings.php:497
|
3400 |
#: includes/admin/settings/register-settings.php:501
|
|
|
|
|
3401 |
#: includes/emails/functions.php:36 includes/emails/functions.php:40
|
3402 |
#: includes/emails/functions.php:77 includes/emails/functions.php:81
|
3403 |
#: includes/emails/template.php:141
|
3404 |
msgid "Purchase Receipt"
|
3405 |
msgstr ""
|
3406 |
|
3407 |
+
#: includes/admin/settings/register-settings.php:494
|
3408 |
msgid "Purchase Email Heading"
|
3409 |
msgstr ""
|
3410 |
|
3411 |
+
#: includes/admin/settings/register-settings.php:495
|
3412 |
msgid "Enter the heading for the purchase receipt email"
|
3413 |
msgstr ""
|
3414 |
|
3415 |
+
#: includes/admin/settings/register-settings.php:502
|
3416 |
msgid ""
|
3417 |
"Enter the text that is sent as purchase receipt email to users after "
|
3418 |
"completion of a successful purchase. HTML is accepted. Available template "
|
3419 |
"tags:"
|
3420 |
msgstr ""
|
3421 |
|
3422 |
+
#: includes/admin/settings/register-settings.php:504
|
3423 |
#: includes/emails/template.php:159
|
3424 |
msgid "Dear"
|
3425 |
msgstr ""
|
3426 |
|
3427 |
+
#: includes/admin/settings/register-settings.php:504
|
3428 |
#: includes/emails/template.php:160
|
3429 |
msgid ""
|
3430 |
"Thank you for your purchase. Please click on the link(s) below to download "
|
3431 |
"your files."
|
3432 |
msgstr ""
|
3433 |
|
3434 |
+
#: includes/admin/settings/register-settings.php:510
|
3435 |
msgid "Sale Notifications"
|
3436 |
msgstr ""
|
3437 |
|
3438 |
+
#: includes/admin/settings/register-settings.php:515
|
3439 |
msgid "Sale Notification Subject"
|
3440 |
msgstr ""
|
3441 |
|
3442 |
+
#: includes/admin/settings/register-settings.php:516
|
3443 |
msgid "Enter the subject line for the sale notification email"
|
3444 |
msgstr ""
|
3445 |
|
3446 |
+
#: includes/admin/settings/register-settings.php:522
|
3447 |
msgid "Sale Notification"
|
3448 |
msgstr ""
|
3449 |
|
3450 |
+
#: includes/admin/settings/register-settings.php:523
|
3451 |
msgid ""
|
3452 |
"Enter the text that is sent as sale notification email after completion of "
|
3453 |
"a purchase. HTML is accepted. Available template tags:"
|
3454 |
msgstr ""
|
3455 |
|
3456 |
+
#: includes/admin/settings/register-settings.php:529
|
3457 |
msgid "Sale Notification Emails"
|
3458 |
msgstr ""
|
3459 |
|
3460 |
+
#: includes/admin/settings/register-settings.php:530
|
3461 |
msgid ""
|
3462 |
"Enter the email address(es) that should receive a notification anytime a "
|
3463 |
"sale is made, one per line"
|
3464 |
msgstr ""
|
3465 |
|
3466 |
+
#: includes/admin/settings/register-settings.php:536
|
3467 |
msgid "Disable Admin Notifications"
|
3468 |
msgstr ""
|
3469 |
|
3470 |
+
#: includes/admin/settings/register-settings.php:537
|
3471 |
msgid "Check this box if you do not want to receive sales notification emails."
|
3472 |
msgstr ""
|
3473 |
|
3474 |
+
#: includes/admin/settings/register-settings.php:549
|
3475 |
+
#: includes/admin/settings/register-settings.php:1204
|
3476 |
msgid "Style Settings"
|
3477 |
msgstr ""
|
3478 |
|
3479 |
+
#: includes/admin/settings/register-settings.php:554
|
3480 |
msgid "Disable Styles"
|
3481 |
msgstr ""
|
3482 |
|
3483 |
+
#: includes/admin/settings/register-settings.php:555
|
3484 |
msgid ""
|
3485 |
"Check this to disable all included styling of buttons, checkout fields, and "
|
3486 |
"all other elements."
|
3487 |
msgstr ""
|
3488 |
|
3489 |
+
#: includes/admin/settings/register-settings.php:557
|
3490 |
+
msgid "Disabling Styles"
|
3491 |
+
msgstr ""
|
3492 |
+
|
3493 |
+
#: includes/admin/settings/register-settings.php:558
|
3494 |
+
msgid ""
|
3495 |
+
"If your theme has a complete custom CSS file for Easy Digital Downloads, "
|
3496 |
+
"you may wish to disable our default styles. This is not recommended unless "
|
3497 |
+
"your sure your theme has a complete custom CSS."
|
3498 |
+
msgstr ""
|
3499 |
+
|
3500 |
+
#: includes/admin/settings/register-settings.php:562
|
3501 |
msgid "Buttons"
|
3502 |
msgstr ""
|
3503 |
|
3504 |
+
#: includes/admin/settings/register-settings.php:563
|
3505 |
msgid "Options for add to cart and purchase buttons"
|
3506 |
msgstr ""
|
3507 |
|
3508 |
+
#: includes/admin/settings/register-settings.php:568
|
3509 |
msgid "Default Button Style"
|
3510 |
msgstr ""
|
3511 |
|
3512 |
+
#: includes/admin/settings/register-settings.php:569
|
3513 |
msgid "Choose the style you want to use for the buttons."
|
3514 |
msgstr ""
|
3515 |
|
3516 |
+
#: includes/admin/settings/register-settings.php:575
|
3517 |
msgid "Default Button Color"
|
3518 |
msgstr ""
|
3519 |
|
3520 |
+
#: includes/admin/settings/register-settings.php:576
|
3521 |
msgid "Choose the color you want to use for the buttons."
|
3522 |
msgstr ""
|
3523 |
|
3524 |
+
#: includes/admin/settings/register-settings.php:589
|
3525 |
+
#: includes/admin/settings/register-settings.php:1207
|
3526 |
msgid "Tax Settings"
|
3527 |
msgstr ""
|
3528 |
|
3529 |
+
#: includes/admin/settings/register-settings.php:594
|
3530 |
+
msgid "Need help?"
|
3531 |
+
msgstr ""
|
3532 |
+
|
3533 |
+
#: includes/admin/settings/register-settings.php:595
|
3534 |
+
msgid ""
|
3535 |
+
"Visit the <a href=\"%s\" target=\"_blank\">Tax setup documentation</a> for "
|
3536 |
+
"further information. If you need VAT support, there are options listed on "
|
3537 |
+
"the documentation page."
|
3538 |
+
msgstr ""
|
3539 |
+
|
3540 |
+
#: includes/admin/settings/register-settings.php:600
|
3541 |
msgid "Enable Taxes"
|
3542 |
msgstr ""
|
3543 |
|
3544 |
+
#: includes/admin/settings/register-settings.php:601
|
3545 |
msgid "Check this to enable taxes on purchases."
|
3546 |
msgstr ""
|
3547 |
|
3548 |
+
#: includes/admin/settings/register-settings.php:603
|
3549 |
+
msgid "Enabling Taxes"
|
3550 |
+
msgstr ""
|
3551 |
+
|
3552 |
+
#: includes/admin/settings/register-settings.php:604
|
3553 |
+
msgid ""
|
3554 |
+
"With taxes enabled, Easy Digital Downloads will use the rules below to "
|
3555 |
+
"charge tax to customers. With taxes enabled, customers are required to "
|
3556 |
+
"input their address on checkout so that taxes can be properly calculated."
|
3557 |
+
msgstr ""
|
3558 |
+
|
3559 |
+
#: includes/admin/settings/register-settings.php:608
|
3560 |
msgid "Tax Rates"
|
3561 |
msgstr ""
|
3562 |
|
3563 |
+
#: includes/admin/settings/register-settings.php:609
|
3564 |
msgid "Enter tax rates for specific regions."
|
3565 |
msgstr ""
|
3566 |
|
3567 |
+
#: includes/admin/settings/register-settings.php:614
|
3568 |
+
#: includes/admin/settings/register-settings.php:618
|
3569 |
msgid "Fallback Tax Rate"
|
3570 |
msgstr ""
|
3571 |
|
3572 |
+
#: includes/admin/settings/register-settings.php:615
|
3573 |
msgid ""
|
3574 |
"Enter a percentage, such as 6.5. Customers not in a specific rate will be "
|
3575 |
"charged this rate."
|
3576 |
msgstr ""
|
3577 |
|
3578 |
+
#: includes/admin/settings/register-settings.php:619
|
3579 |
+
msgid ""
|
3580 |
+
"If the customer's address fails to meet the above tax rules, you can define "
|
3581 |
+
"a `default` tax rate to be applied to all other customers."
|
3582 |
msgstr ""
|
3583 |
|
3584 |
#: includes/admin/settings/register-settings.php:623
|
3585 |
+
msgid "Prices entered with tax"
|
3586 |
+
msgstr ""
|
3587 |
+
|
3588 |
+
#: includes/admin/settings/register-settings.php:624
|
3589 |
msgid "This option affects how you enter prices."
|
3590 |
msgstr ""
|
3591 |
|
3592 |
+
#: includes/admin/settings/register-settings.php:628
|
3593 |
msgid "Yes, I will enter prices inclusive of tax"
|
3594 |
msgstr ""
|
3595 |
|
3596 |
+
#: includes/admin/settings/register-settings.php:629
|
3597 |
msgid "No, I will enter prices exclusive of tax"
|
3598 |
msgstr ""
|
3599 |
|
3600 |
+
#: includes/admin/settings/register-settings.php:631
|
3601 |
+
msgid "Prices Inclusive of Tax"
|
3602 |
+
msgstr ""
|
3603 |
+
|
3604 |
+
#: includes/admin/settings/register-settings.php:632
|
3605 |
+
msgid ""
|
3606 |
+
"When using prices inclusive of tax, you will be entering your prices as the "
|
3607 |
+
"total amount you want a customer to pay for the download, including tax. "
|
3608 |
+
"Easy Digital Downloads will calculate the proper amount to tax the customer "
|
3609 |
+
"for the defined total price."
|
3610 |
+
msgstr ""
|
3611 |
+
|
3612 |
+
#: includes/admin/settings/register-settings.php:636
|
3613 |
msgid "Display Tax Rate on Prices"
|
3614 |
msgstr ""
|
3615 |
|
3616 |
+
#: includes/admin/settings/register-settings.php:637
|
3617 |
msgid "Some countries require a notice when product prices include tax."
|
3618 |
msgstr ""
|
3619 |
|
3620 |
+
#: includes/admin/settings/register-settings.php:642
|
3621 |
msgid "Display during checkout"
|
3622 |
msgstr ""
|
3623 |
|
3624 |
+
#: includes/admin/settings/register-settings.php:643
|
3625 |
msgid "Should prices on the checkout page be shown with or without tax?"
|
3626 |
msgstr ""
|
3627 |
|
3628 |
+
#: includes/admin/settings/register-settings.php:647
|
3629 |
msgid "Including tax"
|
3630 |
msgstr ""
|
3631 |
|
3632 |
+
#: includes/admin/settings/register-settings.php:648
|
3633 |
msgid "Excluding tax"
|
3634 |
msgstr ""
|
3635 |
|
3636 |
+
#: includes/admin/settings/register-settings.php:667
|
3637 |
+
#: includes/admin/settings/register-settings.php:1214
|
3638 |
msgid "Misc Settings"
|
3639 |
msgstr ""
|
3640 |
|
3641 |
+
#: includes/admin/settings/register-settings.php:672
|
3642 |
+
msgid "Enable AJAX"
|
3643 |
msgstr ""
|
3644 |
|
3645 |
+
#: includes/admin/settings/register-settings.php:673
|
3646 |
msgid "Check this to enable AJAX for the shopping cart."
|
3647 |
msgstr ""
|
3648 |
|
3649 |
#: includes/admin/settings/register-settings.php:676
|
3650 |
+
msgid "Enabling AJAX"
|
3651 |
msgstr ""
|
3652 |
|
3653 |
#: includes/admin/settings/register-settings.php:677
|
3654 |
+
msgid ""
|
3655 |
+
"With AJAX enabled, customers can perform cart actions like adding and "
|
3656 |
+
"removing items from their shopping cart without pages having to be "
|
3657 |
+
"reloaded. This also creates fewer steps during the checkout process."
|
3658 |
+
msgstr ""
|
3659 |
+
|
3660 |
+
#: includes/admin/settings/register-settings.php:681
|
3661 |
+
#: includes/admin/settings/register-settings.php:684
|
3662 |
+
msgid "Redirect to Checkout"
|
3663 |
msgstr ""
|
3664 |
|
3665 |
#: includes/admin/settings/register-settings.php:682
|
3666 |
+
msgid "Immediately redirect to checkout after adding an item to the cart?"
|
3667 |
+
msgstr ""
|
3668 |
+
|
3669 |
+
#: includes/admin/settings/register-settings.php:685
|
3670 |
+
msgid ""
|
3671 |
+
"When enabled, once an item has been added to the cart, the customer will be "
|
3672 |
+
"redirected directly to your checkout page. This is useful for stores that "
|
3673 |
+
"sell single items."
|
3674 |
+
msgstr ""
|
3675 |
+
|
3676 |
+
#: includes/admin/settings/register-settings.php:689
|
3677 |
msgid "Item Quantities"
|
3678 |
msgstr ""
|
3679 |
|
3680 |
+
#: includes/admin/settings/register-settings.php:690
|
3681 |
msgid "Allow item quantities to be changed."
|
3682 |
msgstr ""
|
3683 |
|
3684 |
+
#: includes/admin/settings/register-settings.php:695
|
3685 |
msgid "Remove Data on Uninstall?"
|
3686 |
msgstr ""
|
3687 |
|
3688 |
+
#: includes/admin/settings/register-settings.php:696
|
3689 |
msgid ""
|
3690 |
"Check this box if you would like EDD to completely remove all of its data "
|
3691 |
"when the plugin is deleted."
|
3692 |
msgstr ""
|
3693 |
|
3694 |
+
#: includes/admin/settings/register-settings.php:703
|
3695 |
+
#: includes/admin/settings/register-settings.php:1215
|
3696 |
msgid "Checkout Settings"
|
3697 |
msgstr ""
|
3698 |
|
3699 |
+
#: includes/admin/settings/register-settings.php:708
|
3700 |
msgid "Enforce SSL on Checkout"
|
3701 |
msgstr ""
|
3702 |
|
3703 |
+
#: includes/admin/settings/register-settings.php:709
|
3704 |
msgid ""
|
3705 |
"Check this to force users to be redirected to the secure checkout page. You "
|
3706 |
"must have an SSL certificate installed to use this option."
|
3707 |
msgstr ""
|
3708 |
|
3709 |
+
#: includes/admin/settings/register-settings.php:714
|
3710 |
msgid "Disable Guest Checkout"
|
3711 |
msgstr ""
|
3712 |
|
3713 |
+
#: includes/admin/settings/register-settings.php:715
|
3714 |
msgid "Require that users be logged-in to purchase files."
|
3715 |
msgstr ""
|
3716 |
|
3717 |
+
#: includes/admin/settings/register-settings.php:717
|
3718 |
+
msgid "Disabling Guest Checkout"
|
3719 |
+
msgstr ""
|
3720 |
+
|
3721 |
+
#: includes/admin/settings/register-settings.php:718
|
3722 |
+
msgid ""
|
3723 |
+
"You can require that customers create and login to user accounts prior to "
|
3724 |
+
"purchasing from your store by enabling this option. When unchecked, users "
|
3725 |
+
"can purchase without being logged in by using their name and email address."
|
3726 |
+
msgstr ""
|
3727 |
+
|
3728 |
+
#: includes/admin/settings/register-settings.php:722
|
3729 |
msgid "Show Register / Login Form?"
|
3730 |
msgstr ""
|
3731 |
|
3732 |
+
#: includes/admin/settings/register-settings.php:723
|
3733 |
msgid ""
|
3734 |
"Display the registration and login forms on the checkout page for "
|
3735 |
"non-logged-in users."
|
3736 |
msgstr ""
|
3737 |
|
3738 |
+
#: includes/admin/settings/register-settings.php:727
|
3739 |
msgid "Registration and Login Forms"
|
3740 |
msgstr ""
|
3741 |
|
3742 |
+
#: includes/admin/settings/register-settings.php:728
|
3743 |
msgid "Registration Form Only"
|
3744 |
msgstr ""
|
3745 |
|
3746 |
+
#: includes/admin/settings/register-settings.php:729
|
3747 |
msgid "Login Form Only"
|
3748 |
msgstr ""
|
3749 |
|
3750 |
+
#: includes/admin/settings/register-settings.php:735
|
3751 |
msgid "Multiple Discounts"
|
3752 |
msgstr ""
|
3753 |
|
3754 |
+
#: includes/admin/settings/register-settings.php:736
|
3755 |
msgid "Allow customers to use multiple discounts on the same purchase?"
|
3756 |
msgstr ""
|
3757 |
|
3758 |
+
#: includes/admin/settings/register-settings.php:741
|
3759 |
msgid "Enable Cart Saving"
|
3760 |
msgstr ""
|
3761 |
|
3762 |
+
#: includes/admin/settings/register-settings.php:742
|
3763 |
msgid "Check this to enable cart saving on the checkout."
|
3764 |
msgstr ""
|
3765 |
|
3766 |
+
#: includes/admin/settings/register-settings.php:744
|
3767 |
+
msgid "Cart Saving"
|
|
|
3768 |
msgstr ""
|
3769 |
|
3770 |
#: includes/admin/settings/register-settings.php:745
|
3771 |
+
msgid ""
|
3772 |
+
"Cart saving allows shoppers to create a temporary link to their current "
|
3773 |
+
"shopping cart so they can come back to it later, or share it with someone."
|
3774 |
+
msgstr ""
|
3775 |
+
|
3776 |
+
#: includes/admin/settings/register-settings.php:751
|
3777 |
+
#: includes/admin/settings/register-settings.php:1216
|
3778 |
+
msgid "Button Text"
|
3779 |
+
msgstr ""
|
3780 |
+
|
3781 |
+
#: includes/admin/settings/register-settings.php:756
|
3782 |
msgid "Complete Purchase Text"
|
3783 |
msgstr ""
|
3784 |
|
3785 |
+
#: includes/admin/settings/register-settings.php:757
|
3786 |
msgid "The button label for completing a purchase."
|
3787 |
msgstr ""
|
3788 |
|
3789 |
+
#: includes/admin/settings/register-settings.php:763
|
3790 |
msgid "Add to Cart Text"
|
3791 |
msgstr ""
|
3792 |
|
3793 |
+
#: includes/admin/settings/register-settings.php:764
|
3794 |
msgid "Text shown on the Add to Cart Buttons."
|
3795 |
msgstr ""
|
3796 |
|
3797 |
+
#: includes/admin/settings/register-settings.php:770
|
3798 |
msgid "Buy Now Text"
|
3799 |
msgstr ""
|
3800 |
|
3801 |
+
#: includes/admin/settings/register-settings.php:771
|
3802 |
msgid "Text shown on the Buy Now Buttons."
|
3803 |
msgstr ""
|
3804 |
|
3805 |
+
#: includes/admin/settings/register-settings.php:779
|
3806 |
msgid "File Download Settings"
|
3807 |
msgstr ""
|
3808 |
|
3809 |
+
#: includes/admin/settings/register-settings.php:784
|
3810 |
+
#: includes/admin/settings/register-settings.php:787
|
3811 |
msgid "Download Method"
|
3812 |
msgstr ""
|
3813 |
|
3814 |
+
#: includes/admin/settings/register-settings.php:785
|
3815 |
msgid "Select the file download method. Note, not all methods work on all servers."
|
3816 |
msgstr ""
|
3817 |
|
3818 |
+
#: includes/admin/settings/register-settings.php:788
|
3819 |
+
msgid ""
|
3820 |
+
"Due to its consistency in multiple platforms and better file protection, "
|
3821 |
+
"'forced' is the default method. Because Easy Digital Downloads uses PHP to "
|
3822 |
+
"process the file with the 'forced' method, larger files can cause problems "
|
3823 |
+
"with delivery, resulting in hitting the 'max execution time' of the server. "
|
3824 |
+
"If users are getting 404 or 403 errors when trying to access their "
|
3825 |
+
"purchased files when using the 'forced' method, changing to the 'redirect' "
|
3826 |
+
"method can help resolve this."
|
3827 |
+
msgstr ""
|
3828 |
+
|
3829 |
+
#: includes/admin/settings/register-settings.php:790
|
3830 |
msgid "Forced"
|
3831 |
msgstr ""
|
3832 |
|
3833 |
+
#: includes/admin/settings/register-settings.php:791
|
3834 |
msgid "Redirect"
|
3835 |
msgstr ""
|
3836 |
|
3837 |
+
#: includes/admin/settings/register-settings.php:796
|
3838 |
msgid "Symlink File Downloads?"
|
3839 |
msgstr ""
|
3840 |
|
3841 |
+
#: includes/admin/settings/register-settings.php:797
|
3842 |
msgid ""
|
3843 |
"Check this if you are delivering really large files or having problems with "
|
3844 |
"file downloads completing."
|
3845 |
msgstr ""
|
3846 |
|
3847 |
+
#: includes/admin/settings/register-settings.php:803
|
3848 |
msgid ""
|
3849 |
"The maximum number of times files can be downloaded for purchases. Can be "
|
3850 |
"overwritten for each %s."
|
3851 |
msgstr ""
|
3852 |
|
3853 |
+
#: includes/admin/settings/register-settings.php:806
|
3854 |
+
msgid "File Download Limits"
|
3855 |
+
msgstr ""
|
3856 |
+
|
3857 |
+
#: includes/admin/settings/register-settings.php:807
|
3858 |
+
msgid ""
|
3859 |
+
"Set the global default for the number of times a customer can download "
|
3860 |
+
"items they purchase. Using a value of 0 is unlimited. This can be defined "
|
3861 |
+
"on a %s-specific level as well. Download limits can also be reset for an "
|
3862 |
+
"individual purchase."
|
3863 |
+
msgstr ""
|
3864 |
+
|
3865 |
+
#: includes/admin/settings/register-settings.php:811
|
3866 |
+
#: includes/admin/settings/register-settings.php:813
|
3867 |
msgid "Download Link Expiration"
|
3868 |
msgstr ""
|
3869 |
|
3870 |
+
#: includes/admin/settings/register-settings.php:812
|
3871 |
msgid ""
|
3872 |
"How long should download links be valid for? Default is 24 hours from the "
|
3873 |
"time they are generated. Enter a time in hours."
|
3874 |
msgstr ""
|
3875 |
|
3876 |
+
#: includes/admin/settings/register-settings.php:814
|
3877 |
+
msgid ""
|
3878 |
+
"When a customer receives a link to their downloads via email, in their "
|
3879 |
+
"receipt, or in their purchase history, the link will only be valid for the "
|
3880 |
+
"timeframe (in hours) defined in this setting. Sending a new purchase "
|
3881 |
+
"receipt or visiting the account page will re-generate a valid link for the "
|
3882 |
+
"customer."
|
3883 |
+
msgstr ""
|
3884 |
+
|
3885 |
+
#: includes/admin/settings/register-settings.php:822
|
3886 |
msgid "Disable Redownload?"
|
3887 |
msgstr ""
|
3888 |
|
3889 |
+
#: includes/admin/settings/register-settings.php:823
|
3890 |
msgid ""
|
3891 |
"Check this if you do not want to allow users to redownload items from their "
|
3892 |
"purchase history."
|
3893 |
msgstr ""
|
3894 |
|
3895 |
+
#: includes/admin/settings/register-settings.php:830
|
3896 |
+
#: includes/admin/settings/register-settings.php:1218
|
3897 |
msgid "Accounting Settings"
|
3898 |
msgstr ""
|
3899 |
|
3900 |
+
#: includes/admin/settings/register-settings.php:835
|
3901 |
msgid "Enable SKU Entry"
|
3902 |
msgstr ""
|
3903 |
|
3904 |
+
#: includes/admin/settings/register-settings.php:836
|
3905 |
msgid ""
|
3906 |
"Check this box to allow entry of product SKUs. SKUs will be shown on "
|
3907 |
"purchase receipt and exported purchase histories."
|
3908 |
msgstr ""
|
3909 |
|
3910 |
+
#: includes/admin/settings/register-settings.php:841
|
3911 |
msgid "Sequential Order Numbers"
|
3912 |
msgstr ""
|
3913 |
|
3914 |
+
#: includes/admin/settings/register-settings.php:842
|
3915 |
msgid "Check this box to enable sequential order numbers."
|
3916 |
msgstr ""
|
3917 |
|
3918 |
+
#: includes/admin/settings/register-settings.php:847
|
3919 |
msgid "Sequential Starting Number"
|
3920 |
msgstr ""
|
3921 |
|
3922 |
+
#: includes/admin/settings/register-settings.php:848
|
3923 |
msgid "The number at which the sequence should begin."
|
3924 |
msgstr ""
|
3925 |
|
3926 |
+
#: includes/admin/settings/register-settings.php:855
|
3927 |
msgid "Sequential Number Prefix"
|
3928 |
msgstr ""
|
3929 |
|
3930 |
+
#: includes/admin/settings/register-settings.php:856
|
3931 |
msgid "A prefix to prepend to all sequential order numbers."
|
3932 |
msgstr ""
|
3933 |
|
3934 |
+
#: includes/admin/settings/register-settings.php:861
|
3935 |
msgid "Sequential Number Postfix"
|
3936 |
msgstr ""
|
3937 |
|
3938 |
+
#: includes/admin/settings/register-settings.php:862
|
3939 |
msgid "A postfix to append to all sequential order numbers."
|
3940 |
msgstr ""
|
3941 |
|
3942 |
+
#: includes/admin/settings/register-settings.php:869
|
3943 |
msgid "Agreement Settings"
|
3944 |
msgstr ""
|
3945 |
|
3946 |
+
#: includes/admin/settings/register-settings.php:874
|
3947 |
msgid "Agree to Terms"
|
3948 |
msgstr ""
|
3949 |
|
3950 |
+
#: includes/admin/settings/register-settings.php:875
|
3951 |
msgid ""
|
3952 |
"Check this to show an agree to terms on the checkout that users must agree "
|
3953 |
"to before purchasing."
|
3954 |
msgstr ""
|
3955 |
|
3956 |
+
#: includes/admin/settings/register-settings.php:880
|
3957 |
msgid "Agree to Terms Label"
|
3958 |
msgstr ""
|
3959 |
|
3960 |
+
#: includes/admin/settings/register-settings.php:881
|
3961 |
msgid "Label shown next to the agree to terms check box."
|
3962 |
msgstr ""
|
3963 |
|
3964 |
+
#: includes/admin/settings/register-settings.php:887
|
3965 |
msgid "Agreement Text"
|
3966 |
msgstr ""
|
3967 |
|
3968 |
+
#: includes/admin/settings/register-settings.php:888
|
3969 |
msgid "If Agree to Terms is checked, enter the agreement terms here."
|
3970 |
msgstr ""
|
3971 |
|
3972 |
+
#: includes/admin/settings/register-settings.php:992
|
3973 |
msgid "Settings updated."
|
3974 |
msgstr ""
|
3975 |
|
3976 |
+
#: includes/admin/settings/register-settings.php:1145
|
3977 |
msgid "Licenses"
|
3978 |
msgstr ""
|
3979 |
|
3980 |
+
#: includes/admin/settings/register-settings.php:1148
|
3981 |
msgid "Misc"
|
3982 |
msgstr ""
|
3983 |
|
3984 |
+
#: includes/admin/settings/register-settings.php:1196
|
3985 |
+
#: includes/gateways/functions.php:25 includes/gateways/paypal-standard.php:33
|
3986 |
msgid "PayPal Standard"
|
3987 |
msgstr ""
|
3988 |
|
3989 |
+
#: includes/admin/settings/register-settings.php:1201
|
3990 |
msgid "New Sale Notifications"
|
3991 |
msgstr ""
|
3992 |
|
3993 |
+
#: includes/admin/settings/register-settings.php:1210
|
3994 |
msgid "Main"
|
3995 |
msgstr ""
|
3996 |
|
3997 |
+
#: includes/admin/settings/register-settings.php:1219
|
3998 |
msgid "Terms of Agreement"
|
3999 |
msgstr ""
|
4000 |
|
4001 |
+
#: includes/admin/settings/register-settings.php:1610
|
4002 |
msgid "The callback function used for the %s setting is missing."
|
4003 |
msgstr ""
|
4004 |
|
4005 |
+
#: includes/admin/settings/register-settings.php:1745
|
4006 |
msgid "Upload File"
|
4007 |
msgstr ""
|
4008 |
|
4009 |
+
#: includes/admin/settings/register-settings.php:1833
|
|
|
|
|
|
|
|
|
4010 |
msgid "Country Wide"
|
4011 |
msgstr ""
|
4012 |
|
4013 |
+
#: includes/admin/settings/register-settings.php:1834
|
4014 |
msgid "Rate"
|
4015 |
msgstr ""
|
4016 |
|
4017 |
+
#: includes/admin/settings/register-settings.php:1851
|
4018 |
+
#: includes/admin/settings/register-settings.php:1895
|
4019 |
msgid "Choose a country"
|
4020 |
msgstr ""
|
4021 |
|
4022 |
+
#: includes/admin/settings/register-settings.php:1866
|
4023 |
msgid "Choose a state"
|
4024 |
msgstr ""
|
4025 |
|
4026 |
+
#: includes/admin/settings/register-settings.php:1878
|
4027 |
+
#: includes/admin/settings/register-settings.php:1905
|
4028 |
msgid "Apply to whole country"
|
4029 |
msgstr ""
|
4030 |
|
4031 |
+
#: includes/admin/settings/register-settings.php:1881
|
4032 |
+
#: includes/admin/settings/register-settings.php:1908
|
4033 |
msgid "Remove Rate"
|
4034 |
msgstr ""
|
4035 |
|
4036 |
+
#: includes/admin/settings/register-settings.php:1913
|
4037 |
msgid "Add Tax Rate"
|
4038 |
msgstr ""
|
4039 |
|
4040 |
+
#: includes/admin/settings/register-settings.php:1966
|
4041 |
msgid ""
|
4042 |
+
"Your license key expired on %s. Please <a href=\"%s\" "
|
4043 |
+
"target=\"_blank\">renew your license key</a>."
|
4044 |
msgstr ""
|
4045 |
|
4046 |
+
#: includes/admin/settings/register-settings.php:1979
|
4047 |
msgid ""
|
4048 |
+
"Your license key has been disabled. Please <a href=\"%s\" "
|
4049 |
+
"target=\"_blank\">contact support</a> for more information."
|
4050 |
msgstr ""
|
4051 |
|
4052 |
+
#: includes/admin/settings/register-settings.php:1991
|
4053 |
msgid ""
|
4054 |
+
"Invalid license. Please <a href=\"%s\" target=\"_blank\">visit your account "
|
4055 |
+
"page</a> and verify it."
|
|
|
4056 |
msgstr ""
|
4057 |
|
4058 |
+
#: includes/admin/settings/register-settings.php:2004
|
4059 |
+
msgid ""
|
4060 |
+
"Your %s is not active for this URL. Please <a href=\"%s\" "
|
4061 |
+
"target=\"_blank\">visit your account page</a> to manage your license key "
|
4062 |
+
"URLs."
|
4063 |
+
msgstr ""
|
4064 |
+
|
4065 |
+
#: includes/admin/settings/register-settings.php:2016
|
4066 |
+
msgid "This appears to be an invalid license key for %s."
|
4067 |
msgstr ""
|
4068 |
|
4069 |
+
#: includes/admin/settings/register-settings.php:2025
|
4070 |
msgid ""
|
4071 |
"Your license key has reached its activation limit. <a href=\"%s\">View "
|
4072 |
"possible upgrades</a> now."
|
4073 |
msgstr ""
|
4074 |
|
4075 |
+
#: includes/admin/settings/register-settings.php:2051
|
4076 |
msgid "License key never expires."
|
4077 |
msgstr ""
|
4078 |
|
4079 |
+
#: includes/admin/settings/register-settings.php:2058
|
4080 |
msgid ""
|
4081 |
"Your license key expires soon! It expires on %s. <a href=\"%s\" "
|
4082 |
+
"target=\"_blank\">Renew your license key</a>."
|
4083 |
msgstr ""
|
4084 |
|
4085 |
+
#: includes/admin/settings/register-settings.php:2068
|
4086 |
msgid "Your license key expires on %s."
|
4087 |
msgstr ""
|
4088 |
|
4089 |
+
#: includes/admin/settings/register-settings.php:2086
|
4090 |
+
msgid "To receive updates, please enter your valid %s license key."
|
4091 |
msgstr ""
|
4092 |
|
4093 |
+
#: includes/admin/settings/register-settings.php:2097
|
4094 |
+
msgid "Deactivate License"
|
|
|
4095 |
msgstr ""
|
4096 |
|
4097 |
+
#: includes/admin/thickbox.php:29 includes/admin/thickbox.php:130
|
4098 |
+
msgid "Insert %s"
|
4099 |
msgstr ""
|
4100 |
|
4101 |
+
#: includes/admin/thickbox.php:62
|
4102 |
msgid "You must choose a download"
|
4103 |
msgstr ""
|
4104 |
|
4105 |
+
#: includes/admin/thickbox.php:88
|
4106 |
msgid "Use the form below to insert the short code for purchasing a %s"
|
4107 |
msgstr ""
|
4108 |
|
4109 |
+
#: includes/admin/thickbox.php:95
|
4110 |
msgid "Choose the button behavior"
|
4111 |
msgstr ""
|
4112 |
|
4113 |
+
#: includes/admin/thickbox.php:97
|
4114 |
msgid "Direct Purchase Link"
|
4115 |
msgstr ""
|
4116 |
|
4117 |
+
#: includes/admin/thickbox.php:103
|
4118 |
msgid "Choose a style"
|
4119 |
msgstr ""
|
4120 |
|
4121 |
+
#: includes/admin/thickbox.php:117
|
4122 |
msgid "Choose a button color"
|
4123 |
msgstr ""
|
4124 |
|
4125 |
+
#: includes/admin/thickbox.php:127
|
4126 |
msgid "Link text . . ."
|
4127 |
msgstr ""
|
4128 |
|
4185 |
msgid "Please select an option"
|
4186 |
msgstr ""
|
4187 |
|
4188 |
+
#: includes/admin/tools.php:140
|
4189 |
+
msgid "Recount Store Earnings and Sales"
|
4190 |
+
msgstr ""
|
4191 |
+
|
4192 |
+
#: includes/admin/tools.php:141
|
4193 |
+
msgid "Recount Earnings and Sales for a %s"
|
4194 |
+
msgstr ""
|
4195 |
+
|
4196 |
+
#: includes/admin/tools.php:142
|
4197 |
+
msgid "Recount Earnings and Sales for All %s"
|
4198 |
+
msgstr ""
|
4199 |
+
|
4200 |
+
#: includes/admin/tools.php:145
|
4201 |
+
msgid "Reset Store"
|
4202 |
+
msgstr ""
|
4203 |
+
|
4204 |
+
#: includes/admin/tools.php:164
|
4205 |
+
msgid "Recalculates the total store earnings and sales."
|
4206 |
+
msgstr ""
|
4207 |
+
|
4208 |
+
#: includes/admin/tools.php:165
|
4209 |
+
msgid "Recalculates the earnings and sales stats for a specific %s."
|
4210 |
+
msgstr ""
|
4211 |
+
|
4212 |
+
#: includes/admin/tools.php:166
|
4213 |
+
msgid "Recalculates the earnings and sales stats for all %s."
|
4214 |
+
msgstr ""
|
4215 |
+
|
4216 |
+
#: includes/admin/tools.php:167
|
4217 |
+
msgid "Recalculates the lifetime value and purchase counts for all customers."
|
4218 |
+
msgstr ""
|
4219 |
+
|
4220 |
+
#: includes/admin/tools.php:169
|
4221 |
+
msgid ""
|
4222 |
+
"<strong>Deletes</strong> all payment records, customers, and related log "
|
4223 |
+
"entries."
|
4224 |
+
msgstr ""
|
4225 |
+
|
4226 |
+
#: includes/admin/tools.php:199 includes/admin/tools.php:207
|
4227 |
+
msgid "Clear Incomplete Upgrade Notice"
|
4228 |
+
msgstr ""
|
4229 |
+
|
4230 |
+
#: includes/admin/tools.php:201
|
4231 |
+
msgid ""
|
4232 |
+
"Sometimes a database upgrade notice may not be cleared after an upgrade is "
|
4233 |
+
"completed due to conflicts with other extensions or other minor issues."
|
4234 |
+
msgstr ""
|
4235 |
+
|
4236 |
+
#: includes/admin/tools.php:202
|
4237 |
+
msgid ""
|
4238 |
+
"If you're certain these upgrades have been completed, you can clear these "
|
4239 |
+
"upgrade notices by clicking the button below. If you have any questions "
|
4240 |
+
"about this, please contact the Easy Digital Downloads support team and "
|
4241 |
+
"we'll be happy to help."
|
4242 |
+
msgstr ""
|
4243 |
+
|
4244 |
+
#: includes/admin/tools.php:239
|
4245 |
+
msgid ""
|
4246 |
+
"These API keys allow you to use the <a href=\"%s\">EDD REST API</a> to "
|
4247 |
+
"retrieve store data in JSON or XML for external applications or devices, "
|
4248 |
+
"such as the <a href=\"%s\">EDD mobile app</a>."
|
4249 |
+
msgstr ""
|
4250 |
+
|
4251 |
+
#: includes/admin/tools.php:328
|
4252 |
+
msgid "Import Payment History"
|
4253 |
+
msgstr ""
|
4254 |
+
|
4255 |
+
#: includes/admin/tools.php:330
|
4256 |
+
msgid "Import a CSV file of payment records."
|
4257 |
+
msgstr ""
|
4258 |
+
|
4259 |
+
#: includes/admin/tools.php:340 includes/admin/tools.php:622
|
4260 |
+
msgid "Import CSV"
|
4261 |
+
msgstr ""
|
4262 |
+
|
4263 |
+
#: includes/admin/tools.php:350
|
4264 |
+
msgid ""
|
4265 |
+
"Each column loaded from the CSV needs to be mapped to a payment field. "
|
4266 |
+
"Select the column that should be mapped to each field below. Any columns "
|
4267 |
+
"not needed can be ignored. See <a href=\"%s\" target=\"_blank\">this "
|
4268 |
+
"guide</a> for assistance with importing payment records."
|
4269 |
+
msgstr ""
|
4270 |
+
|
4271 |
+
#: includes/admin/tools.php:359
|
4272 |
+
msgid "Payment Field"
|
4273 |
+
msgstr ""
|
4274 |
+
|
4275 |
+
#: includes/admin/tools.php:360 includes/admin/tools.php:642
|
4276 |
+
msgid "CSV Column"
|
4277 |
+
msgstr ""
|
4278 |
+
|
4279 |
+
#: includes/admin/tools.php:361 includes/admin/tools.php:643
|
4280 |
+
msgid "Data Preview"
|
4281 |
+
msgstr ""
|
4282 |
+
|
4283 |
+
#: includes/admin/tools.php:366
|
4284 |
+
msgid "Currency Code"
|
4285 |
+
msgstr ""
|
4286 |
+
|
4287 |
+
#: includes/admin/tools.php:369 includes/admin/tools.php:378
|
4288 |
+
#: includes/admin/tools.php:387 includes/admin/tools.php:396
|
4289 |
+
#: includes/admin/tools.php:405 includes/admin/tools.php:414
|
4290 |
+
#: includes/admin/tools.php:423 includes/admin/tools.php:432
|
4291 |
+
#: includes/admin/tools.php:441 includes/admin/tools.php:450
|
4292 |
+
#: includes/admin/tools.php:459 includes/admin/tools.php:468
|
4293 |
+
#: includes/admin/tools.php:477 includes/admin/tools.php:486
|
4294 |
+
#: includes/admin/tools.php:495 includes/admin/tools.php:504
|
4295 |
+
#: includes/admin/tools.php:513 includes/admin/tools.php:522
|
4296 |
+
#: includes/admin/tools.php:531 includes/admin/tools.php:540
|
4297 |
+
#: includes/admin/tools.php:549 includes/admin/tools.php:558
|
4298 |
+
#: includes/admin/tools.php:567 includes/admin/tools.php:576
|
4299 |
+
#: includes/admin/tools.php:585 includes/admin/tools.php:594
|
4300 |
+
#: includes/admin/tools.php:651 includes/admin/tools.php:660
|
4301 |
+
#: includes/admin/tools.php:669 includes/admin/tools.php:678
|
4302 |
+
#: includes/admin/tools.php:687 includes/admin/tools.php:696
|
4303 |
+
#: includes/admin/tools.php:705 includes/admin/tools.php:714
|
4304 |
+
#: includes/admin/tools.php:723 includes/admin/tools.php:732
|
4305 |
+
#: includes/admin/tools.php:741 includes/admin/tools.php:750
|
4306 |
+
#: includes/admin/tools.php:759 includes/admin/tools.php:768
|
4307 |
+
#: includes/admin/tools.php:777 includes/admin/tools.php:786
|
4308 |
+
#: includes/admin/tools.php:795
|
4309 |
+
msgid "- Ignore this field -"
|
4310 |
+
msgstr ""
|
4311 |
+
|
4312 |
+
#: includes/admin/tools.php:372 includes/admin/tools.php:381
|
4313 |
+
#: includes/admin/tools.php:390 includes/admin/tools.php:399
|
4314 |
+
#: includes/admin/tools.php:408 includes/admin/tools.php:417
|
4315 |
+
#: includes/admin/tools.php:426 includes/admin/tools.php:435
|
4316 |
+
#: includes/admin/tools.php:444 includes/admin/tools.php:453
|
4317 |
+
#: includes/admin/tools.php:462 includes/admin/tools.php:471
|
4318 |
+
#: includes/admin/tools.php:480 includes/admin/tools.php:489
|
4319 |
+
#: includes/admin/tools.php:498 includes/admin/tools.php:507
|
4320 |
+
#: includes/admin/tools.php:516 includes/admin/tools.php:525
|
4321 |
+
#: includes/admin/tools.php:534 includes/admin/tools.php:543
|
4322 |
+
#: includes/admin/tools.php:552 includes/admin/tools.php:561
|
4323 |
+
#: includes/admin/tools.php:570 includes/admin/tools.php:579
|
4324 |
+
#: includes/admin/tools.php:588 includes/admin/tools.php:597
|
4325 |
+
#: includes/admin/tools.php:654 includes/admin/tools.php:663
|
4326 |
+
#: includes/admin/tools.php:672 includes/admin/tools.php:681
|
4327 |
+
#: includes/admin/tools.php:690 includes/admin/tools.php:699
|
4328 |
+
#: includes/admin/tools.php:708 includes/admin/tools.php:717
|
4329 |
+
#: includes/admin/tools.php:726 includes/admin/tools.php:735
|
4330 |
+
#: includes/admin/tools.php:744 includes/admin/tools.php:753
|
4331 |
+
#: includes/admin/tools.php:762 includes/admin/tools.php:771
|
4332 |
+
#: includes/admin/tools.php:780 includes/admin/tools.php:789
|
4333 |
+
#: includes/admin/tools.php:798
|
4334 |
+
msgid "- select field to preview data -"
|
4335 |
+
msgstr ""
|
4336 |
+
|
4337 |
+
#: includes/admin/tools.php:411
|
4338 |
+
msgid "Discount Code(s)"
|
4339 |
+
msgstr ""
|
4340 |
+
|
4341 |
+
#: includes/admin/tools.php:438
|
4342 |
+
msgid "Parent Payment ID"
|
4343 |
+
msgstr ""
|
4344 |
+
|
4345 |
+
#: includes/admin/tools.php:483
|
4346 |
+
msgid "Purchased Product(s)"
|
4347 |
+
msgstr ""
|
4348 |
+
|
4349 |
+
#: includes/admin/tools.php:501 templates/checkout_cart.php:102
|
4350 |
+
#: templates/shortcode-receipt.php:98
|
4351 |
+
msgid "Subtotal"
|
4352 |
+
msgstr ""
|
4353 |
+
|
4354 |
+
#: includes/admin/tools.php:519 templates/checkout_cart.php:129
|
4355 |
+
msgid "Total"
|
4356 |
+
msgstr ""
|
4357 |
+
|
4358 |
+
#: includes/admin/tools.php:546
|
4359 |
+
msgid "Address Line 1"
|
4360 |
+
msgstr ""
|
4361 |
+
|
4362 |
+
#: includes/admin/tools.php:555
|
4363 |
+
msgid "Address Line 2"
|
4364 |
+
msgstr ""
|
4365 |
+
|
4366 |
+
#: includes/admin/tools.php:602 includes/admin/tools.php:803
|
4367 |
+
msgid "Process Import"
|
4368 |
+
msgstr ""
|
4369 |
+
|
4370 |
+
#: includes/admin/tools.php:610
|
4371 |
+
msgid "Import Download Products"
|
4372 |
+
msgstr ""
|
4373 |
+
|
4374 |
+
#: includes/admin/tools.php:612
|
4375 |
+
msgid "Import a CSV file of products."
|
4376 |
+
msgstr ""
|
4377 |
+
|
4378 |
+
#: includes/admin/tools.php:632
|
4379 |
+
msgid ""
|
4380 |
+
"Each column loaded from the CSV needs to be mapped to a Download product "
|
4381 |
+
"field. Select the column that should be mapped to each field below. Any "
|
4382 |
+
"columns not needed can be ignored. See <a href=\"%s\" "
|
4383 |
+
"target=\"_blank\">this guide</a> for assistance with importing Download "
|
4384 |
+
"products."
|
4385 |
+
msgstr ""
|
4386 |
+
|
4387 |
+
#: includes/admin/tools.php:641
|
4388 |
+
msgid "Product Field"
|
4389 |
+
msgstr ""
|
4390 |
+
|
4391 |
+
#: includes/admin/tools.php:648
|
4392 |
+
msgid "Product Author"
|
4393 |
+
msgstr ""
|
4394 |
+
|
4395 |
+
#: includes/admin/tools.php:657
|
4396 |
+
msgid "Product Categories"
|
4397 |
+
msgstr ""
|
4398 |
+
|
4399 |
+
#: includes/admin/tools.php:666
|
4400 |
+
msgid "Product Creation Date"
|
4401 |
msgstr ""
|
4402 |
|
4403 |
+
#: includes/admin/tools.php:675
|
4404 |
+
msgid "Product Description"
|
4405 |
msgstr ""
|
4406 |
|
4407 |
+
#: includes/admin/tools.php:684
|
4408 |
+
msgid "Product Excerpt"
|
4409 |
msgstr ""
|
4410 |
|
4411 |
+
#: includes/admin/tools.php:693
|
4412 |
+
msgid "Product Image"
|
4413 |
msgstr ""
|
4414 |
|
4415 |
+
#: includes/admin/tools.php:702
|
4416 |
+
msgid "Product Notes"
|
4417 |
msgstr ""
|
4418 |
|
4419 |
+
#: includes/admin/tools.php:711
|
4420 |
+
msgid "Product Price(s)"
|
4421 |
msgstr ""
|
4422 |
|
4423 |
+
#: includes/admin/tools.php:720
|
4424 |
+
msgid "Product SKU"
|
4425 |
msgstr ""
|
4426 |
|
4427 |
+
#: includes/admin/tools.php:729
|
4428 |
+
msgid "Product Slug"
|
4429 |
msgstr ""
|
4430 |
|
4431 |
+
#: includes/admin/tools.php:738
|
4432 |
+
msgid "Product Status"
|
|
|
|
|
4433 |
msgstr ""
|
4434 |
|
4435 |
+
#: includes/admin/tools.php:747
|
4436 |
+
msgid "Product Tags"
|
4437 |
msgstr ""
|
4438 |
|
4439 |
+
#: includes/admin/tools.php:756
|
4440 |
+
msgid "Product Title"
|
|
|
|
|
4441 |
msgstr ""
|
4442 |
|
4443 |
+
#: includes/admin/tools.php:765 includes/admin/welcome.php:335
|
4444 |
+
msgid "Download Files"
|
|
|
|
|
|
|
|
|
4445 |
msgstr ""
|
4446 |
|
4447 |
+
#: includes/admin/tools.php:783
|
4448 |
+
msgid "Sale Count"
|
|
|
|
|
|
|
4449 |
msgstr ""
|
4450 |
|
4451 |
+
#: includes/admin/tools.php:811
|
4452 |
msgid "Export Settings"
|
4453 |
msgstr ""
|
4454 |
|
4455 |
+
#: includes/admin/tools.php:813
|
4456 |
msgid ""
|
4457 |
"Export the Easy Digital Downloads settings for this site as a .json file. "
|
4458 |
"This allows you to easily import the configuration into another site."
|
4459 |
msgstr ""
|
4460 |
|
4461 |
+
#: includes/admin/tools.php:814
|
4462 |
msgid ""
|
4463 |
"To export shop data (purchases, customers, etc), visit the <a "
|
4464 |
"href=\"%s\">Reports</a> page."
|
4465 |
msgstr ""
|
4466 |
|
4467 |
+
#: includes/admin/tools.php:826
|
4468 |
msgid "Import Settings"
|
4469 |
msgstr ""
|
4470 |
|
4471 |
+
#: includes/admin/tools.php:828
|
4472 |
msgid ""
|
4473 |
"Import the Easy Digital Downloads settings from a .json file. This file can "
|
4474 |
"be obtained by exporting the settings on another site using the form above."
|
4475 |
msgstr ""
|
4476 |
|
4477 |
+
#: includes/admin/tools.php:836
|
4478 |
msgid "Import"
|
4479 |
msgstr ""
|
4480 |
|
4481 |
+
#: includes/admin/tools.php:901
|
4482 |
msgid "Please upload a valid .json file"
|
4483 |
msgstr ""
|
4484 |
|
4485 |
+
#: includes/admin/tools.php:907
|
4486 |
msgid "Please upload a file to import"
|
4487 |
msgstr ""
|
4488 |
|
4502 |
msgid "Do not allow"
|
4503 |
msgstr ""
|
4504 |
|
4505 |
+
#: includes/admin/upgrades/upgrade-functions.php:67
|
4506 |
msgid "The Payment History needs to be updated. %s"
|
4507 |
msgstr ""
|
4508 |
|
4509 |
+
#: includes/admin/upgrades/upgrade-functions.php:67
|
4510 |
msgid "Click to Upgrade"
|
4511 |
msgstr ""
|
4512 |
|
4513 |
+
#: includes/admin/upgrades/upgrade-functions.php:73
|
4514 |
msgid ""
|
4515 |
"The Purchase and File Download History in Easy Digital Downloads needs to "
|
4516 |
"be upgraded, click %shere%s to start the upgrade."
|
4517 |
msgstr ""
|
4518 |
|
4519 |
+
#: includes/admin/upgrades/upgrade-functions.php:81
|
4520 |
msgid ""
|
4521 |
"Easy Digital Downloads needs to upgrade the plugin pages, click %shere%s to "
|
4522 |
"start the upgrade."
|
4523 |
msgstr ""
|
4524 |
|
4525 |
+
#: includes/admin/upgrades/upgrade-functions.php:89
|
4526 |
+
#: includes/admin/upgrades/upgrade-functions.php:97
|
4527 |
msgid ""
|
4528 |
"Easy Digital Downloads needs to upgrade the database, click %shere%s to "
|
4529 |
"start the upgrade."
|
4530 |
msgstr ""
|
4531 |
|
4532 |
+
#: includes/admin/upgrades/upgrade-functions.php:109
|
4533 |
msgid ""
|
4534 |
"Easy Digital Downloads needs to complete a database upgrade that was "
|
4535 |
"previously started, click <a href=\"%s\">here</a> to resume the upgrade."
|
4536 |
msgstr ""
|
4537 |
|
4538 |
+
#: includes/admin/upgrades/upgrade-functions.php:120
|
4539 |
msgid ""
|
4540 |
"Easy Digital Downloads needs to upgrade past order numbers to make them "
|
4541 |
"sequential, click <a href=\"%s\">here</a> to start the upgrade."
|
4542 |
msgstr ""
|
4543 |
|
4544 |
+
#: includes/admin/upgrades/upgrade-functions.php:127
|
4545 |
msgid ""
|
4546 |
"Easy Digital Downloads needs to upgrade the customer database, click "
|
4547 |
"%shere%s to start the upgrade."
|
4548 |
msgstr ""
|
4549 |
|
4550 |
+
#: includes/admin/upgrades/upgrade-functions.php:135
|
4551 |
+
#: includes/admin/upgrades/upgrade-functions.php:149
|
4552 |
msgid ""
|
4553 |
"Easy Digital Downloads needs to upgrade the payment database, click <a "
|
4554 |
"href=\"%s\">here</a> to start the upgrade."
|
4555 |
msgstr ""
|
4556 |
|
4557 |
+
#: includes/admin/upgrades/upgrade-functions.php:142
|
4558 |
msgid ""
|
4559 |
"Easy Digital Downloads needs to upgrade the customer database, click <a "
|
4560 |
"href=\"%s\">here</a> to start the upgrade."
|
4561 |
msgstr ""
|
4562 |
|
4563 |
+
#: includes/admin/upgrades/upgrade-functions.php:156
|
4564 |
msgid ""
|
4565 |
"Easy Digital Downloads needs to upgrade the API Key database, click <a "
|
4566 |
"href=\"%s\">here</a> to start the upgrade."
|
4567 |
msgstr ""
|
4568 |
|
4569 |
+
#: includes/admin/upgrades/upgrade-functions.php:163
|
4570 |
msgid ""
|
4571 |
"Easy Digital Downloads needs to upgrade the payments database, click <a "
|
4572 |
"href=\"%s\">here</a> to start the upgrade."
|
4573 |
msgstr ""
|
4574 |
|
4575 |
+
#: includes/admin/upgrades/upgrade-functions.php:194
|
4576 |
+
#: includes/admin/upgrades/upgrade-functions.php:510
|
4577 |
+
#: includes/admin/upgrades/upgrade-functions.php:592
|
4578 |
+
#: includes/admin/upgrades/upgrade-functions.php:703
|
4579 |
+
#: includes/admin/upgrades/upgrade-functions.php:800
|
4580 |
+
#: includes/admin/upgrades/upgrade-functions.php:874
|
4581 |
+
#: includes/admin/upgrades/upgrade-functions.php:1002
|
4582 |
+
#: includes/admin/upgrades/upgrade-functions.php:1087
|
4583 |
msgid "You do not have permission to do shop upgrades"
|
4584 |
msgstr ""
|
4585 |
|
4586 |
+
#: includes/admin/upgrades/upgrade-functions.php:363 includes/install.php:116
|
4587 |
msgid "Transaction Failed"
|
4588 |
msgstr ""
|
4589 |
|
4590 |
+
#: includes/admin/upgrades/upgrade-functions.php:364 includes/install.php:117
|
4591 |
msgid "Your transaction failed, please try again or contact site support."
|
4592 |
msgstr ""
|
4593 |
|
4640 |
msgid "Credits"
|
4641 |
msgstr ""
|
4642 |
|
4643 |
+
#: includes/admin/welcome.php:186
|
4644 |
+
msgid "Additional Customer Emails"
|
4645 |
msgstr ""
|
4646 |
|
4647 |
#: includes/admin/welcome.php:192
|
4648 |
msgid ""
|
4649 |
+
"To help keep track of customers that have multiple email addresses, Easy "
|
4650 |
+
"Digital Downloads now supports storing additional emails on customers. "
|
4651 |
+
"During checkout, customers can use any email address assigned to their "
|
4652 |
+
"account to complete their purchase."
|
4653 |
msgstr ""
|
4654 |
|
4655 |
#: includes/admin/welcome.php:194
|
|
|
|
|
|
|
|
|
4656 |
msgid ""
|
4657 |
+
"Email addresses can be easily added by site administrators at anytime and "
|
4658 |
+
"will also be automatically registered when a customer makes a purchase with "
|
4659 |
+
"an additional email address."
|
4660 |
msgstr ""
|
4661 |
|
4662 |
+
#: includes/admin/welcome.php:196
|
4663 |
+
msgid "Improved Help Text"
|
4664 |
msgstr ""
|
4665 |
|
4666 |
+
#: includes/admin/welcome.php:197
|
4667 |
msgid ""
|
4668 |
+
"While we strive to make Easy Digital Downloads live up to its name, there "
|
4669 |
+
"are always times when certain things are not quite clear. To help alleviate "
|
4670 |
+
"any uncertainty, we have introduced improved descriptions and help texts "
|
4671 |
+
"throughout the plugin. Along with the improved descriptions, we have also "
|
4672 |
+
"added tooltips in many places that offer verbose definitions of options."
|
4673 |
msgstr ""
|
4674 |
|
4675 |
+
#: includes/admin/welcome.php:199
|
4676 |
+
msgid "Better Mobile Checkout"
|
4677 |
msgstr ""
|
4678 |
|
4679 |
+
#: includes/admin/welcome.php:200
|
4680 |
msgid ""
|
4681 |
+
"When purchasing with a debit or credit card from a mobile phone, the card "
|
4682 |
+
"number input field will now properly set the phone’s keyboard to a "
|
4683 |
+
"numerical keyboard."
|
4684 |
msgstr ""
|
4685 |
|
4686 |
+
#: includes/admin/welcome.php:206
|
4687 |
+
msgid "Native Import Options"
|
4688 |
msgstr ""
|
4689 |
|
4690 |
+
#: includes/admin/welcome.php:212
|
4691 |
msgid ""
|
4692 |
+
"We believe you should own your data. We also believe that it should be easy "
|
4693 |
+
"to get data out of <em>and</em> into Easy Digital Downloads. 2.6 introduces "
|
4694 |
+
"native import options for payments and download products."
|
4695 |
msgstr ""
|
4696 |
|
4697 |
+
#: includes/admin/welcome.php:214
|
4698 |
+
msgid "Product Import"
|
4699 |
msgstr ""
|
4700 |
|
4701 |
+
#: includes/admin/welcome.php:215
|
4702 |
msgid ""
|
4703 |
+
"With the new import options, Easy Digital Downloads now makes it easy to "
|
4704 |
+
"import products from a CSV file into your store. Whether you wish to import "
|
4705 |
+
"five products or 50,000, Easy Digital Downloads can now effortlessly handle "
|
4706 |
+
"the import for you."
|
4707 |
msgstr ""
|
4708 |
|
4709 |
+
#: includes/admin/welcome.php:217
|
4710 |
+
msgid "Payment Import"
|
4711 |
msgstr ""
|
4712 |
|
4713 |
+
#: includes/admin/welcome.php:218
|
4714 |
msgid ""
|
4715 |
+
"Sometimes it is necessary to move purchase records from one location to "
|
4716 |
+
"another. Perhaps you are transitioning from another eCommerce system, or "
|
4717 |
+
"from a separate Easy Digital Downloads store; whatever the reason, Easy "
|
4718 |
+
"Digital Downloads now allows you to easily import purchase records from a "
|
4719 |
+
"CSV file."
|
4720 |
msgstr ""
|
4721 |
|
4722 |
+
#: includes/admin/welcome.php:224
|
4723 |
+
msgid "Better Refunds"
|
4724 |
msgstr ""
|
4725 |
|
4726 |
+
#: includes/admin/welcome.php:230
|
4727 |
+
msgid "Refund Processing for PayPal Standard"
|
4728 |
msgstr ""
|
4729 |
|
4730 |
+
#: includes/admin/welcome.php:231
|
4731 |
msgid ""
|
4732 |
+
"While not usually something store administrators take great pleasure in "
|
4733 |
+
"handling, refunds are a very real part of running an eCommerce store. As "
|
4734 |
+
"much as we would love to, we can’t make the actual refund more enjoyable, "
|
4735 |
+
"but we can make refunds easier to process."
|
|
|
|
|
|
|
4736 |
msgstr ""
|
4737 |
|
4738 |
+
#: includes/admin/welcome.php:232
|
4739 |
msgid ""
|
4740 |
+
"In Easy Digital Downloads 2.6, we have added support for processing refunds "
|
4741 |
+
"directly from the View Order Details screen for purchases made through "
|
4742 |
+
"PayPal Standard."
|
4743 |
msgstr ""
|
4744 |
|
4745 |
+
#: includes/admin/welcome.php:238
|
4746 |
msgid "Additional Updates"
|
4747 |
msgstr ""
|
4748 |
|
4749 |
+
#: includes/admin/welcome.php:241
|
4750 |
+
msgid "REST API Version 2"
|
4751 |
msgstr ""
|
4752 |
|
4753 |
+
#: includes/admin/welcome.php:242
|
4754 |
msgid ""
|
4755 |
+
"Version 2 of the REST API offers several improved endpoint options and "
|
4756 |
+
"better data standardization."
|
4757 |
msgstr ""
|
4758 |
|
4759 |
+
#: includes/admin/welcome.php:245
|
4760 |
+
msgid "Prices on oEmbed"
|
4761 |
msgstr ""
|
4762 |
|
4763 |
+
#: includes/admin/welcome.php:246
|
4764 |
msgid ""
|
4765 |
+
"When embedding a download product on another site, using WordPress core’s "
|
4766 |
+
"oEmbed feature, the product prices are now shown."
|
4767 |
msgstr ""
|
4768 |
|
4769 |
+
#: includes/admin/welcome.php:249
|
4770 |
+
msgid "Customer Meta"
|
4771 |
msgstr ""
|
4772 |
|
4773 |
+
#: includes/admin/welcome.php:250
|
4774 |
msgid ""
|
4775 |
+
"The customer database now includes a complete metadata API for storing "
|
4776 |
+
"additional information on customer records."
|
4777 |
msgstr ""
|
4778 |
|
4779 |
+
#: includes/admin/welcome.php:254
|
4780 |
+
msgid "Improved Accessibility"
|
4781 |
msgstr ""
|
4782 |
|
4783 |
+
#: includes/admin/welcome.php:255
|
4784 |
msgid ""
|
4785 |
+
"Easy Digital Downloads is now more accessible to more users thanks to a "
|
4786 |
+
"member of the WordPress accessibility team who helped resolve accessibility "
|
4787 |
+
"issues throughout the administrative interfaces."
|
4788 |
msgstr ""
|
4789 |
|
4790 |
+
#: includes/admin/welcome.php:258
|
4791 |
+
msgid "Resolved Schema Problems"
|
4792 |
msgstr ""
|
4793 |
|
4794 |
+
#: includes/admin/welcome.php:259
|
4795 |
+
msgid "Invalid and missing schema microdata has been resolved."
|
|
|
|
|
4796 |
msgstr ""
|
4797 |
|
4798 |
+
#: includes/admin/welcome.php:262
|
4799 |
+
msgid "More Actions and Filters"
|
4800 |
msgstr ""
|
4801 |
|
4802 |
+
#: includes/admin/welcome.php:263
|
4803 |
msgid ""
|
4804 |
+
"Numerous new actions and filters have been added to help make Easy Digital "
|
4805 |
+
"Downloads more extensible for developers."
|
4806 |
msgstr ""
|
4807 |
|
4808 |
+
#: includes/admin/welcome.php:270 includes/admin/welcome.php:301
|
4809 |
msgid "Go to Easy Digital Downloads Settings"
|
4810 |
msgstr ""
|
4811 |
|
4812 |
+
#: includes/admin/welcome.php:271
|
4813 |
msgid "View the Full Changelog"
|
4814 |
msgstr ""
|
4815 |
|
4816 |
+
#: includes/admin/welcome.php:293
|
4817 |
msgid "Full Changelog"
|
4818 |
msgstr ""
|
4819 |
|
4820 |
+
#: includes/admin/welcome.php:322
|
4821 |
msgid ""
|
4822 |
"Use the tips below to get started using Easy Digital Downloads. You will be "
|
4823 |
"up and running in no time!"
|
4824 |
msgstr ""
|
4825 |
|
4826 |
+
#: includes/admin/welcome.php:325
|
4827 |
msgid "Creating Your First Download Product"
|
4828 |
msgstr ""
|
4829 |
|
4830 |
+
#: includes/admin/welcome.php:331
|
4831 |
msgid "%s → Add New"
|
4832 |
msgstr ""
|
4833 |
|
4834 |
+
#: includes/admin/welcome.php:332
|
4835 |
msgid ""
|
4836 |
"The %s menu is your access point for all aspects of your Easy Digital "
|
4837 |
"Downloads product creation and setup. To create your first product, simply "
|
4838 |
"click Add New and then fill out the product details."
|
4839 |
msgstr ""
|
4840 |
|
4841 |
+
#: includes/admin/welcome.php:336
|
|
|
|
|
|
|
|
|
4842 |
msgid ""
|
4843 |
"Uploading the downloadable files is simple. Click <em>Upload File</em> in "
|
4844 |
"the Download Files section and choose your download file. To add more than "
|
4845 |
"one file, simply click the <em>Add New</em> button."
|
4846 |
msgstr ""
|
4847 |
|
4848 |
+
#: includes/admin/welcome.php:342
|
4849 |
msgid "Display a Product Grid"
|
4850 |
msgstr ""
|
4851 |
|
4852 |
+
#: includes/admin/welcome.php:348
|
4853 |
msgid "Flexible Product Grids"
|
4854 |
msgstr ""
|
4855 |
|
4856 |
+
#: includes/admin/welcome.php:349
|
4857 |
msgid ""
|
4858 |
"The [downloads] shortcode will display a product grid that works with any "
|
4859 |
"theme, no matter the size. It is even responsive!"
|
4860 |
msgstr ""
|
4861 |
|
4862 |
+
#: includes/admin/welcome.php:351
|
4863 |
msgid "Change the Number of Columns"
|
4864 |
msgstr ""
|
4865 |
|
4866 |
+
#: includes/admin/welcome.php:352
|
4867 |
msgid ""
|
4868 |
"You can easily change the number of columns by adding the columns=\"x\" "
|
4869 |
"parameter:"
|
4870 |
msgstr ""
|
4871 |
|
4872 |
+
#: includes/admin/welcome.php:355
|
4873 |
msgid "Additional Display Options"
|
4874 |
msgstr ""
|
4875 |
|
4876 |
+
#: includes/admin/welcome.php:356
|
4877 |
msgid ""
|
4878 |
"The product grids can be customized in any way you wish and there is <a "
|
4879 |
"href=\"%s\">extensive documentation</a> to assist you."
|
4880 |
msgstr ""
|
4881 |
|
4882 |
+
#: includes/admin/welcome.php:362
|
4883 |
msgid "Purchase Buttons Anywhere"
|
4884 |
msgstr ""
|
4885 |
|
4886 |
+
#: includes/admin/welcome.php:368
|
4887 |
msgid "The <em>[purchase_link]</em> Shortcode"
|
4888 |
msgstr ""
|
4889 |
|
4890 |
+
#: includes/admin/welcome.php:369
|
4891 |
msgid ""
|
4892 |
"With easily accessible shortcodes to display purchase buttons, you can add "
|
4893 |
"a Buy Now or Add to Cart button for any product anywhere on your site in "
|
4894 |
"seconds."
|
4895 |
msgstr ""
|
4896 |
|
4897 |
+
#: includes/admin/welcome.php:371
|
4898 |
msgid "Buy Now Buttons"
|
4899 |
msgstr ""
|
4900 |
|
4901 |
+
#: includes/admin/welcome.php:372
|
4902 |
msgid ""
|
4903 |
"Purchase buttons can behave as either Add to Cart or Buy Now buttons. With "
|
4904 |
"Buy Now buttons customers are taken straight to PayPal, giving them the "
|
4905 |
"most frictionless purchasing experience possible."
|
4906 |
msgstr ""
|
4907 |
|
4908 |
+
#: includes/admin/welcome.php:378
|
4909 |
msgid "Need Help?"
|
4910 |
msgstr ""
|
4911 |
|
4912 |
+
#: includes/admin/welcome.php:381
|
4913 |
msgid "Phenomenal Support"
|
4914 |
msgstr ""
|
4915 |
|
4916 |
+
#: includes/admin/welcome.php:382
|
4917 |
msgid ""
|
4918 |
"We do our best to provide the best support we can. If you encounter a "
|
4919 |
"problem or have a question, simply open a ticket using our <a "
|
4920 |
+
"href=\"https://easydigitaldownloads.com/support/?utm_source=plugin-welcome-"
|
4921 |
+
"page&utm_medium=support-link&utm_term=support&utm_campaign="
|
4922 |
+
"EDDWelcomeSupport\">support form</a>."
|
4923 |
msgstr ""
|
4924 |
|
4925 |
+
#: includes/admin/welcome.php:385
|
4926 |
msgid "Need Even Faster Support?"
|
4927 |
msgstr ""
|
4928 |
|
4929 |
+
#: includes/admin/welcome.php:386
|
4930 |
msgid ""
|
4931 |
+
"Our <a "
|
4932 |
+
"href=\"https://easydigitaldownloads.com/support/pricing/?utm_source=plugin-"
|
4933 |
+
"welcome-page&utm_medium=support-link&utm_term=priority-support&utm_campaign="
|
4934 |
+
"EDDWelcomeSupport\">Priority Support</a> system is there for customers that "
|
4935 |
+
"need faster and/or more in-depth assistance."
|
4936 |
msgstr ""
|
4937 |
|
4938 |
+
#: includes/admin/welcome.php:392
|
4939 |
msgid "Stay Up to Date"
|
4940 |
msgstr ""
|
4941 |
|
4942 |
+
#: includes/admin/welcome.php:395
|
4943 |
msgid "Get Notified of Extension Releases"
|
4944 |
msgstr ""
|
4945 |
|
4946 |
+
#: includes/admin/welcome.php:396
|
4947 |
msgid ""
|
4948 |
"New extensions that make Easy Digital Downloads even more powerful are "
|
4949 |
"released nearly every single week. Subscribe to the newsletter to stay up "
|
4950 |
+
"to date with our latest releases. <a "
|
4951 |
+
"href=\"https://easydigitaldownloads.com/subscribe\" target=\"_blank\">Sign "
|
4952 |
+
"up now</a> to ensure you do not miss a release!"
|
4953 |
msgstr ""
|
4954 |
|
4955 |
+
#: includes/admin/welcome.php:399
|
4956 |
msgid "Get Alerted About New Tutorials"
|
4957 |
msgstr ""
|
4958 |
|
4959 |
+
#: includes/admin/welcome.php:400
|
4960 |
msgid ""
|
4961 |
+
"<a href=\"https://easydigitaldownloads.com/subscribe\" "
|
4962 |
+
"target=\"_blank\">Sign up now</a> to hear about the latest tutorial "
|
4963 |
+
"releases that explain how to take Easy Digital Downloads further."
|
4964 |
msgstr ""
|
4965 |
|
4966 |
+
#: includes/admin/welcome.php:406
|
4967 |
msgid "Extensions for Everything"
|
4968 |
msgstr ""
|
4969 |
|
4970 |
+
#: includes/admin/welcome.php:409
|
4971 |
msgid "Over 250 Extensions"
|
4972 |
msgstr ""
|
4973 |
|
4974 |
+
#: includes/admin/welcome.php:410
|
4975 |
msgid ""
|
4976 |
"Add-on plugins are available that greatly extend the default functionality "
|
4977 |
"of Easy Digital Downloads. There are extensions for payment processors, "
|
4979 |
"many, many more."
|
4980 |
msgstr ""
|
4981 |
|
4982 |
+
#: includes/admin/welcome.php:413
|
4983 |
msgid "Visit the Extension Store"
|
4984 |
msgstr ""
|
4985 |
|
4986 |
+
#: includes/admin/welcome.php:414
|
4987 |
msgid ""
|
4988 |
+
"<a "
|
4989 |
+
"href=\"https://easydigitaldownloads.com/downloads/?utm_source=plugin-"
|
4990 |
+
"welcome-page&utm_medium=extensions-link&utm_term=extensions&utm_campaign="
|
4991 |
+
"EDDWelcomeExtensions\" target=\"_blank\">The Extensions store</a> has a "
|
4992 |
+
"list of all available extensions, including convenient category filters so "
|
4993 |
+
"you can find exactly what you are looking for."
|
4994 |
msgstr ""
|
4995 |
|
4996 |
+
#: includes/admin/welcome.php:437
|
4997 |
msgid ""
|
4998 |
"Easy Digital Downloads is created by a worldwide team of developers who aim "
|
4999 |
"to provide the #1 eCommerce platform for selling digital goods through "
|
5000 |
"WordPress."
|
5001 |
msgstr ""
|
5002 |
|
5003 |
+
#: includes/admin/welcome.php:455
|
5004 |
msgid "No valid changelog was found."
|
5005 |
msgstr ""
|
5006 |
|
5016 |
msgid "No users found"
|
5017 |
msgstr ""
|
5018 |
|
5019 |
+
#: includes/api/class-edd-api-v2.php:143 includes/api/class-edd-api.php:1037
|
5020 |
+
#: includes/api/class-edd-api.php:1231 includes/api/class-edd-api.php:1341
|
5021 |
+
msgid "Product %s not found!"
|
5022 |
msgstr ""
|
5023 |
|
5024 |
+
#: includes/api/class-edd-api-v2.php:218 includes/api/class-edd-api.php:1142
|
5025 |
+
#: includes/api/class-edd-api.php:1248
|
5026 |
+
msgid "The end date must be later than the start date!"
|
5027 |
msgstr ""
|
5028 |
|
5029 |
+
#: includes/api/class-edd-api-v2.php:319 includes/api/class-edd-api.php:984
|
5030 |
+
msgid "Customer %s not found!"
|
5031 |
msgstr ""
|
5032 |
|
5033 |
+
#: includes/api/class-edd-api-v2.php:324 includes/api/class-edd-api.php:989
|
5034 |
+
msgid "No customers found!"
|
5035 |
msgstr ""
|
5036 |
|
5037 |
+
#: includes/api/class-edd-api.php:462
|
5038 |
+
msgid "You must specify both a token and API key!"
|
5039 |
msgstr ""
|
5040 |
|
5041 |
+
#: includes/api/class-edd-api.php:479
|
5042 |
+
msgid "Your request could not be authenticated!"
|
5043 |
msgstr ""
|
5044 |
|
5045 |
+
#: includes/api/class-edd-api.php:497
|
5046 |
+
msgid "Invalid API key!"
|
5047 |
msgstr ""
|
5048 |
|
5049 |
+
#: includes/api/class-edd-api.php:513
|
5050 |
+
msgid "Invalid API version!"
|
|
|
5051 |
msgstr ""
|
5052 |
|
5053 |
+
#: includes/api/class-edd-api.php:680
|
5054 |
+
msgid "Invalid query!"
|
5055 |
msgstr ""
|
5056 |
|
5057 |
+
#: includes/api/class-edd-api.php:1147 includes/api/class-edd-api.php:1253
|
5058 |
msgid "Invalid or no date range specified!"
|
5059 |
msgstr ""
|
5060 |
|
5061 |
+
#: includes/api/class-edd-api.php:1485
|
5062 |
msgid "No discounts found!"
|
5063 |
msgstr ""
|
5064 |
|
5065 |
+
#: includes/api/class-edd-api.php:1532
|
5066 |
msgid "Discount %s not found!"
|
5067 |
msgstr ""
|
5068 |
|
5069 |
+
#: includes/api/class-edd-api.php:1605
|
5070 |
msgid "No download logs found!"
|
5071 |
msgstr ""
|
5072 |
|
5073 |
+
#: includes/api/class-edd-api.php:1800 includes/user-functions.php:961
|
5074 |
msgid "Easy Digital Downloads API Keys"
|
5075 |
msgstr ""
|
5076 |
|
5077 |
+
#: includes/api/class-edd-api.php:1809 includes/user-functions.php:970
|
5078 |
msgid "Generate API Key"
|
5079 |
msgstr ""
|
5080 |
|
5081 |
+
#: includes/api/class-edd-api.php:1811 includes/user-functions.php:972
|
5082 |
msgid "Public key:"
|
5083 |
msgstr ""
|
5084 |
|
5085 |
+
#: includes/api/class-edd-api.php:1812 includes/user-functions.php:973
|
5086 |
msgid "Secret key:"
|
5087 |
msgstr ""
|
5088 |
|
5089 |
+
#: includes/api/class-edd-api.php:1813 includes/user-functions.php:974
|
5090 |
msgid "Token:"
|
5091 |
msgstr ""
|
5092 |
|
5093 |
+
#: includes/api/class-edd-api.php:1815 includes/user-functions.php:976
|
5094 |
msgid "Revoke API Keys"
|
5095 |
msgstr ""
|
5096 |
|
5097 |
+
#: includes/api/class-edd-api.php:1841
|
5098 |
msgid "User ID Required"
|
5099 |
msgstr ""
|
5100 |
|
5101 |
+
#: includes/api/class-edd-api.php:1853 includes/api/class-edd-api.php:1855
|
5102 |
msgid "You do not have permission to %s API keys for this user"
|
5103 |
msgstr ""
|
5104 |
|
5105 |
+
#: includes/cart/functions.php:431
|
5106 |
msgid "includes %s tax"
|
5107 |
msgstr ""
|
5108 |
|
5109 |
+
#: includes/cart/functions.php:433
|
5110 |
msgid "excludes %s tax"
|
5111 |
msgstr ""
|
5112 |
|
5113 |
+
#: includes/cart/functions.php:1140 includes/cart/functions.php:1208
|
5114 |
+
#: templates/shortcode-profile-editor.php:22
|
5115 |
msgid "Success"
|
5116 |
msgstr ""
|
5117 |
|
5118 |
+
#: includes/cart/functions.php:1141
|
5119 |
msgid "Cart saved successfully. You can restore your cart using this URL:"
|
5120 |
msgstr ""
|
5121 |
|
5122 |
+
#: includes/cart/functions.php:1178 includes/cart/functions.php:1195
|
5123 |
msgid "Cart restoration failed. Invalid token."
|
5124 |
msgstr ""
|
5125 |
|
5126 |
+
#: includes/cart/functions.php:1186 includes/cart/functions.php:1198
|
5127 |
msgid "The cart cannot be restored. Invalid token."
|
5128 |
msgstr ""
|
5129 |
|
5130 |
+
#: includes/cart/functions.php:1208
|
5131 |
msgid "Cart restored successfully."
|
5132 |
msgstr ""
|
5133 |
|
5163 |
msgid "Personal Info"
|
5164 |
msgstr ""
|
5165 |
|
|
|
|
|
|
|
|
|
|
|
5166 |
#: includes/checkout/template.php:185
|
5167 |
msgid "We will send the purchase receipt to this address."
|
5168 |
msgstr ""
|
5373 |
msgid "Enter a coupon code if you have one."
|
5374 |
msgstr ""
|
5375 |
|
5376 |
+
#: includes/checkout/template.php:723 includes/process-purchase.php:306
|
5377 |
#: includes/scripts.php:55
|
5378 |
msgid "Enter discount"
|
5379 |
msgstr ""
|
5434 |
msgstr ""
|
5435 |
|
5436 |
#: includes/class-edd-cli.php:63
|
5437 |
+
msgid "AJAX is: %s"
|
5438 |
msgstr ""
|
5439 |
|
5440 |
#: includes/class-edd-cli.php:64
|
5566 |
msgid "Customer User ID: %s"
|
5567 |
msgstr ""
|
5568 |
|
5569 |
+
#: includes/class-edd-cli.php:318 includes/user-functions.php:509
|
5570 |
+
#: includes/user-functions.php:518
|
5571 |
msgid "Username: %s"
|
5572 |
msgstr ""
|
5573 |
|
5644 |
msgstr ""
|
5645 |
|
5646 |
#: includes/class-edd-cli.php:419 includes/class-edd-html-elements.php:208
|
5647 |
+
#: includes/shortcodes.php:251
|
5648 |
msgid "No discounts found"
|
5649 |
msgstr ""
|
5650 |
|
5728 |
msgid "Once Weekly"
|
5729 |
msgstr ""
|
5730 |
|
5731 |
+
#: includes/class-edd-customer.php:185 includes/class-edd-download.php:196
|
5732 |
msgid "Can't get property %s"
|
5733 |
msgstr ""
|
5734 |
|
5736 |
msgid "New Download Product"
|
5737 |
msgstr ""
|
5738 |
|
5739 |
+
#: includes/class-edd-html-elements.php:43 includes/scripts.php:207
|
5740 |
msgid "Choose a %s"
|
5741 |
msgstr ""
|
5742 |
|
5757 |
msgstr ""
|
5758 |
|
5759 |
#: includes/class-edd-license-handler.php:163
|
5760 |
+
msgid "%1$s"
|
5761 |
msgstr ""
|
5762 |
|
5763 |
#: includes/class-edd-license-handler.php:196
|
5764 |
msgid ""
|
5765 |
"Enter your extension license keys here to receive updates for purchased "
|
5766 |
"extensions. If your license key has expired, please <a href=\"%s\" "
|
5767 |
+
"target=\"_blank\">renew your license</a>."
|
5768 |
msgstr ""
|
5769 |
|
5770 |
#: includes/class-edd-license-handler.php:421
|
5771 |
msgid ""
|
5772 |
"You have invalid or expired license keys for Easy Digital Downloads. Please "
|
5773 |
+
"go to the <a href=\"%s\">Licenses page</a> to correct this issue."
|
|
|
5774 |
msgstr ""
|
5775 |
|
5776 |
#: includes/class-edd-license-handler.php:460
|
6123 |
msgid "This discount is not active."
|
6124 |
msgstr ""
|
6125 |
|
6126 |
+
#: includes/discount-functions.php:629
|
6127 |
msgid "This discount is not active yet."
|
6128 |
msgstr ""
|
6129 |
|
6130 |
+
#: includes/discount-functions.php:660
|
6131 |
msgid "This discount has reached its maximum usage."
|
6132 |
msgstr ""
|
6133 |
|
6134 |
+
#: includes/discount-functions.php:689
|
6135 |
msgid "Minimum order of %s not met."
|
6136 |
msgstr ""
|
6137 |
|
6138 |
+
#: includes/discount-functions.php:751 includes/discount-functions.php:771
|
6139 |
msgid "The product requirements for this discount are not met."
|
6140 |
msgstr ""
|
6141 |
|
6142 |
+
#: includes/discount-functions.php:787
|
6143 |
msgid "This discount is not valid for the cart contents."
|
6144 |
msgstr ""
|
6145 |
|
6146 |
+
#: includes/discount-functions.php:891
|
6147 |
msgid "This discount has already been redeemed."
|
6148 |
msgstr ""
|
6149 |
|
6150 |
+
#: includes/discount-functions.php:937
|
6151 |
msgid "This discount is invalid."
|
6152 |
msgstr ""
|
6153 |
|
6240 |
msgid "These are some sample notes added to a product."
|
6241 |
msgstr ""
|
6242 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
6243 |
#: includes/emails/template.php:113
|
6244 |
msgid "Preview Purchase Receipt"
|
6245 |
msgstr ""
|
6265 |
msgid "Amazon"
|
6266 |
msgstr ""
|
6267 |
|
6268 |
+
#: includes/gateways/amazon-payments.php:264
|
6269 |
+
msgid "Amazon Payments"
|
6270 |
+
msgstr ""
|
6271 |
+
|
6272 |
#: includes/gateways/amazon-payments.php:282
|
6273 |
msgid "Amazon Payments Settings"
|
6274 |
msgstr ""
|
6363 |
|
6364 |
#: includes/gateways/amazon-payments.php:1017
|
6365 |
#: includes/gateways/amazon-payments.php:1071
|
6366 |
+
#: includes/gateways/paypal-standard.php:407
|
6367 |
+
#: includes/gateways/paypal-standard.php:412
|
6368 |
+
#: includes/gateways/paypal-standard.php:475
|
6369 |
+
#: includes/gateways/paypal-standard.php:484
|
6370 |
+
#: includes/gateways/paypal-standard.php:543
|
6371 |
+
#: includes/gateways/paypal-standard.php:550
|
6372 |
msgid "IPN Error"
|
6373 |
msgstr ""
|
6374 |
|
6409 |
msgid "The requested price ID does not exist."
|
6410 |
msgstr ""
|
6411 |
|
6412 |
+
#: includes/gateways/manual.php:33 includes/gateways/paypal-standard.php:155
|
6413 |
msgid "Nonce verification has failed"
|
6414 |
msgstr ""
|
6415 |
|
6419 |
"Payment data: %s"
|
6420 |
msgstr ""
|
6421 |
|
6422 |
+
#: includes/gateways/paypal-standard.php:51
|
6423 |
+
msgid "PayPal Standard Settings"
|
6424 |
+
msgstr ""
|
6425 |
+
|
6426 |
+
#: includes/gateways/paypal-standard.php:56
|
6427 |
+
msgid "PayPal Email"
|
6428 |
+
msgstr ""
|
6429 |
+
|
6430 |
#: includes/gateways/paypal-standard.php:57
|
6431 |
+
msgid "Enter your PayPal account's email"
|
6432 |
+
msgstr ""
|
6433 |
+
|
6434 |
+
#: includes/gateways/paypal-standard.php:63
|
6435 |
+
msgid "PayPal Page Style"
|
6436 |
+
msgstr ""
|
6437 |
+
|
6438 |
+
#: includes/gateways/paypal-standard.php:64
|
6439 |
+
msgid "Enter the name of the page style to use, or leave blank for default"
|
6440 |
+
msgstr ""
|
6441 |
+
|
6442 |
+
#: includes/gateways/paypal-standard.php:71
|
6443 |
+
msgid ""
|
6444 |
+
"If payments are not getting marked as complete, then check this box. This "
|
6445 |
+
"forces the site to use a slightly less secure method of verifying "
|
6446 |
+
"purchases. See our <a href=\"%s\" target=\"_blank\">FAQ</a> for further "
|
6447 |
+
"information."
|
6448 |
+
msgstr ""
|
6449 |
+
|
6450 |
+
#: includes/gateways/paypal-standard.php:77
|
6451 |
+
msgid "Disable PayPal IPN Verification"
|
6452 |
+
msgstr ""
|
6453 |
+
|
6454 |
+
#: includes/gateways/paypal-standard.php:85
|
6455 |
+
msgid "API Credentials"
|
6456 |
+
msgstr ""
|
6457 |
+
|
6458 |
+
#: includes/gateways/paypal-standard.php:88
|
6459 |
+
msgid ""
|
6460 |
+
"API credentials are necessary to process PayPal refunds from inside "
|
6461 |
+
"WordPress. These can be obtained from <a href=\"%s\" target=\"_blank\">your "
|
6462 |
+
"PayPal account</a>."
|
6463 |
+
msgstr ""
|
6464 |
+
|
6465 |
+
#: includes/gateways/paypal-standard.php:94
|
6466 |
+
msgid "Live API Username"
|
6467 |
+
msgstr ""
|
6468 |
+
|
6469 |
+
#: includes/gateways/paypal-standard.php:95
|
6470 |
+
msgid "Your PayPal live API username. "
|
6471 |
+
msgstr ""
|
6472 |
+
|
6473 |
+
#: includes/gateways/paypal-standard.php:101
|
6474 |
+
msgid "Live API Password"
|
6475 |
+
msgstr ""
|
6476 |
+
|
6477 |
+
#: includes/gateways/paypal-standard.php:102
|
6478 |
+
msgid "Your PayPal live API password."
|
6479 |
+
msgstr ""
|
6480 |
+
|
6481 |
+
#: includes/gateways/paypal-standard.php:108
|
6482 |
+
msgid "Live API Signature"
|
6483 |
+
msgstr ""
|
6484 |
+
|
6485 |
+
#: includes/gateways/paypal-standard.php:109
|
6486 |
+
msgid "Your PayPal live API signature."
|
6487 |
+
msgstr ""
|
6488 |
+
|
6489 |
+
#: includes/gateways/paypal-standard.php:115
|
6490 |
+
msgid "Test API Username"
|
6491 |
+
msgstr ""
|
6492 |
+
|
6493 |
+
#: includes/gateways/paypal-standard.php:116
|
6494 |
+
msgid "Your PayPal test API username."
|
6495 |
+
msgstr ""
|
6496 |
+
|
6497 |
+
#: includes/gateways/paypal-standard.php:122
|
6498 |
+
msgid "Test API Password"
|
6499 |
+
msgstr ""
|
6500 |
+
|
6501 |
+
#: includes/gateways/paypal-standard.php:123
|
6502 |
+
msgid "Your PayPal test API password."
|
6503 |
+
msgstr ""
|
6504 |
+
|
6505 |
+
#: includes/gateways/paypal-standard.php:129
|
6506 |
+
msgid "Test API Signature"
|
6507 |
+
msgstr ""
|
6508 |
+
|
6509 |
+
#: includes/gateways/paypal-standard.php:130
|
6510 |
+
msgid "Your PayPal test API signature."
|
6511 |
+
msgstr ""
|
6512 |
+
|
6513 |
+
#: includes/gateways/paypal-standard.php:178
|
6514 |
msgid "Payment creation failed before sending buyer to PayPal. Payment data: %s"
|
6515 |
msgstr ""
|
6516 |
|
6517 |
+
#: includes/gateways/paypal-standard.php:407
|
6518 |
+
#: includes/gateways/paypal-standard.php:412
|
6519 |
msgid "Invalid IPN verification response. IPN data: %s"
|
6520 |
msgstr ""
|
6521 |
|
6522 |
+
#: includes/gateways/paypal-standard.php:475
|
6523 |
msgid "Invalid business email in IPN response. IPN data: %s"
|
6524 |
msgstr ""
|
6525 |
|
6526 |
+
#: includes/gateways/paypal-standard.php:477
|
6527 |
msgid "Payment failed due to invalid PayPal business email."
|
6528 |
msgstr ""
|
6529 |
|
6530 |
+
#: includes/gateways/paypal-standard.php:484
|
6531 |
msgid "Invalid currency in IPN response. IPN data: %s"
|
6532 |
msgstr ""
|
6533 |
|
6534 |
+
#: includes/gateways/paypal-standard.php:486
|
6535 |
msgid "Payment failed due to invalid currency in PayPal IPN."
|
6536 |
msgstr ""
|
6537 |
|
6538 |
+
#: includes/gateways/paypal-standard.php:543
|
6539 |
msgid "Invalid payment amount in IPN response. IPN data: %s"
|
6540 |
msgstr ""
|
6541 |
|
6542 |
+
#: includes/gateways/paypal-standard.php:545
|
6543 |
msgid "Payment failed due to invalid amount in PayPal IPN."
|
6544 |
msgstr ""
|
6545 |
|
6546 |
+
#: includes/gateways/paypal-standard.php:550
|
6547 |
msgid "Invalid purchase key in IPN response. IPN data: %s"
|
6548 |
msgstr ""
|
6549 |
|
6550 |
+
#: includes/gateways/paypal-standard.php:552
|
6551 |
msgid "Payment failed due to invalid purchase key in PayPal IPN."
|
6552 |
msgstr ""
|
6553 |
|
6554 |
+
#: includes/gateways/paypal-standard.php:558
|
6555 |
#: tests/helpers/class-helper-payment.php:131
|
6556 |
#: tests/helpers/class-helper-payment.php:234
|
6557 |
#: tests/helpers/class-helper-payment.php:342
|
6561 |
msgid "PayPal Transaction ID: %s"
|
6562 |
msgstr ""
|
6563 |
|
6564 |
+
#: includes/gateways/paypal-standard.php:572
|
6565 |
msgid "Payment made via eCheck and will clear automatically in 5-8 days"
|
6566 |
msgstr ""
|
6567 |
|
6568 |
+
#: includes/gateways/paypal-standard.php:578
|
6569 |
msgid ""
|
6570 |
"Payment requires a confirmed customer address and must be accepted manually "
|
6571 |
"through PayPal"
|
6572 |
msgstr ""
|
6573 |
|
6574 |
+
#: includes/gateways/paypal-standard.php:584
|
6575 |
msgid ""
|
6576 |
"Payment must be accepted manually through PayPal due to international "
|
6577 |
"account regulations"
|
6578 |
msgstr ""
|
6579 |
|
6580 |
+
#: includes/gateways/paypal-standard.php:590
|
6581 |
msgid ""
|
6582 |
"Payment received in non-shop currency and must be accepted manually through "
|
6583 |
"PayPal"
|
6584 |
msgstr ""
|
6585 |
|
6586 |
+
#: includes/gateways/paypal-standard.php:597
|
6587 |
msgid ""
|
6588 |
"Payment is being reviewed by PayPal staff as high-risk or in possible "
|
6589 |
"violation of government regulations"
|
6590 |
msgstr ""
|
6591 |
|
6592 |
+
#: includes/gateways/paypal-standard.php:603
|
6593 |
msgid "Payment was sent to non-confirmed or non-registered email address."
|
6594 |
msgstr ""
|
6595 |
|
6596 |
+
#: includes/gateways/paypal-standard.php:609
|
6597 |
msgid "PayPal account must be upgraded before this payment can be accepted"
|
6598 |
msgstr ""
|
6599 |
|
6600 |
+
#: includes/gateways/paypal-standard.php:615
|
6601 |
msgid ""
|
6602 |
"PayPal account is not verified. Verify account in order to accept this "
|
6603 |
"payment"
|
6604 |
msgstr ""
|
6605 |
|
6606 |
+
#: includes/gateways/paypal-standard.php:621
|
6607 |
msgid ""
|
6608 |
"Payment is pending for unknown reasons. Contact PayPal support for "
|
6609 |
"assistance"
|
6610 |
msgstr ""
|
6611 |
|
6612 |
+
#: includes/gateways/paypal-standard.php:662
|
6613 |
msgid "Partial PayPal refund processed: %s"
|
6614 |
msgstr ""
|
6615 |
|
6616 |
+
#: includes/gateways/paypal-standard.php:667
|
6617 |
msgid "PayPal Payment #%s Refunded for reason: %s"
|
6618 |
msgstr ""
|
6619 |
|
6620 |
+
#: includes/gateways/paypal-standard.php:668
|
6621 |
msgid "PayPal Refund Transaction ID: %s"
|
6622 |
msgstr ""
|
6623 |
|
6624 |
+
#: includes/gateways/paypal-standard.php:815
|
6625 |
+
msgid "Refund Payment in PayPal"
|
6626 |
+
msgstr ""
|
6627 |
+
|
6628 |
+
#: includes/gateways/paypal-standard.php:964
|
6629 |
+
msgid "PayPal refund failed for unknown reason."
|
6630 |
+
msgstr ""
|
6631 |
+
|
6632 |
+
#: includes/gateways/paypal-standard.php:974
|
6633 |
+
msgid "PayPal refund transaction ID: %s"
|
6634 |
+
msgstr ""
|
6635 |
+
|
6636 |
+
#: includes/gateways/paypal-standard.php:978
|
6637 |
+
msgid "PayPal refund failed: %s"
|
6638 |
+
msgstr ""
|
6639 |
+
|
6640 |
+
#: includes/install.php:91 includes/template-functions.php:182
|
6641 |
#: templates/widget-cart-checkout.php:6 templates/widget-cart-empty.php:7
|
6642 |
msgid "Checkout"
|
6643 |
msgstr ""
|
6644 |
|
6645 |
+
#: includes/install.php:103
|
6646 |
msgid "Purchase Confirmation"
|
6647 |
msgstr ""
|
6648 |
|
6649 |
+
#: includes/install.php:104
|
6650 |
msgid "Thank you for your purchase! [edd_receipt]"
|
6651 |
msgstr ""
|
6652 |
|
6653 |
+
#: includes/install.php:129
|
6654 |
msgid "Purchase History"
|
6655 |
msgstr ""
|
6656 |
|
6658 |
msgid "The password you entered is incorrect"
|
6659 |
msgstr ""
|
6660 |
|
6661 |
+
#: includes/login-register.php:87 includes/process-purchase.php:612
|
6662 |
msgid "The username you entered does not exist"
|
6663 |
msgstr ""
|
6664 |
|
6665 |
#: includes/login-register.php:140 includes/login-register.php:148
|
6666 |
+
#: includes/process-purchase.php:497
|
6667 |
msgid "Invalid username"
|
6668 |
msgstr ""
|
6669 |
|
6670 |
+
#: includes/login-register.php:144 includes/process-purchase.php:490
|
6671 |
msgid "Username already taken"
|
6672 |
msgstr ""
|
6673 |
|
6675 |
msgid "Email address already taken"
|
6676 |
msgstr ""
|
6677 |
|
6678 |
+
#: includes/login-register.php:156 includes/process-purchase.php:437
|
6679 |
+
#: includes/process-purchase.php:512 includes/process-purchase.php:645
|
6680 |
msgid "Invalid email"
|
6681 |
msgstr ""
|
6682 |
|
6828 |
msgid "Status changed from %s to %s"
|
6829 |
msgstr ""
|
6830 |
|
6831 |
+
#: includes/payments/functions.php:640
|
6832 |
msgid "Complete"
|
6833 |
msgstr ""
|
6834 |
|
6835 |
+
#: includes/payments/functions.php:1581
|
6836 |
msgid "EDD Bot"
|
6837 |
msgstr ""
|
6838 |
|
|
|
|
|
|
|
|
|
6839 |
#: includes/plugin-compatibility.php:73 tests/tests-plugin-compatibility.php:85
|
6840 |
msgid "No Caching on Checkout?"
|
6841 |
msgstr ""
|
7136 |
msgid "Your cart is empty"
|
7137 |
msgstr ""
|
7138 |
|
7139 |
+
#: includes/process-purchase.php:273
|
7140 |
msgid "The selected payment gateway is not enabled"
|
7141 |
msgstr ""
|
7142 |
|
7143 |
+
#: includes/process-purchase.php:333
|
7144 |
msgid "One or more of the discounts you entered is invalid"
|
7145 |
msgstr ""
|
7146 |
|
7147 |
+
#: includes/process-purchase.php:350
|
7148 |
msgid "You must agree to the terms of use"
|
7149 |
msgstr ""
|
7150 |
|
7151 |
+
#: includes/process-purchase.php:365
|
7152 |
msgid "Please enter a valid email address"
|
7153 |
msgstr ""
|
7154 |
|
7155 |
+
#: includes/process-purchase.php:369
|
7156 |
msgid "Please enter your first name"
|
7157 |
msgstr ""
|
7158 |
|
7159 |
+
#: includes/process-purchase.php:379
|
7160 |
msgid "Please enter your zip / postal code"
|
7161 |
msgstr ""
|
7162 |
|
7163 |
+
#: includes/process-purchase.php:383
|
7164 |
msgid "Please enter your billing city"
|
7165 |
msgstr ""
|
7166 |
|
7167 |
+
#: includes/process-purchase.php:387
|
7168 |
msgid "Please select your billing country"
|
7169 |
msgstr ""
|
7170 |
|
7171 |
+
#: includes/process-purchase.php:391
|
7172 |
msgid "Please enter billing state / province"
|
7173 |
msgstr ""
|
7174 |
|
7175 |
+
#: includes/process-purchase.php:442
|
7176 |
msgid "The user information is invalid"
|
7177 |
msgstr ""
|
7178 |
|
7179 |
+
#: includes/process-purchase.php:495
|
7180 |
msgid "Invalid username. Only lowercase letters (a-z) and numbers are allowed"
|
7181 |
msgstr ""
|
7182 |
|
7183 |
+
#: includes/process-purchase.php:504
|
7184 |
msgid "You must register or login to complete your purchase"
|
7185 |
msgstr ""
|
7186 |
|
7187 |
+
#: includes/process-purchase.php:517
|
7188 |
msgid "Email already used"
|
7189 |
msgstr ""
|
7190 |
|
7191 |
+
#: includes/process-purchase.php:525 includes/process-purchase.php:652
|
7192 |
msgid "Enter an email"
|
7193 |
msgstr ""
|
7194 |
|
7195 |
+
#: includes/process-purchase.php:533
|
7196 |
msgid "Passwords don't match"
|
7197 |
msgstr ""
|
7198 |
|
7199 |
+
#: includes/process-purchase.php:542 includes/process-purchase.php:608
|
7200 |
msgid "Enter a password"
|
7201 |
msgstr ""
|
7202 |
|
7203 |
+
#: includes/process-purchase.php:545
|
7204 |
msgid "Enter the password confirmation"
|
7205 |
msgstr ""
|
7206 |
|
7207 |
+
#: includes/process-purchase.php:569
|
7208 |
msgid "You must login or register to complete your purchase"
|
7209 |
msgstr ""
|
7210 |
|
7211 |
+
#: includes/process-purchase.php:589
|
7212 |
msgid "The password you entered is incorrect. %sReset Password%s"
|
7213 |
msgstr ""
|
7214 |
|
7215 |
+
#: includes/process-purchase.php:634
|
|
|
|
|
|
|
|
|
7216 |
msgid "You must be logged into an account to purchase"
|
7217 |
msgstr ""
|
7218 |
|
7219 |
+
#: includes/process-purchase.php:814
|
7220 |
msgid "The zip / postal code you entered for your billing address is invalid"
|
7221 |
msgstr ""
|
7222 |
|
7223 |
+
#: includes/process-purchase.php:1076
|
7224 |
msgid "An internal error has occurred, please try again or contact support."
|
7225 |
msgstr ""
|
7226 |
|
7260 |
msgid "Loading"
|
7261 |
msgstr ""
|
7262 |
|
7263 |
+
#: includes/scripts.php:193
|
7264 |
msgid "Add New Download"
|
7265 |
msgstr ""
|
7266 |
|
7267 |
+
#: includes/scripts.php:194
|
7268 |
msgid "Use This File"
|
7269 |
msgstr ""
|
7270 |
|
7271 |
+
#: includes/scripts.php:195
|
7272 |
msgid "Sorry, not available for variable priced products."
|
7273 |
msgstr ""
|
7274 |
|
7275 |
+
#: includes/scripts.php:196
|
7276 |
msgid "Are you sure you wish to delete this payment?"
|
7277 |
msgstr ""
|
7278 |
|
7279 |
+
#: includes/scripts.php:197
|
7280 |
msgid "Are you sure you wish to delete this note?"
|
7281 |
msgstr ""
|
7282 |
|
7283 |
+
#: includes/scripts.php:198
|
7284 |
msgid "Are you sure you wish to delete this tax rate?"
|
7285 |
msgstr ""
|
7286 |
|
7287 |
+
#: includes/scripts.php:199
|
7288 |
msgid "Are you sure you wish to revoke this API key?"
|
7289 |
msgstr ""
|
7290 |
|
7291 |
+
#: includes/scripts.php:200
|
7292 |
msgid "Are you sure you wish to regenerate this API key?"
|
7293 |
msgstr ""
|
7294 |
|
7295 |
+
#: includes/scripts.php:201
|
7296 |
msgid "Are you sure you wish to resend the purchase receipt?"
|
7297 |
msgstr ""
|
7298 |
|
7299 |
+
#: includes/scripts.php:202
|
7300 |
msgid "Copy these links to your clipboard and give them to your customer"
|
7301 |
msgstr ""
|
7302 |
|
7303 |
+
#: includes/scripts.php:203
|
7304 |
msgid "Are you sure you wish to delete this %s?"
|
7305 |
msgstr ""
|
7306 |
|
7307 |
+
#: includes/scripts.php:204
|
7308 |
msgid "You must have at least one price"
|
7309 |
msgstr ""
|
7310 |
|
7311 |
+
#: includes/scripts.php:205
|
7312 |
msgid "You must have at least one field"
|
7313 |
msgstr ""
|
7314 |
|
7315 |
+
#: includes/scripts.php:206
|
7316 |
msgid "Payments must contain at least one item"
|
7317 |
msgstr ""
|
7318 |
|
7319 |
+
#: includes/scripts.php:208
|
7320 |
msgid "Choose one or more %s"
|
7321 |
msgstr ""
|
7322 |
|
7323 |
+
#: includes/scripts.php:209
|
7324 |
msgid "Item price must be numeric"
|
7325 |
msgstr ""
|
7326 |
|
7327 |
+
#: includes/scripts.php:210
|
7328 |
msgid "Quantity must be numeric"
|
7329 |
msgstr ""
|
7330 |
|
7331 |
+
#: includes/scripts.php:217
|
7332 |
msgid "Type to search %s"
|
7333 |
msgstr ""
|
7334 |
|
7335 |
+
#: includes/scripts.php:219
|
7336 |
msgid "You must choose a method."
|
7337 |
msgstr ""
|
7338 |
|
7339 |
+
#: includes/scripts.php:220
|
7340 |
msgid "Required fields not completed."
|
7341 |
msgstr ""
|
7342 |
|
7343 |
+
#: includes/scripts.php:221
|
7344 |
msgid ""
|
7345 |
"Are you sure you want to reset your store? This process is <strong><em>not "
|
7346 |
"reversible</em></strong>. Please be sure you have a recent backup."
|
7347 |
msgstr ""
|
7348 |
|
7349 |
+
#: includes/scripts.php:222
|
7350 |
msgid "Type to search all %s"
|
7351 |
msgstr ""
|
7352 |
|
7353 |
+
#: includes/scripts.php:223
|
7354 |
+
msgid ""
|
7355 |
+
"We are sorry but your browser is not compatible with this kind of file "
|
7356 |
+
"upload. Please upgrade your browser."
|
7357 |
+
msgstr ""
|
7358 |
+
|
7359 |
+
#: includes/shortcodes.php:275
|
7360 |
msgid "Purchase All Items"
|
7361 |
msgstr ""
|
7362 |
|
7363 |
+
#: includes/shortcodes.php:665
|
7364 |
msgid "Sorry, trouble retrieving payment receipt."
|
7365 |
msgstr ""
|
7366 |
|
7367 |
+
#: includes/shortcodes.php:700
|
7368 |
msgid "You must be logged in to view this payment receipt."
|
7369 |
msgstr ""
|
7370 |
|
7371 |
+
#: includes/shortcodes.php:835
|
7372 |
msgid "The passwords you entered do not match. Please try again."
|
7373 |
msgstr ""
|
7374 |
|
7375 |
+
#: includes/shortcodes.php:845
|
7376 |
msgid "The email you entered is invalid. Please enter a valid email."
|
7377 |
msgstr ""
|
7378 |
|
7379 |
+
#: includes/shortcodes.php:850
|
7380 |
msgid "The email you entered belongs to another user. Please use another."
|
7381 |
msgstr ""
|
7382 |
|
7383 |
+
#: includes/shortcodes.php:925
|
7384 |
+
msgid "Error removing email address from profile. Please try again later."
|
7385 |
+
msgstr ""
|
7386 |
+
|
7387 |
#: includes/template-functions.php:134
|
7388 |
msgid "Free"
|
7389 |
msgstr ""
|
7400 |
msgid "Excluding %1$s% tax"
|
7401 |
msgstr ""
|
7402 |
|
7403 |
+
#: includes/template-functions.php:440
|
7404 |
msgid "White"
|
7405 |
msgstr ""
|
7406 |
|
7407 |
+
#: includes/template-functions.php:444
|
7408 |
msgid "Gray"
|
7409 |
msgstr ""
|
7410 |
|
7411 |
+
#: includes/template-functions.php:448
|
7412 |
msgid "Blue"
|
7413 |
msgstr ""
|
7414 |
|
7415 |
+
#: includes/template-functions.php:452
|
7416 |
msgid "Red"
|
7417 |
msgstr ""
|
7418 |
|
7419 |
+
#: includes/template-functions.php:456
|
7420 |
msgid "Green"
|
7421 |
msgstr ""
|
7422 |
|
7423 |
+
#: includes/template-functions.php:460
|
7424 |
msgid "Yellow"
|
7425 |
msgstr ""
|
7426 |
|
7427 |
+
#: includes/template-functions.php:464
|
7428 |
msgid "Orange"
|
7429 |
msgstr ""
|
7430 |
|
7431 |
+
#: includes/template-functions.php:468
|
7432 |
msgid "Dark Gray"
|
7433 |
msgstr ""
|
7434 |
|
7435 |
+
#: includes/template-functions.php:472
|
7436 |
msgid "Inherit"
|
7437 |
msgstr ""
|
7438 |
|
7439 |
+
#: includes/template-functions.php:490
|
7440 |
msgid "Button"
|
7441 |
msgstr ""
|
7442 |
|
7443 |
+
#: includes/template-functions.php:491
|
7444 |
msgid "Plain Text"
|
7445 |
msgstr ""
|
7446 |
|
7447 |
+
#: includes/user-functions.php:507
|
7448 |
msgid "[%s] New User Registration"
|
7449 |
msgstr ""
|
7450 |
|
7451 |
+
#: includes/user-functions.php:508
|
7452 |
msgid "New user registration"
|
7453 |
msgstr ""
|
7454 |
|
7455 |
+
#: includes/user-functions.php:510
|
7456 |
msgid "E-mail: %s"
|
7457 |
msgstr ""
|
7458 |
|
7459 |
+
#: includes/user-functions.php:516
|
7460 |
msgid "[%s] Your username and password"
|
7461 |
msgstr ""
|
7462 |
|
7463 |
+
#: includes/user-functions.php:517
|
7464 |
msgid "Your account info"
|
7465 |
msgstr ""
|
7466 |
|
7467 |
+
#: includes/user-functions.php:521
|
7468 |
+
msgid "Password entered at checkout"
|
7469 |
msgstr ""
|
7470 |
|
7471 |
+
#: includes/user-functions.php:523
|
7472 |
+
msgid "Password entered at registration"
|
7473 |
msgstr ""
|
7474 |
|
7475 |
+
#: includes/user-functions.php:526
|
7476 |
+
msgid "Password: %s"
|
7477 |
+
msgstr ""
|
7478 |
+
|
7479 |
+
#: includes/user-functions.php:528
|
7480 |
msgid "Click Here to Log In"
|
7481 |
msgstr ""
|
7482 |
|
7483 |
+
#: includes/user-functions.php:682 includes/user-functions.php:683
|
7484 |
msgid "Verify your account"
|
7485 |
msgstr ""
|
7486 |
|
7487 |
+
#: includes/user-functions.php:685
|
7488 |
msgid ""
|
7489 |
"Hello %s,\n"
|
7490 |
"\n"
|
7494 |
"Link missing? Visit the following URL: %s"
|
7495 |
msgstr ""
|
7496 |
|
7497 |
+
#: includes/user-functions.php:809
|
7498 |
msgid ""
|
7499 |
"Sorry but your account verification link has expired. <a href=\"#\">Click "
|
7500 |
"here</a> to request a new verification URL."
|
7501 |
msgstr ""
|
7502 |
|
7503 |
+
#: includes/user-functions.php:838
|
|
|
|
|
|
|
|
|
7504 |
msgid "You must be logged in to verify your account."
|
7505 |
msgstr ""
|
7506 |
|
7507 |
+
#: includes/user-functions.php:838 includes/user-functions.php:842
|
7508 |
msgid "Notice"
|
7509 |
msgstr ""
|
7510 |
|
7511 |
+
#: includes/user-functions.php:842
|
7512 |
msgid "Your account has already been verified."
|
7513 |
msgstr ""
|
7514 |
|
7515 |
+
#: includes/user-functions.php:887
|
7516 |
msgid "Invalid verification token provided."
|
7517 |
msgstr ""
|
7518 |
|
7604 |
msgid "Item Price"
|
7605 |
msgstr ""
|
7606 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
7607 |
#: templates/history-downloads.php:3 templates/history-purchases.php:3
|
7608 |
msgid "Your account has been successfully verified!"
|
7609 |
msgstr ""
|
7642 |
msgid "Log into Your Account"
|
7643 |
msgstr ""
|
7644 |
|
|
|
|
|
|
|
|
|
7645 |
#: templates/shortcode-login.php:26
|
7646 |
msgid "Log In"
|
7647 |
msgstr ""
|
7654 |
msgid "You are already logged in"
|
7655 |
msgstr ""
|
7656 |
|
7657 |
+
#: templates/shortcode-profile-editor.php:18
|
7658 |
msgid "Saved cart"
|
7659 |
msgstr ""
|
7660 |
|
7661 |
+
#: templates/shortcode-profile-editor.php:18
|
7662 |
msgid "You have a saved cart, <a href=\"%s\">click here</a> to restore it."
|
7663 |
msgstr ""
|
7664 |
|
7665 |
+
#: templates/shortcode-profile-editor.php:22
|
7666 |
msgid "Your profile has been edited successfully."
|
7667 |
msgstr ""
|
7668 |
|
7669 |
+
#: templates/shortcode-profile-editor.php:31
|
7670 |
msgid "Change your Name"
|
7671 |
msgstr ""
|
7672 |
|
7673 |
+
#: templates/shortcode-profile-editor.php:40
|
7674 |
msgid "Display Name"
|
7675 |
msgstr ""
|
7676 |
|
7677 |
+
#: templates/shortcode-profile-editor.php:58
|
7678 |
+
msgid "Primary Email Address"
|
7679 |
+
msgstr ""
|
7680 |
+
|
7681 |
+
#: templates/shortcode-profile-editor.php:95
|
7682 |
+
msgid "Additional Email Addresses"
|
7683 |
+
msgstr ""
|
7684 |
+
|
7685 |
+
#: templates/shortcode-profile-editor.php:124
|
7686 |
msgid "Change your Billing Address"
|
7687 |
msgstr ""
|
7688 |
|
7689 |
+
#: templates/shortcode-profile-editor.php:126
|
7690 |
msgid "Line 1"
|
7691 |
msgstr ""
|
7692 |
|
7693 |
+
#: templates/shortcode-profile-editor.php:129
|
7694 |
msgid "Line 2"
|
7695 |
msgstr ""
|
7696 |
|
7697 |
+
#: templates/shortcode-profile-editor.php:162
|
7698 |
msgid "Change your Password"
|
7699 |
msgstr ""
|
7700 |
|
7701 |
+
#: templates/shortcode-profile-editor.php:164
|
7702 |
msgid "New Password"
|
7703 |
msgstr ""
|
7704 |
|
7705 |
+
#: templates/shortcode-profile-editor.php:167
|
7706 |
msgid "Re-enter Password"
|
7707 |
msgstr ""
|
7708 |
|
7709 |
+
#: templates/shortcode-profile-editor.php:176
|
|
|
|
|
|
|
|
|
7710 |
msgid "Save Changes"
|
7711 |
msgstr ""
|
7712 |
|
7713 |
+
#: templates/shortcode-profile-editor.php:185
|
7714 |
msgid "You need to login to edit your profile."
|
7715 |
msgstr ""
|
7716 |
|
7766 |
msgid "The easiest way to sell digital products with WordPress."
|
7767 |
msgstr ""
|
7768 |
|
7769 |
+
#: includes/admin/payments/view-order-details.php:493
|
7770 |
msgctxt "Address City"
|
7771 |
msgid "City:"
|
7772 |
msgstr ""
|
7773 |
|
7774 |
+
#: includes/admin/payments/view-order-details.php:498
|
7775 |
msgctxt "Zip / Postal code of address"
|
7776 |
msgid "Zip / Postal Code:"
|
7777 |
msgstr ""
|
7778 |
|
7779 |
+
#: includes/admin/payments/view-order-details.php:505
|
7780 |
msgctxt "Address country"
|
7781 |
msgid "Country:"
|
7782 |
msgstr ""
|
7783 |
|
7784 |
+
#: includes/admin/payments/view-order-details.php:519
|
7785 |
msgctxt "State / province of address"
|
7786 |
msgid "State / Province:"
|
7787 |
msgstr ""
|
7821 |
msgid "%2$s"
|
7822 |
msgstr ""
|
7823 |
|
7824 |
+
#: includes/shortcodes.php:619
|
7825 |
msgctxt "download post type name"
|
7826 |
msgid "No %s found"
|
7827 |
msgstr ""
|
readme.txt
CHANGED
@@ -1,12 +1,12 @@
|
|
1 |
=== Easy Digital Downloads ===
|
2 |
Author URI: https://pippinsplugins.com
|
3 |
Plugin URI: https://easydigitaldownloads.com
|
4 |
-
Contributors: mordauk, sunnyratilal, chriscct7, section214, sumobi, sdavis2702, cklosows, mindctrl, topher1kenobe, sksmatt, SpencerFinnell
|
5 |
Donate link: https://pippinsplugins.com/support-the-site
|
6 |
Tags: download, downloads, e-store, eshop, digital downloads, e-commerce, wp-ecommerce, wp ecommerce
|
7 |
Requires at least: 4.0
|
8 |
Tested up to: 4.6
|
9 |
-
Stable Tag: 2.
|
10 |
|
11 |
License: GNU Version 2 or Any Later Version
|
12 |
|
@@ -214,6 +214,95 @@ Yes, through the addition of one or more of the add-on payment gateways, you can
|
|
214 |
|
215 |
== Changelog ==
|
216 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
217 |
= 2.5.17, June 3, 2016 =
|
218 |
|
219 |
* Fix: Discount codes are not always sent when opt-in tracking is enabled
|
1 |
=== Easy Digital Downloads ===
|
2 |
Author URI: https://pippinsplugins.com
|
3 |
Plugin URI: https://easydigitaldownloads.com
|
4 |
+
Contributors: mordauk, sunnyratilal, chriscct7, section214, sumobi, sdavis2702, cklosows, mindctrl, topher1kenobe, sksmatt, SpencerFinnell, johnstonphilip
|
5 |
Donate link: https://pippinsplugins.com/support-the-site
|
6 |
Tags: download, downloads, e-store, eshop, digital downloads, e-commerce, wp-ecommerce, wp ecommerce
|
7 |
Requires at least: 4.0
|
8 |
Tested up to: 4.6
|
9 |
+
Stable Tag: 2.6
|
10 |
|
11 |
License: GNU Version 2 or Any Later Version
|
12 |
|
214 |
|
215 |
== Changelog ==
|
216 |
|
217 |
+
= 2.6, June 22, 2016 =
|
218 |
+
* New: Added filters to process the earnings as they are updated.
|
219 |
+
* New: Profile Editor state field shows as dropdown when possible.
|
220 |
+
* New: Public API query mode to allow extension developers the ability to create API endpoints that do not require API keys.
|
221 |
+
* New: Add/Improve inline help throughout the plugin with UI Tooltip.
|
222 |
+
* New: Purchased Products column in payment export improved for better parsing.
|
223 |
+
* New: Filters added to EDD_Customer increase and decrease methods.
|
224 |
+
* New: Introduce Version 2 (v2) of the REST API.
|
225 |
+
* New: (API v2) Products endpoint supports category and tag filtering.
|
226 |
+
* New: (API v2) Customers endpoint supports filtering customers by creation date.
|
227 |
+
* New: (API v2) Support searching products.
|
228 |
+
* New: (API v2) Improve discount code reporting.
|
229 |
+
* New: Add price(s) to oEmbed output for downloads.
|
230 |
+
* New: Remove comment/trackback counts from oEmbed output for downloads.
|
231 |
+
* New: Add new edd-table class to all tables outputted by Easy Digital Downloads.
|
232 |
+
* New: Improve discount code status updates by setting inactive when usage reaches max.
|
233 |
+
* New: Add daily cron to mark expired and discount codes at max usage as expired or inactive.
|
234 |
+
* New: Add get_payments() method to the EDD_Customer class.
|
235 |
+
* New: Make download ID more visible on the downloads list table.
|
236 |
+
* New: Add filters to the add_fee() and get_fees() methods of EDD_Fees class.
|
237 |
+
* New: Add price_id support for the Fees API.
|
238 |
+
* New: PayPal Standard payments are now able to be refunded within the WordPress admin.
|
239 |
+
* New: Deprecate edd_get_success_page_url().
|
240 |
+
* New: Add default redirect option to [edd_login] and [edd_register] shortcodes.
|
241 |
+
* New: Introduce customer meta table.
|
242 |
+
* New: Add JavaScript trigger to edd_load_gateway() for 3rd party hooks.
|
243 |
+
* New: Support post__in as an argument in [downloads] shortcode.
|
244 |
+
* New: Final declaration removed from EDD_Payment class.
|
245 |
+
* New: Allow edd_get_payment_status to also accept a payment ID.
|
246 |
+
* New: Support additional email addresses for customers.
|
247 |
+
* New: Add actions into the increase/decrease sales/earnings methods of the EDD_Download class.
|
248 |
+
* New: Added CSV Import functionality.
|
249 |
+
* Tweak: Use internal methods when getting sales counts and files in EDD_Download class.
|
250 |
+
* Tweak: Add campaign tracking to links in the contextual help menus.
|
251 |
+
* Tweak: Improve edd-admin.css coding standards.
|
252 |
+
* Tweak: Update translation .mo files and add development tool for downloading translations from Language Packs.
|
253 |
+
* Tweak: Improve EDD Licenses tab in settings.
|
254 |
+
* Tweak: Improve edd_object_to_array method.
|
255 |
+
* Tweak: Improve mobile breakpoints for customer details view.
|
256 |
+
* Tweak: Remove pagination when [download] shortcode uses 'random' for the sort.
|
257 |
+
* Tweak: Use existing function to build {receipt_link} email tag.
|
258 |
+
* Tweak: PayPal Standard Buy Now was updated to use EDD_Payment.
|
259 |
+
* Fix: New User Email alerts have incorrect header.
|
260 |
+
* Fix: Transient being bypassed in EDD_Payment_Stats::get_earnings().
|
261 |
+
* Fix: Remove unused variable and duplicate post_where filters in EDD_Payment_Stats.
|
262 |
+
* Fix: Correct spelling error in edd_get_paypal_redirect().
|
263 |
+
* Fix: Improved cache key generation in EDD_Payment_Stats::get_earnings().
|
264 |
+
* Fix: Remove deprecated constructor method in System Info browser class.
|
265 |
+
* Fix: Negative cart fees should not have tax charged on them.
|
266 |
+
* Fix: Roles are being initialized on every admin request.
|
267 |
+
* Fix: Negative item fees did not alter the taxation on the item.
|
268 |
+
* Fix: System info shows Must-Use plugins when none are present.
|
269 |
+
* Fix: Cart position (key) is not passed to the hooks in the cart.
|
270 |
+
* Fix: Product dropdown search never shows the current download in results.
|
271 |
+
* Fix: Trim response from country state lookup.
|
272 |
+
* Fix: Update subscribe link in Welcome screen.
|
273 |
+
* Fix: edd_get_users_purchased_products() can sometimes try an array_mege on a non-array value.
|
274 |
+
* Fix: PayPal IPN Verification forced to HTTPS.
|
275 |
+
* Fix: Incorrect earnings across a custom date range report.
|
276 |
+
* Fix: Flat rate discounts can apply an amount larger than the cart total.
|
277 |
+
* Fix: Improve performance of transient deletion when uninstalling Easy Digital Downloads.
|
278 |
+
* Fix: Sales logs show incorrect item amounts with variable pricing sales.
|
279 |
+
* Fix: (a11y) Customer details page icons are not focused.
|
280 |
+
* Fix: (a11y) Removed title attributes.
|
281 |
+
* Fix: (a11y) Focus is lost when removing price option.
|
282 |
+
* Fix: (a11y) Make Add New Price a button when working with variable pricing.
|
283 |
+
* Fix: (a11y) Repeatable field link to remove row should be a button.
|
284 |
+
* Fix: Creating a payment sometimes doesn't save the correct user_id or customer_id.
|
285 |
+
* Fix: Remove old WordPress version compatibility checks for WordPress versions less than 4.0.
|
286 |
+
* Fix: Preview emails use default gateway.
|
287 |
+
* Fix: EDD_API hooks for API key generation fire when extending the base class.
|
288 |
+
* Fix: Remove incorrect messaging on profile editor related to password changes.
|
289 |
+
* Fix: HTML validation fails if schema.org itemtype is missing.
|
290 |
+
* Fix: Clicking 'Complete Purchase' button multiple times can result in Empty Cart error.
|
291 |
+
* Fix: Replace calls to global settings variable with edd_get_option().
|
292 |
+
* Fix: Duplicate get_post_meta calls in EDD_Download class.
|
293 |
+
* Fix: Amazon Payments address field not showing with AJAX disabled.
|
294 |
+
* Fix: Reporting is incorrect when changing predefined dates where year_end changes.
|
295 |
+
* Fix: Allow no gateway to be enabled when purchase is free.
|
296 |
+
* Fix: Item fees not taken into account when using EDD_Payment_Stats::get_earnings() for a specific download.
|
297 |
+
* Fix: Subtotal and Total data attributes using incorrect amounts.
|
298 |
+
* Fix: Taxonomies with numeric slugs are assumed to be the term_id in [downloads] shortcode.
|
299 |
+
* Fix: Multiple instances of variable pricing output for a single product causes label target issue.
|
300 |
+
* Fix: Correct schema.org structured data for items with variable pricing.
|
301 |
+
* Fix: Correct HTML validation for the legend tag on forms by removing span wrappers.
|
302 |
+
* Fix: Schema.org markup missing priceCurrency attribute.
|
303 |
+
* Fix: Use tel input type and patterns to force numeric keyboard on checkout for card number and CVC inputs.
|
304 |
+
* Fix: Settings sanitization for subsections unsets tax rates when a subsection is registered under taxes.
|
305 |
+
|
306 |
= 2.5.17, June 3, 2016 =
|
307 |
|
308 |
* Fix: Discount codes are not always sent when opt-in tracking is enabled
|
templates/checkout_cart.php
CHANGED
@@ -30,11 +30,19 @@ global $post; ?>
|
|
30 |
}
|
31 |
$item_title = edd_get_cart_item_name( $item );
|
32 |
echo '<span class="edd_checkout_cart_item_title">' . esc_html( $item_title ) . '</span>';
|
33 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
34 |
?>
|
35 |
</td>
|
36 |
<td class="edd_cart_item_price">
|
37 |
-
<?php
|
38 |
echo edd_cart_item_price( $item['id'], $item['options'] );
|
39 |
do_action( 'edd_checkout_cart_item_price_after', $item );
|
40 |
?>
|
@@ -118,7 +126,7 @@ global $post; ?>
|
|
118 |
|
119 |
<tr class="edd_cart_footer_row">
|
120 |
<?php do_action( 'edd_checkout_table_footer_first' ); ?>
|
121 |
-
<th colspan="<?php echo edd_checkout_cart_columns(); ?>" class="edd_cart_total"><?php _e( 'Total', 'easy-digital-downloads' ); ?>: <span class="edd_cart_amount" data-subtotal="<?php echo
|
122 |
<?php do_action( 'edd_checkout_table_footer_last' ); ?>
|
123 |
</tr>
|
124 |
</tfoot>
|
30 |
}
|
31 |
$item_title = edd_get_cart_item_name( $item );
|
32 |
echo '<span class="edd_checkout_cart_item_title">' . esc_html( $item_title ) . '</span>';
|
33 |
+
|
34 |
+
/**
|
35 |
+
* Runs after the item in cart's title is echoed
|
36 |
+
* @since 2.6
|
37 |
+
*
|
38 |
+
* @param array $item Cart Item
|
39 |
+
* @param int $key Cart key
|
40 |
+
*/
|
41 |
+
do_action( 'edd_checkout_cart_item_title_after', $item, $key );
|
42 |
?>
|
43 |
</td>
|
44 |
<td class="edd_cart_item_price">
|
45 |
+
<?php
|
46 |
echo edd_cart_item_price( $item['id'], $item['options'] );
|
47 |
do_action( 'edd_checkout_cart_item_price_after', $item );
|
48 |
?>
|
126 |
|
127 |
<tr class="edd_cart_footer_row">
|
128 |
<?php do_action( 'edd_checkout_table_footer_first' ); ?>
|
129 |
+
<th colspan="<?php echo edd_checkout_cart_columns(); ?>" class="edd_cart_total"><?php _e( 'Total', 'easy-digital-downloads' ); ?>: <span class="edd_cart_amount" data-subtotal="<?php echo edd_get_cart_subtotal(); ?>" data-total="<?php echo edd_get_cart_total(); ?>"><?php edd_cart_total(); ?></span></th>
|
130 |
<?php do_action( 'edd_checkout_table_footer_last' ); ?>
|
131 |
</tr>
|
132 |
</tfoot>
|
templates/edd.css
CHANGED
@@ -666,6 +666,21 @@ table#edd_purchase_receipt_products .edd_bundled_product_name {
|
|
666 |
display: inline-block;
|
667 |
width: 200px;
|
668 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
669 |
|
670 |
|
671 |
/* =Alerts
|
@@ -1063,4 +1078,4 @@ p.edd_error {
|
|
1063 |
color: #8a6d3b;
|
1064 |
background-color: #fcf8e3;
|
1065 |
border-color: #faebcc;
|
1066 |
-
}
|
666 |
display: inline-block;
|
667 |
width: 200px;
|
668 |
}
|
669 |
+
#edd_profile_editor_form .edd-profile-emails {
|
670 |
+
list-style-type: none;
|
671 |
+
display: inline-table;
|
672 |
+
margin-left: 0;
|
673 |
+
}
|
674 |
+
#edd_profile_editor_form .edd-profile-email {
|
675 |
+
width: auto;
|
676 |
+
}
|
677 |
+
#edd_profile_editor_form .edd-profile-email .actions {
|
678 |
+
display: none;
|
679 |
+
}
|
680 |
+
#edd_profile_editor_form .edd-profile-email:hover > span {
|
681 |
+
display: inline-block;
|
682 |
+
}
|
683 |
+
|
684 |
|
685 |
|
686 |
/* =Alerts
|
1078 |
color: #8a6d3b;
|
1079 |
background-color: #fcf8e3;
|
1080 |
border-color: #faebcc;
|
1081 |
+
}
|
templates/edd.min.css
CHANGED
@@ -1 +1 @@
|
|
1 |
-
@charset "UTF-8";@font-face{font-family:EDD-Icons;src:url(fonts/EDD-Icons.eot);src:url(fonts/EDD-Icons.eot?#iefix) format('embedded-opentype'),url(fonts/EDD-Icons.woff) format('woff'),url(fonts/EDD-Icons.ttf) format('truetype'),url(fonts/EDD-Icons.svg#EDD-Icons) format('svg');font-weight:400;font-style:normal}[class*=edd-icon-],[class*=" edd-icon-"]{font-family:EDD-Icons;speak:none;font-style:normal;font-weight:400;font-variant:normal;text-transform:none;width:auto;height:auto;line-height:1;-webkit-font-smoothing:antialiased}[class*=edd-icon-]:before,[class*=" edd-icon-"]:before{text-decoration:inherit;display:inline-block;cursor:default;speak:none}.edd-icon-spinner:before{content:"\71"}.edd-icon-ok:before{content:"\77"}.edd-icon-remove:before{content:"\65"}.edd-icon-remove-circle:before{content:"\72"}.edd-icon-ok-circle:before{content:"\74"}#edd_checkout_form_wrap label:after,.edd_clearfix:after{visibility:hidden;float:none;text-indent:-9999px;content:".";clear:both}.edd-icon-spin{display:inline-block;-moz-animation:edd-icon-spin 2s infinite linear;-o-animation:edd-icon-spin 2s infinite linear;-webkit-animation:edd-icon-spin 2s infinite linear;animation:edd-icon-spin 2s infinite linear}@-moz-keyframes edd-icon-spin{0%{-moz-transform:rotate(0)}100%{-moz-transform:rotate(359deg)}}@-webkit-keyframes edd-icon-spin{0%{-webkit-transform:rotate(0)}100%{-webkit-transform:rotate(359deg)}}@-o-keyframes edd-icon-spin{0%{-o-transform:rotate(0)}100%{-o-transform:rotate(359deg)}}@-ms-keyframes edd-icon-spin{0%{-ms-transform:rotate(0)}100%{-ms-transform:rotate(359deg)}}@keyframes edd-icon-spin{0%{transform:rotate(0)}100%{transform:rotate(359deg)}}.edd_clearfix:after{display:block}#edd_checkout_cart{text-align:left;width:100%;border:none;margin:0 0 21px;table-layout:auto}#edd_checkout_cart td,#edd_checkout_cart th{text-align:left;border:1px solid #eee;color:#666;padding:.5em 1.387em}#edd_checkout_cart .edd_cart_header_row th{background:#fafafa;padding:1.387em}#edd_checkout_cart .edd_cart_discount_row th,#edd_checkout_cart .edd_cart_tax_row th{background:0 0}#edd_checkout_cart th{font-weight:700}#edd_checkout_cart td{line-height:25px;vertical-align:middle;background:#fff}#edd_checkout_cart td.edd_cart_actions,#edd_checkout_cart td:last-child,#edd_checkout_cart th.edd_cart_actions,#edd_checkout_cart th.edd_cart_total,#edd_checkout_cart th:last-child{text-align:right}#edd_checkout_cart td img{float:left;margin:0 8px 0 0;background:0 0;padding:0;border:none}#edd_checkout_cart input.edd-item-quantity{width:3em;padding:2px}#edd_checkout_cart .edd_discount{display:inline-block;margin-left:5px}.edd_discount_remove{display:inline-block;width:10px;height:11px;background:url(images/xit.gif) no-repeat;position:relative;top:3px}.edd_discount_remove:hover{background-position:-10px 0}#edd_checkout_cart br{display:none}#edd_checkout_cart a.edd-cart-saving-button{font-weight:400;text-decoration:none}#edd_checkout_form_wrap legend{display:block;font-size:120%;line-height:1;font-weight:700;width:100%;margin:0 0 21px;padding:0}#edd_checkout_form_wrap label{font-weight:700;display:block;position:relative;line-height:100%;font-size:95%;margin:0 0 5px}#edd_checkout_form_wrap label:after{display:block;height:0}#edd_checkout_form_wrap span.edd-description{color:#666;font-size:80%;display:block;margin:0 0 5px}#edd_checkout_form_wrap input.edd-input,#edd_checkout_form_wrap textarea.edd-input{display:inline-block;width:70%}#edd_checkout_form_wrap select.edd-select{display:block;width:60%}#edd_checkout_form_wrap select.edd-select.edd-select-small{display:inline;width:auto}#edd_checkout_form_wrap input.edd-input.error,#edd_checkout_form_wrap textarea.edd-input.error{border-color:#c4554e}#edd_checkout_form_wrap>p{margin:0 0 21px}#edd_checkout_form_wrap span.edd-required-indicator{color:#b94a48;display:inline}#edd_checkout_form_wrap input[type=text],#edd_checkout_form_wrap input[type=email],#edd_checkout_form_wrap input[type=password],#edd_checkout_form_wrap textarea{padding:4px 6px}#edd_checkout_form_wrap input[type=radio]{border:none;margin-right:5px}#edd_checkout_form_wrap input[type=checkbox]{display:inline-block;margin:0 5px 0 0}#edd_checkout_form_wrap input[type=checkbox]+label,#edd_checkout_form_wrap input[type=checkbox]+label:after{display:inline}#edd_checkout_form_wrap .edd-payment-icons{height:32px;display:block;margin:0 0 8px}#edd_checkout_form_wrap .edd-payment-icons img.payment-icon{max-height:32px;width:auto;margin:0 3px 0 0;float:left;background:0 0;padding:0;border:none;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}#edd_checkout_form_wrap #edd-payment-mode-wrap label{display:inline-block;margin:0 20px 0 0}#edd_checkout_form_wrap #edd-payment-mode-wrap .edd-payment-mode-label{font-weight:700;display:inline-block;position:relative;margin-bottom:5px}#edd_checkout_form_wrap fieldset{border:1px solid #eee;padding:1.387em;margin:0 0 21px}#edd_checkout_form_wrap #edd_discount_code,#edd_checkout_form_wrap #edd_purchase_submit,#edd_checkout_form_wrap #edd_register_account_fields{padding:0;border:none}#edd_checkout_form_wrap fieldset fieldset{margin:0;border:none;padding:0}#edd_checkout_form_wrap #edd-login-account-wrap,#edd_checkout_form_wrap #edd-new-account-wrap,#edd_checkout_form_wrap #edd_final_total_wrap,#edd_checkout_form_wrap #edd_show_discount,#edd_checkout_form_wrap .edd-cart-adjustment{background:#fafafa;color:#666;padding:.5em 1.387em}#edd_checkout_form_wrap #edd-discount-code-wrap,#edd_checkout_form_wrap #edd_final_total_wrap,#edd_checkout_form_wrap #edd_show_discount{border:1px solid #eee}#edd_checkout_form_wrap .edd-cart-adjustment{padding:1.387em}#edd_checkout_form_wrap .edd-cart-adjustment input.edd-input,#edd_checkout_form_wrap .edd-cart-adjustment input.edd-submit{display:inline-block}#edd_checkout_form_wrap .edd-cart-adjustment input.edd-submit{padding:3px 12px;margin-bottom:2px}#edd_checkout_form_wrap #edd_purchase_final_total p,#edd_checkout_form_wrap fieldset#edd_register_account_fields p.edd_login_password,#edd_checkout_form_wrap fieldset#edd_register_account_fields p.edd_register_password{margin:0}#edd_checkout_form_wrap #edd-discount-error-wrap{width:100%;display:inline-block;margin:1em 0 0}#edd_checkout_form_wrap #edd-login-account-wrap,#edd_checkout_form_wrap #edd-new-account-wrap{margin:-1.387em -1.387em 21px;border-left:none;border-right:none;border-top:none}#edd_checkout_form_wrap #edd_payment_mode_select,#edd_checkout_form_wrap fieldset#edd_register_fields #edd_checkout_user_info{margin-bottom:21px}#edd_checkout_form_wrap fieldset#edd_register_account_fields legend{padding-top:11px}#edd_checkout_form_wrap fieldset#edd_cc_fields{border:1px solid #f0f0f0;background:#f9f9f9;position:relative}#edd_checkout_form_wrap fieldset#edd_cc_fields legend{border:none;padding:0}#edd_checkout_form_wrap fieldset p:last-child{margin-bottom:0}#edd_checkout_form_wrap fieldset#edd_cc_fields #edd-card-number-wrap{margin-top:5px}#edd_checkout_form_wrap #edd_purchase_final_total{margin:21px 0}#edd_secure_site_wrapper{padding:4px 4px 4px 0;font-weight:700}#edd_secure_site_wrapper span.padlock:before{content:'\f160';display:inline-block;-webkit-font-smoothing:antialiased;font:400 20px/1 dashicons;vertical-align:top}#edd_checkout_form_wrap input.edd-input.card-number.valid{background-image:url(images/tick.png);background-repeat:no-repeat;background-position:98% 50%}#edd_checkout_form_wrap span.exp-divider{display:inline}#edd_checkout_form_wrap span.card-type{position:absolute;top:-2px;right:0;width:43px;height:32px;background-size:43px 32px!important}#edd_checkout_form_wrap span.card-type.off{display:none}#edd_checkout_form_wrap span.card-type.visa{background:url(images/icons/visa.gif) no-repeat}#edd_checkout_form_wrap span.card-type.mastercard{background:url(images/icons/mastercard.gif) no-repeat}#edd_checkout_form_wrap span.card-type.discover{background:url(images/icons/discover.gif) no-repeat}#edd_checkout_form_wrap span.card-type.amex{background:url(images/icons/americanexpress.gif) no-repeat}#edd_checkeout_form_wrap .edd-cart-ajax,#edd_checkout_form_wrap #edd-discount-loader{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}.edd-amazon-profile-wrapper{font-size:12px}.edd-amazon-profile-name{font-weight:600}.edd-amazon-logout{font-size:10px;line-height:12px}.edd-amazon-logout a{cursor:pointer}#edd-amazon-address-box,#edd-amazon-wallet-box{height:228px;width:350px}#edd-amazon-address-box{margin-bottom:15px}@media only screen and (min-width:768px){#edd-amazon-address-box,#edd-amazon-wallet-box{width:100%;height:228px}}.edd_purchase_submit_wrapper{position:relative}.edd_purchase_submit_wrapper a.edd-add-to-cart{text-decoration:none;display:none;position:relative;overflow:hidden}.edd_purchase_submit_wrapper a.edd-add-to-cart.edd-has-js{display:inline-block}.edd_purchase_submit_wrapper .edd-cart-ajax{display:none;position:relative;left:-35px}.edd-submit.button.edd-ajax-loading{padding-right:30px}.edd-add-to-cart .edd-add-to-cart-label{opacity:1;filter:alpha(opacity=100)}.edd-add-to-cart[data-edd-loading] .edd-add-to-cart-label,a.edd-add-to-cart .edd-loading{opacity:0;filter:alpha(opacity=0)}a.edd-add-to-cart .edd-loading{position:absolute;left:50%;top:50%}a.edd-add-to-cart .edd-add-to-cart-label,a.edd-add-to-cart .edd-loading{-webkit-transition:.1s opacity!important;-moz-transition:.1s opacity!important;-ms-transition:.1s opacity!important;-o-transition:.1s opacity!important;transition:.1s opacity!important}.edd-add-to-cart[data-edd-loading] .edd-loading{opacity:1;filter:alpha(opacity=100)}.edd-cart-added-alert{color:#567622;display:block;position:absolute}.edd-cart-ajax,body.edd_receipt_page:before{position:relative}.edd_form input.edd-input.required,.edd_form select.edd-select.required{color:#000}body.edd_receipt_page{background-color:#fff;color:#141412;margin:0;font-family:Helvetica,sans-serif;font-size:12px}#edd_user_history .edd_purchase_status.cancelled,#edd_user_history .edd_purchase_status.failed,#edd_user_history .edd_purchase_status.pending,#edd_user_history .edd_purchase_status.revoked,table#edd_purchase_receipt .edd_receipt_payment_status.cancelled,table#edd_purchase_receipt .edd_receipt_payment_status.failed,table#edd_purchase_receipt .edd_receipt_payment_status.pending,table#edd_purchase_receipt .edd_receipt_payment_status.revoked{color:#f73f2e}body.edd_receipt_page #edd_receipt_wrapper{width:660px;margin:0 auto;padding:50px 0}body.edd_receipt_page table{display:table;width:100%;border-bottom:1px solid #ededed;border-collapse:collapse;border-spacing:0;font-size:14px;line-height:2;margin:0 0 20px}body.edd_receipt_page td,body.edd_receipt_page th{display:table-cell;text-align:left;border-top:1px solid #ededed;padding:6px 10px;font-weight:400}body.edd_receipt_page th{font-weight:700;text-transform:uppercase}body.edd_receipt_page h3{font-size:22px;margin:40px 0 5px;clear:both;display:block;font-weight:700}#edd_login_form .edd-input,#edd_login_form label,#edd_profile_editor_form label,#edd_register_form .edd-input,#edd_register_form label{display:inline-block;width:200px}body.edd_receipt_page li{list-style:none}table#edd_purchase_receipt,table#edd_purchase_receipt_products{width:100%}table#edd_purchase_receipt td,table#edd_purchase_receipt th,table#edd_purchase_receipt_products td,table#edd_purchase_receipt_products th{text-align:left}table#edd_purchase_receipt_products li{list-style:none;margin:0 0 8px 10px}table#edd_purchase_receipt ul,table#edd_purchase_receipt_products ul.edd_purchase_receipt_files{margin:0;padding:0}table#edd_purchase_receipt li.edd_download_file{list-style:none;margin:0 0 8px}table#edd_purchase_receipt_products .edd_purchase_receipt_product_notes{font-style:italic}table#edd_purchase_receipt_products .edd_purchase_receipt_product_name{font-weight:700}table#edd_purchase_receipt_products .edd_bundled_product_name{font-style:italic;font-weight:700}#edd_user_history{text-align:left;width:100%;border-top:1px solid #f0f0f0;border-bottom:none}#edd_user_history td,#edd_user_history th{text-align:left;padding:3px 5px;border-bottom:1px solid #f0f0f0;border-top:none}#edd_user_history th{font-weight:700;background:#f5f5f5}#edd_user_history td{line-height:25px;vertical-align:middle}#edd_profile_editor_form p{margin-bottom:8px}.edd_added_to_cart_alert{padding:5px;font-size:14px;border:1px solid #046a9e;background:#9ecce2;color:#333;margin:8px 0}.edd_added_to_cart_alert a.edd_alert_checkout_link{color:#000!important}input.edd_submit_plain{background:0 0!important;border:none!important;padding:0!important;display:inline;cursor:pointer}.single-download .edd_download_purchase_form{margin-bottom:1.387em}.edd_download_purchase_form .edd_download_quantity_wrapper{margin:0 0 .5em}.edd_download_purchase_form .edd_download_quantity_wrapper .edd-item-quantity{width:75px}.edd_download_purchase_form .edd_price_options{margin:0 0 15px}.edd_download_purchase_form .edd_price_options ul{margin:0;padding:0;list-style:none}.edd_download_purchase_form .edd_price_options li{display:block;padding:0;margin:0}.edd_download_purchase_form .edd_price_options span{display:inline;padding:0;margin:0}.edd_download_purchase_form .edd_price_options .edd_download_quantity_wrapper{padding-left:18px}.edd_download_purchase_form .edd_price_options .edd_download_quantity_wrapper *{font-size:80%}.edd_download_purchase_form .edd_price_options input.edd-item-quantity{display:inline;width:50px;max-width:90%}#edd-purchase-button,.edd-submit,input[type=submit].edd-submit{display:inline-block;padding:6px 12px;margin:0;font-size:14px;font-weight:400;line-height:1.428571429;text-align:center;white-space:nowrap;vertical-align:middle;cursor:pointer;border:1px solid #ccc;border-radius:4px;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;-o-user-select:none;user-select:none}.edd-submit.button:focus,input[type=submit].edd-submit:focus{outline:#333 dotted thin;outline:-webkit-focus-ring-color auto 5px;outline-offset:-2px}.edd-submit.button:focus,.edd-submit.button:hover,input[type=submit].edd-submit:focus,input[type=submit].edd-submit:hover{color:#333;text-decoration:none}.edd-submit.button:active{background-image:none;outline:0;-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.edd-submit.plain{padding:0}.edd-submit.button,.edd-submit.button.gray,.edd-submit.button:visited{color:#333;background:#f0f0f0;border-color:#ccc}.edd-submit.button.gray:active,.edd-submit.button.gray:focus,.edd-submit.button.gray:hover,.edd-submit.button:active,.edd-submit.button:focus,.edd-submit.button:hover{color:#333;background:#ebebeb;border-color:#adadad}.edd-submit.button.gray:active{background-image:none}.edd-submit.button.white{color:#333;background:#fff;border-color:#ccc}.edd-submit.button.white:active,.edd-submit.button.white:focus,.edd-submit.button.white:hover{color:#333;background:#ebebeb;border-color:#adadad}.edd-submit.button.white:active{background-image:none}.edd-submit.button.blue{color:#fff;background:#428bca;border-color:#357ebd}.edd-submit.button.blue.active,.edd-submit.button.blue:focus,.edd-submit.button.blue:hover{color:#fff;background:#3276b1;border-color:#285e8e}.edd-submit.button.blue.active{background-image:none}.edd-submit.button.red{color:#fff;background:#d9534f;border-color:#d43f3a}.edd-submit.button.red:active,.edd-submit.button.red:focus,.edd-submit.button.red:hover{color:#fff;background:#d2322d;border-color:#ac2925}.edd-submit.button.red:active{background-image:none}.edd-submit.button.green{color:#fff;background:#5cb85c;border-color:#4cae4c}.edd-submit.button.green:active,.edd-submit.button.green:focus,.edd-submit.button.green:hover{color:#fff;background:#47a447;border-color:#398439}.edd-submit.button.green:active{background-image:none}.edd-submit.button.yellow{color:#fff;background:#f0ad4e;border-color:#eea236}.edd-submit.button.yellow:active,.edd-submit.button.yellow:focus,.edd-submit.button.yellow:hover{color:#fff;background:#ed9c28;border-color:#d58512}.edd-submit.button.yellow:active{background-image:none}.edd-submit.button.orange{color:#fff;background:#ed9c28;border-color:#e3921e}.edd-submit.button.orange:active,.edd-submit.button.orange:focus,.edd-submit.button.orange:hover{color:#fff;background:#e59016;border-color:#d58512}.edd-submit.button.orange:active{background-image:none}.edd-submit.button.dark-gray{color:#fff;background:#363636;border-color:#222}.edd-submit.button.dark-gray:active,.edd-submit.button.dark-gray:focus,.edd-submit.button.dark-gray:hover{color:#fff;background:#333;border-color:#adadad}.edd-submit.button.dark-gray:active{background-image:none}.edd_download{float:left}.edd_download_columns_1 .edd_download{width:100%}.edd_download_columns_2 .edd_download{width:50%}.edd_download_columns_0 .edd_download,.edd_download_columns_3 .edd_download{width:33%}.edd_download_columns_4 .edd_download{width:25%}.edd_download_columns_5 .edd_download{width:20%}.edd_download_columns_6 .edd_download{width:16.6%}.edd_download_inner{padding:0 8px 8px;margin:0 0 10px}.edd_download_image{max-width:100%}.edd_download .edd_price{margin-bottom:10px}.edd-cart-ajax{margin:0 8px 0 4px;top:2px;background:0 0;border:none;padding:0}.edd-cart-number-of-items{font-style:italic;color:grey}.edd-cart-meta.edd_subtotal{font-weight:700;font-style:italic}.edd-cart-meta.edd_cart_tax{font-size:1em;font-style:italic}.edd-cart-meta.edd_cart_tax::before{font-style:normal}.edd-cart-meta.edd_total{font-weight:700}.edd-cart-meta{padding:2px 5px}.edd-cart-meta.edd_subtotal,.edd-cart-meta.edd_total{background-color:#f9f9f9}.edd_errors:not(.edd-alert){-webkit-border-radius:2px;-moz-border-radius:2px;border-radius:2px;border:1px solid #E6DB55;margin:0 0 21px;background:#FFFFE0;color:#333}.edd_error{padding:10px}p.edd_error{margin:0!important}.edd_success:not(.edd-alert){-webkit-border-radius:2px;-moz-border-radius:2px;border-radius:2px;border:1px solid #b3ce89;margin:20px 0;background:#d5eab3;color:#567622;padding:6px 8px;box-shadow:inset 0 1px 0 rgba(255,255,255,.7)}.edd-alert{-webkit-border-radius:2px;-moz-border-radius:2px;border-radius:2px;margin-bottom:20px;padding:10px;border:1px solid transparent;vertical-align:middle}.edd-alert p{padding:0}.edd-alert p:not(:last-child){margin-bottom:5px}.edd-alert p:last-child{margin-bottom:0}.edd-alert-error{color:#a94442;background-color:#f2dede;border-color:#ebccd1}.edd-alert-success{background-color:#dff0d8;border-color:#d6e9c6;color:#3c763d}.edd-alert-info{color:#31708f;background-color:#d9edf7;border-color:#bce8f1}.edd-alert-warn{color:#8a6d3b;background-color:#fcf8e3;border-color:#faebcc}
|
1 |
+
@charset "UTF-8";@font-face{font-family:EDD-Icons;src:url(fonts/EDD-Icons.eot);src:url(fonts/EDD-Icons.eot?#iefix) format('embedded-opentype'),url(fonts/EDD-Icons.woff) format('woff'),url(fonts/EDD-Icons.ttf) format('truetype'),url(fonts/EDD-Icons.svg#EDD-Icons) format('svg');font-weight:400;font-style:normal}[class*=edd-icon-],[class*=" edd-icon-"]{font-family:EDD-Icons;speak:none;font-style:normal;font-weight:400;font-variant:normal;text-transform:none;width:auto;height:auto;line-height:1;-webkit-font-smoothing:antialiased}[class*=edd-icon-]:before,[class*=" edd-icon-"]:before{text-decoration:inherit;display:inline-block;cursor:default;speak:none}.edd-icon-spinner:before{content:"\71"}.edd-icon-ok:before{content:"\77"}.edd-icon-remove:before{content:"\65"}.edd-icon-remove-circle:before{content:"\72"}.edd-icon-ok-circle:before{content:"\74"}#edd_checkout_form_wrap label:after,.edd_clearfix:after{visibility:hidden;float:none;text-indent:-9999px;content:".";clear:both}.edd-icon-spin{display:inline-block;-moz-animation:edd-icon-spin 2s infinite linear;-o-animation:edd-icon-spin 2s infinite linear;-webkit-animation:edd-icon-spin 2s infinite linear;animation:edd-icon-spin 2s infinite linear}@-moz-keyframes edd-icon-spin{0%{-moz-transform:rotate(0)}100%{-moz-transform:rotate(359deg)}}@-webkit-keyframes edd-icon-spin{0%{-webkit-transform:rotate(0)}100%{-webkit-transform:rotate(359deg)}}@-o-keyframes edd-icon-spin{0%{-o-transform:rotate(0)}100%{-o-transform:rotate(359deg)}}@-ms-keyframes edd-icon-spin{0%{-ms-transform:rotate(0)}100%{-ms-transform:rotate(359deg)}}@keyframes edd-icon-spin{0%{transform:rotate(0)}100%{transform:rotate(359deg)}}.edd_clearfix:after{display:block}#edd_checkout_cart{text-align:left;width:100%;border:none;margin:0 0 21px;table-layout:auto}#edd_checkout_cart td,#edd_checkout_cart th{text-align:left;border:1px solid #eee;color:#666;padding:.5em 1.387em}#edd_checkout_cart .edd_cart_header_row th{background:#fafafa;padding:1.387em}#edd_checkout_cart .edd_cart_discount_row th,#edd_checkout_cart .edd_cart_tax_row th{background:0 0}#edd_checkout_cart th{font-weight:700}#edd_checkout_cart td{line-height:25px;vertical-align:middle;background:#fff}#edd_checkout_cart td.edd_cart_actions,#edd_checkout_cart td:last-child,#edd_checkout_cart th.edd_cart_actions,#edd_checkout_cart th.edd_cart_total,#edd_checkout_cart th:last-child{text-align:right}#edd_checkout_cart td img{float:left;margin:0 8px 0 0;background:0 0;padding:0;border:none}#edd_checkout_cart input.edd-item-quantity{width:3em;padding:2px}#edd_checkout_cart .edd_discount{display:inline-block;margin-left:5px}.edd_discount_remove{display:inline-block;width:10px;height:11px;background:url(images/xit.gif) no-repeat;position:relative;top:3px}.edd_discount_remove:hover{background-position:-10px 0}#edd_checkout_cart br{display:none}#edd_checkout_cart a.edd-cart-saving-button{font-weight:400;text-decoration:none}#edd_checkout_form_wrap legend{display:block;font-size:120%;line-height:1;font-weight:700;width:100%;margin:0 0 21px;padding:0}#edd_checkout_form_wrap label{font-weight:700;display:block;position:relative;line-height:100%;font-size:95%;margin:0 0 5px}#edd_checkout_form_wrap label:after{display:block;height:0}#edd_checkout_form_wrap span.edd-description{color:#666;font-size:80%;display:block;margin:0 0 5px}#edd_checkout_form_wrap input.edd-input,#edd_checkout_form_wrap textarea.edd-input{display:inline-block;width:70%}#edd_checkout_form_wrap select.edd-select{display:block;width:60%}#edd_checkout_form_wrap select.edd-select.edd-select-small{display:inline;width:auto}#edd_checkout_form_wrap input.edd-input.error,#edd_checkout_form_wrap textarea.edd-input.error{border-color:#c4554e}#edd_checkout_form_wrap>p{margin:0 0 21px}#edd_checkout_form_wrap span.edd-required-indicator{color:#b94a48;display:inline}#edd_checkout_form_wrap input[type=text],#edd_checkout_form_wrap input[type=email],#edd_checkout_form_wrap input[type=password],#edd_checkout_form_wrap textarea{padding:4px 6px}#edd_checkout_form_wrap input[type=radio]{border:none;margin-right:5px}#edd_checkout_form_wrap input[type=checkbox]{display:inline-block;margin:0 5px 0 0}#edd_checkout_form_wrap input[type=checkbox]+label,#edd_checkout_form_wrap input[type=checkbox]+label:after{display:inline}#edd_checkout_form_wrap .edd-payment-icons{height:32px;display:block;margin:0 0 8px}#edd_checkout_form_wrap .edd-payment-icons img.payment-icon{max-height:32px;width:auto;margin:0 3px 0 0;float:left;background:0 0;padding:0;border:none;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}#edd_checkout_form_wrap #edd-payment-mode-wrap label{display:inline-block;margin:0 20px 0 0}#edd_checkout_form_wrap #edd-payment-mode-wrap .edd-payment-mode-label{font-weight:700;display:inline-block;position:relative;margin-bottom:5px}#edd_checkout_form_wrap fieldset{border:1px solid #eee;padding:1.387em;margin:0 0 21px}#edd_checkout_form_wrap #edd_discount_code,#edd_checkout_form_wrap #edd_purchase_submit,#edd_checkout_form_wrap #edd_register_account_fields{padding:0;border:none}#edd_checkout_form_wrap fieldset fieldset{margin:0;border:none;padding:0}#edd_checkout_form_wrap #edd-login-account-wrap,#edd_checkout_form_wrap #edd-new-account-wrap,#edd_checkout_form_wrap #edd_final_total_wrap,#edd_checkout_form_wrap #edd_show_discount,#edd_checkout_form_wrap .edd-cart-adjustment{background:#fafafa;color:#666;padding:.5em 1.387em}#edd_checkout_form_wrap #edd-discount-code-wrap,#edd_checkout_form_wrap #edd_final_total_wrap,#edd_checkout_form_wrap #edd_show_discount{border:1px solid #eee}#edd_checkout_form_wrap .edd-cart-adjustment{padding:1.387em}#edd_checkout_form_wrap .edd-cart-adjustment input.edd-input,#edd_checkout_form_wrap .edd-cart-adjustment input.edd-submit{display:inline-block}#edd_checkout_form_wrap .edd-cart-adjustment input.edd-submit{padding:3px 12px;margin-bottom:2px}#edd_checkout_form_wrap #edd_purchase_final_total p,#edd_checkout_form_wrap fieldset#edd_register_account_fields p.edd_login_password,#edd_checkout_form_wrap fieldset#edd_register_account_fields p.edd_register_password{margin:0}#edd_checkout_form_wrap #edd-discount-error-wrap{width:100%;display:inline-block;margin:1em 0 0}#edd_checkout_form_wrap #edd-login-account-wrap,#edd_checkout_form_wrap #edd-new-account-wrap{margin:-1.387em -1.387em 21px;border-left:none;border-right:none;border-top:none}#edd_checkout_form_wrap #edd_payment_mode_select,#edd_checkout_form_wrap fieldset#edd_register_fields #edd_checkout_user_info{margin-bottom:21px}#edd_checkout_form_wrap fieldset#edd_register_account_fields legend{padding-top:11px}#edd_checkout_form_wrap fieldset#edd_cc_fields{border:1px solid #f0f0f0;background:#f9f9f9;position:relative}#edd_checkout_form_wrap fieldset#edd_cc_fields legend{border:none;padding:0}#edd_checkout_form_wrap fieldset p:last-child{margin-bottom:0}#edd_checkout_form_wrap fieldset#edd_cc_fields #edd-card-number-wrap{margin-top:5px}#edd_checkout_form_wrap #edd_purchase_final_total{margin:21px 0}#edd_secure_site_wrapper{padding:4px 4px 4px 0;font-weight:700}#edd_secure_site_wrapper span.padlock:before{content:'\f160';display:inline-block;-webkit-font-smoothing:antialiased;font:400 20px/1 dashicons;vertical-align:top}#edd_checkout_form_wrap input.edd-input.card-number.valid{background-image:url(images/tick.png);background-repeat:no-repeat;background-position:98% 50%}#edd_checkout_form_wrap span.exp-divider{display:inline}#edd_checkout_form_wrap span.card-type{position:absolute;top:-2px;right:0;width:43px;height:32px;background-size:43px 32px!important}#edd_checkout_form_wrap span.card-type.off{display:none}#edd_checkout_form_wrap span.card-type.visa{background:url(images/icons/visa.gif) no-repeat}#edd_checkout_form_wrap span.card-type.mastercard{background:url(images/icons/mastercard.gif) no-repeat}#edd_checkout_form_wrap span.card-type.discover{background:url(images/icons/discover.gif) no-repeat}#edd_checkout_form_wrap span.card-type.amex{background:url(images/icons/americanexpress.gif) no-repeat}#edd_checkeout_form_wrap .edd-cart-ajax,#edd_checkout_form_wrap #edd-discount-loader{-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}.edd-amazon-profile-wrapper{font-size:12px}.edd-amazon-profile-name{font-weight:600}.edd-amazon-logout{font-size:10px;line-height:12px}.edd-amazon-logout a{cursor:pointer}#edd-amazon-address-box,#edd-amazon-wallet-box{height:228px;width:350px}#edd-amazon-address-box{margin-bottom:15px}@media only screen and (min-width:768px){#edd-amazon-address-box,#edd-amazon-wallet-box{width:100%;height:228px}}.edd_purchase_submit_wrapper{position:relative}.edd_purchase_submit_wrapper a.edd-add-to-cart{text-decoration:none;display:none;position:relative;overflow:hidden}.edd_purchase_submit_wrapper a.edd-add-to-cart.edd-has-js{display:inline-block}.edd_purchase_submit_wrapper .edd-cart-ajax{display:none;position:relative;left:-35px}.edd-submit.button.edd-ajax-loading{padding-right:30px}.edd-add-to-cart .edd-add-to-cart-label{opacity:1;filter:alpha(opacity=100)}.edd-add-to-cart[data-edd-loading] .edd-add-to-cart-label,a.edd-add-to-cart .edd-loading{opacity:0;filter:alpha(opacity=0)}a.edd-add-to-cart .edd-loading{position:absolute;left:50%;top:50%}a.edd-add-to-cart .edd-add-to-cart-label,a.edd-add-to-cart .edd-loading{-webkit-transition:.1s opacity!important;-moz-transition:.1s opacity!important;-ms-transition:.1s opacity!important;-o-transition:.1s opacity!important;transition:.1s opacity!important}.edd-add-to-cart[data-edd-loading] .edd-loading{opacity:1;filter:alpha(opacity=100)}.edd-cart-added-alert{color:#567622;display:block;position:absolute}.edd-cart-ajax,body.edd_receipt_page:before{position:relative}.edd_form input.edd-input.required,.edd_form select.edd-select.required{color:#000}body.edd_receipt_page{background-color:#fff;color:#141412;margin:0;font-family:Helvetica,sans-serif;font-size:12px}#edd_user_history .edd_purchase_status.cancelled,#edd_user_history .edd_purchase_status.failed,#edd_user_history .edd_purchase_status.pending,#edd_user_history .edd_purchase_status.revoked,table#edd_purchase_receipt .edd_receipt_payment_status.cancelled,table#edd_purchase_receipt .edd_receipt_payment_status.failed,table#edd_purchase_receipt .edd_receipt_payment_status.pending,table#edd_purchase_receipt .edd_receipt_payment_status.revoked{color:#f73f2e}body.edd_receipt_page #edd_receipt_wrapper{width:660px;margin:0 auto;padding:50px 0}body.edd_receipt_page table{display:table;width:100%;border-bottom:1px solid #ededed;border-collapse:collapse;border-spacing:0;font-size:14px;line-height:2;margin:0 0 20px}body.edd_receipt_page td,body.edd_receipt_page th{display:table-cell;text-align:left;border-top:1px solid #ededed;padding:6px 10px;font-weight:400}body.edd_receipt_page th{font-weight:700;text-transform:uppercase}body.edd_receipt_page h3{font-size:22px;margin:40px 0 5px;clear:both;display:block;font-weight:700}#edd_login_form .edd-input,#edd_login_form label,#edd_profile_editor_form label,#edd_register_form .edd-input,#edd_register_form label{display:inline-block;width:200px}body.edd_receipt_page li{list-style:none}table#edd_purchase_receipt,table#edd_purchase_receipt_products{width:100%}table#edd_purchase_receipt td,table#edd_purchase_receipt th,table#edd_purchase_receipt_products td,table#edd_purchase_receipt_products th{text-align:left}table#edd_purchase_receipt_products li{list-style:none;margin:0 0 8px 10px}table#edd_purchase_receipt ul,table#edd_purchase_receipt_products ul.edd_purchase_receipt_files{margin:0;padding:0}table#edd_purchase_receipt li.edd_download_file{list-style:none;margin:0 0 8px}table#edd_purchase_receipt_products .edd_purchase_receipt_product_notes{font-style:italic}table#edd_purchase_receipt_products .edd_purchase_receipt_product_name{font-weight:700}table#edd_purchase_receipt_products .edd_bundled_product_name{font-style:italic;font-weight:700}#edd_user_history{text-align:left;width:100%;border-top:1px solid #f0f0f0;border-bottom:none}#edd_user_history td,#edd_user_history th{text-align:left;padding:3px 5px;border-bottom:1px solid #f0f0f0;border-top:none}#edd_user_history th{font-weight:700;background:#f5f5f5}#edd_user_history td{line-height:25px;vertical-align:middle}#edd_profile_editor_form p{margin-bottom:8px}#edd_profile_editor_form .edd-profile-emails{list-style-type:none;display:inline-table;margin-left:0}#edd_profile_editor_form .edd-profile-email{width:auto}#edd_profile_editor_form .edd-profile-email .actions{display:none}#edd_profile_editor_form .edd-profile-email:hover>span{display:inline-block}.edd_added_to_cart_alert{padding:5px;font-size:14px;border:1px solid #046a9e;background:#9ecce2;color:#333;margin:8px 0}.edd_added_to_cart_alert a.edd_alert_checkout_link{color:#000!important}input.edd_submit_plain{background:0 0!important;border:none!important;padding:0!important;display:inline;cursor:pointer}.single-download .edd_download_purchase_form{margin-bottom:1.387em}.edd_download_purchase_form .edd_download_quantity_wrapper{margin:0 0 .5em}.edd_download_purchase_form .edd_download_quantity_wrapper .edd-item-quantity{width:75px}.edd_download_purchase_form .edd_price_options{margin:0 0 15px}.edd_download_purchase_form .edd_price_options ul{margin:0;padding:0;list-style:none}.edd_download_purchase_form .edd_price_options li{display:block;padding:0;margin:0}.edd_download_purchase_form .edd_price_options span{display:inline;padding:0;margin:0}.edd_download_purchase_form .edd_price_options .edd_download_quantity_wrapper{padding-left:18px}.edd_download_purchase_form .edd_price_options .edd_download_quantity_wrapper *{font-size:80%}.edd_download_purchase_form .edd_price_options input.edd-item-quantity{display:inline;width:50px;max-width:90%}#edd-purchase-button,.edd-submit,input[type=submit].edd-submit{display:inline-block;padding:6px 12px;margin:0;font-size:14px;font-weight:400;line-height:1.428571429;text-align:center;white-space:nowrap;vertical-align:middle;cursor:pointer;border:1px solid #ccc;border-radius:4px;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;-o-user-select:none;user-select:none}.edd-submit.button:focus,input[type=submit].edd-submit:focus{outline:#333 dotted thin;outline:-webkit-focus-ring-color auto 5px;outline-offset:-2px}.edd-submit.button:focus,.edd-submit.button:hover,input[type=submit].edd-submit:focus,input[type=submit].edd-submit:hover{color:#333;text-decoration:none}.edd-submit.button:active{background-image:none;outline:0;-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,.125);box-shadow:inset 0 3px 5px rgba(0,0,0,.125)}.edd-submit.plain{padding:0}.edd-submit.button,.edd-submit.button.gray,.edd-submit.button:visited{color:#333;background:#f0f0f0;border-color:#ccc}.edd-submit.button.gray:active,.edd-submit.button.gray:focus,.edd-submit.button.gray:hover,.edd-submit.button:active,.edd-submit.button:focus,.edd-submit.button:hover{color:#333;background:#ebebeb;border-color:#adadad}.edd-submit.button.gray:active{background-image:none}.edd-submit.button.white{color:#333;background:#fff;border-color:#ccc}.edd-submit.button.white:active,.edd-submit.button.white:focus,.edd-submit.button.white:hover{color:#333;background:#ebebeb;border-color:#adadad}.edd-submit.button.white:active{background-image:none}.edd-submit.button.blue{color:#fff;background:#428bca;border-color:#357ebd}.edd-submit.button.blue.active,.edd-submit.button.blue:focus,.edd-submit.button.blue:hover{color:#fff;background:#3276b1;border-color:#285e8e}.edd-submit.button.blue.active{background-image:none}.edd-submit.button.red{color:#fff;background:#d9534f;border-color:#d43f3a}.edd-submit.button.red:active,.edd-submit.button.red:focus,.edd-submit.button.red:hover{color:#fff;background:#d2322d;border-color:#ac2925}.edd-submit.button.red:active{background-image:none}.edd-submit.button.green{color:#fff;background:#5cb85c;border-color:#4cae4c}.edd-submit.button.green:active,.edd-submit.button.green:focus,.edd-submit.button.green:hover{color:#fff;background:#47a447;border-color:#398439}.edd-submit.button.green:active{background-image:none}.edd-submit.button.yellow{color:#fff;background:#f0ad4e;border-color:#eea236}.edd-submit.button.yellow:active,.edd-submit.button.yellow:focus,.edd-submit.button.yellow:hover{color:#fff;background:#ed9c28;border-color:#d58512}.edd-submit.button.yellow:active{background-image:none}.edd-submit.button.orange{color:#fff;background:#ed9c28;border-color:#e3921e}.edd-submit.button.orange:active,.edd-submit.button.orange:focus,.edd-submit.button.orange:hover{color:#fff;background:#e59016;border-color:#d58512}.edd-submit.button.orange:active{background-image:none}.edd-submit.button.dark-gray{color:#fff;background:#363636;border-color:#222}.edd-submit.button.dark-gray:active,.edd-submit.button.dark-gray:focus,.edd-submit.button.dark-gray:hover{color:#fff;background:#333;border-color:#adadad}.edd-submit.button.dark-gray:active{background-image:none}.edd_download{float:left}.edd_download_columns_1 .edd_download{width:100%}.edd_download_columns_2 .edd_download{width:50%}.edd_download_columns_0 .edd_download,.edd_download_columns_3 .edd_download{width:33%}.edd_download_columns_4 .edd_download{width:25%}.edd_download_columns_5 .edd_download{width:20%}.edd_download_columns_6 .edd_download{width:16.6%}.edd_download_inner{padding:0 8px 8px;margin:0 0 10px}.edd_download_image{max-width:100%}.edd_download .edd_price{margin-bottom:10px}.edd-cart-ajax{margin:0 8px 0 4px;top:2px;background:0 0;border:none;padding:0}.edd-cart-number-of-items{font-style:italic;color:grey}.edd-cart-meta.edd_subtotal{font-weight:700;font-style:italic}.edd-cart-meta.edd_cart_tax{font-size:1em;font-style:italic}.edd-cart-meta.edd_cart_tax::before{font-style:normal}.edd-cart-meta.edd_total{font-weight:700}.edd-cart-meta{padding:2px 5px}.edd-cart-meta.edd_subtotal,.edd-cart-meta.edd_total{background-color:#f9f9f9}.edd_errors:not(.edd-alert){-webkit-border-radius:2px;-moz-border-radius:2px;border-radius:2px;border:1px solid #E6DB55;margin:0 0 21px;background:#FFFFE0;color:#333}.edd_error{padding:10px}p.edd_error{margin:0!important}.edd_success:not(.edd-alert){-webkit-border-radius:2px;-moz-border-radius:2px;border-radius:2px;border:1px solid #b3ce89;margin:20px 0;background:#d5eab3;color:#567622;padding:6px 8px;box-shadow:inset 0 1px 0 rgba(255,255,255,.7)}.edd-alert{-webkit-border-radius:2px;-moz-border-radius:2px;border-radius:2px;margin-bottom:20px;padding:10px;border:1px solid transparent;vertical-align:middle}.edd-alert p{padding:0}.edd-alert p:not(:last-child){margin-bottom:5px}.edd-alert p:last-child{margin-bottom:0}.edd-alert-error{color:#a94442;background-color:#f2dede;border-color:#ebccd1}.edd-alert-success{background-color:#dff0d8;border-color:#d6e9c6;color:#3c763d}.edd-alert-info{color:#31708f;background-color:#d9edf7;border-color:#bce8f1}.edd-alert-warn{color:#8a6d3b;background-color:#fcf8e3;border-color:#faebcc}
|
templates/history-downloads.php
CHANGED
@@ -10,7 +10,7 @@ endif;
|
|
10 |
$purchases = edd_get_users_purchases( get_current_user_id(), 20, true, 'any' );
|
11 |
if ( $purchases ) :
|
12 |
do_action( 'edd_before_download_history' ); ?>
|
13 |
-
<table id="edd_user_history">
|
14 |
<thead>
|
15 |
<tr class="edd_download_history_row">
|
16 |
<?php do_action( 'edd_download_history_header_start' ); ?>
|
10 |
$purchases = edd_get_users_purchases( get_current_user_id(), 20, true, 'any' );
|
11 |
if ( $purchases ) :
|
12 |
do_action( 'edd_before_download_history' ); ?>
|
13 |
+
<table id="edd_user_history" class="edd-table">
|
14 |
<thead>
|
15 |
<tr class="edd_download_history_row">
|
16 |
<?php do_action( 'edd_download_history_header_start' ); ?>
|
templates/history-purchases.php
CHANGED
@@ -11,7 +11,7 @@ if ( is_user_logged_in() ):
|
|
11 |
$purchases = edd_get_users_purchases( get_current_user_id(), 20, true, 'any' );
|
12 |
if ( $purchases ) :
|
13 |
do_action( 'edd_before_purchase_history' ); ?>
|
14 |
-
<table id="edd_user_history">
|
15 |
<thead>
|
16 |
<tr class="edd_purchase_row">
|
17 |
<?php do_action('edd_purchase_history_header_before'); ?>
|
11 |
$purchases = edd_get_users_purchases( get_current_user_id(), 20, true, 'any' );
|
12 |
if ( $purchases ) :
|
13 |
do_action( 'edd_before_purchase_history' ); ?>
|
14 |
+
<table id="edd_user_history" class="edd-table">
|
15 |
<thead>
|
16 |
<tr class="edd_purchase_row">
|
17 |
<?php do_action('edd_purchase_history_header_before'); ?>
|
templates/shortcode-content-excerpt.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<?php $excerpt_length = apply_filters( 'excerpt_length', 30 ); ?>
|
2 |
-
|
3 |
<?php if ( has_excerpt() ) : ?>
|
4 |
-
<div
|
5 |
<?php echo apply_filters( 'edd_downloads_excerpt', wp_trim_words( get_post_field( 'post_excerpt', get_the_ID() ), $excerpt_length ) ); ?>
|
6 |
</div>
|
7 |
<?php elseif ( get_the_content() ) : ?>
|
8 |
-
<div
|
9 |
<?php echo apply_filters( 'edd_downloads_excerpt', wp_trim_words( get_post_field( 'post_content', get_the_ID() ), $excerpt_length ) ); ?>
|
10 |
</div>
|
11 |
-
<?php endif; ?>
|
1 |
<?php $excerpt_length = apply_filters( 'excerpt_length', 30 ); ?>
|
2 |
+
<?php $item_prop = edd_add_schema_microdata() ? ' itemprop="description"' : ''; ?>
|
3 |
<?php if ( has_excerpt() ) : ?>
|
4 |
+
<div<?php echo $item_prop; ?> class="edd_download_excerpt">
|
5 |
<?php echo apply_filters( 'edd_downloads_excerpt', wp_trim_words( get_post_field( 'post_excerpt', get_the_ID() ), $excerpt_length ) ); ?>
|
6 |
</div>
|
7 |
<?php elseif ( get_the_content() ) : ?>
|
8 |
+
<div<?php echo $item_prop; ?> class="edd_download_excerpt">
|
9 |
<?php echo apply_filters( 'edd_downloads_excerpt', wp_trim_words( get_post_field( 'post_content', get_the_ID() ), $excerpt_length ) ); ?>
|
10 |
</div>
|
11 |
+
<?php endif; ?>
|
templates/shortcode-content-full.php
CHANGED
@@ -1,3 +1,4 @@
|
|
1 |
-
|
|
|
2 |
<?php echo apply_filters( 'edd_downloads_content', get_post_field( 'post_content', get_the_ID() ) ); ?>
|
3 |
-
</div>
|
1 |
+
<?php $item_prop = edd_add_schema_microdata() ? ' itemprop="description"' : ''; ?>
|
2 |
+
<div<?php echo $item_prop; ?> class="edd_download_full_content">
|
3 |
<?php echo apply_filters( 'edd_downloads_content', get_post_field( 'post_content', get_the_ID() ) ); ?>
|
4 |
+
</div>
|
templates/shortcode-content-image.php
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?php if ( function_exists( 'has_post_thumbnail' ) && has_post_thumbnail( get_the_ID() ) ) : ?>
|
2 |
<div class="edd_download_image">
|
3 |
-
<a href="<?php the_permalink(); ?>"
|
4 |
<?php echo get_the_post_thumbnail( get_the_ID(), 'thumbnail' ); ?>
|
5 |
</a>
|
6 |
</div>
|
7 |
-
<?php endif; ?>
|
1 |
<?php if ( function_exists( 'has_post_thumbnail' ) && has_post_thumbnail( get_the_ID() ) ) : ?>
|
2 |
<div class="edd_download_image">
|
3 |
+
<a href="<?php the_permalink(); ?>">
|
4 |
<?php echo get_the_post_thumbnail( get_the_ID(), 'thumbnail' ); ?>
|
5 |
</a>
|
6 |
</div>
|
7 |
+
<?php endif; ?>
|
templates/shortcode-content-price.php
CHANGED
@@ -1,7 +1,8 @@
|
|
1 |
<?php if ( ! edd_has_variable_prices( get_the_ID() ) ) : ?>
|
2 |
-
|
|
|
3 |
<div itemprop="price" class="edd_price">
|
4 |
<?php edd_price( get_the_ID() ); ?>
|
5 |
</div>
|
6 |
</div>
|
7 |
-
<?php endif; ?>
|
1 |
<?php if ( ! edd_has_variable_prices( get_the_ID() ) ) : ?>
|
2 |
+
<?php $item_props = edd_add_schema_microdata() ? ' itemprop="offers" itemscope itemtype="http://schema.org/Offer"' : ''; ?>
|
3 |
+
<div<?php echo $item_props; ?>>
|
4 |
<div itemprop="price" class="edd_price">
|
5 |
<?php edd_price( get_the_ID() ); ?>
|
6 |
</div>
|
7 |
</div>
|
8 |
+
<?php endif; ?>
|
templates/shortcode-content-title.php
CHANGED
@@ -1,3 +1,4 @@
|
|
1 |
-
|
2 |
-
|
3 |
-
|
|
1 |
+
<?php $item_prop = edd_add_schema_microdata() ? ' itemprop="name"' : ''; ?>
|
2 |
+
<h3<?php echo $item_prop; ?> class="edd_download_title">
|
3 |
+
<a itemprop="url" href="<?php the_permalink(); ?>"><?php the_title(); ?></a>
|
4 |
+
</h3>
|
templates/shortcode-login.php
CHANGED
@@ -12,8 +12,8 @@ if ( ! is_user_logged_in() ) :
|
|
12 |
<span><legend><?php _e( 'Log into Your Account', 'easy-digital-downloads' ); ?></legend></span>
|
13 |
<?php do_action( 'edd_login_fields_before' ); ?>
|
14 |
<p>
|
15 |
-
<label for="edd_user_login"><?php _e( 'Username
|
16 |
-
<input name="edd_user_login" id="edd_user_login" class="required edd-input" type="text"
|
17 |
</p>
|
18 |
<p>
|
19 |
<label for="edd_user_pass"><?php _e( 'Password', 'easy-digital-downloads' ); ?></label>
|
@@ -26,7 +26,7 @@ if ( ! is_user_logged_in() ) :
|
|
26 |
<input id="edd_login_submit" type="submit" class="edd_submit" value="<?php _e( 'Log In', 'easy-digital-downloads' ); ?>"/>
|
27 |
</p>
|
28 |
<p class="edd-lost-password">
|
29 |
-
<a href="<?php echo wp_lostpassword_url(); ?>"
|
30 |
<?php _e( 'Lost Password?', 'easy-digital-downloads' ); ?>
|
31 |
</a>
|
32 |
</p>
|
12 |
<span><legend><?php _e( 'Log into Your Account', 'easy-digital-downloads' ); ?></legend></span>
|
13 |
<?php do_action( 'edd_login_fields_before' ); ?>
|
14 |
<p>
|
15 |
+
<label for="edd_user_login"><?php _e( 'Username', 'easy-digital-downloads' ); ?></label>
|
16 |
+
<input name="edd_user_login" id="edd_user_login" class="required edd-input" type="text"/>
|
17 |
</p>
|
18 |
<p>
|
19 |
<label for="edd_user_pass"><?php _e( 'Password', 'easy-digital-downloads' ); ?></label>
|
26 |
<input id="edd_login_submit" type="submit" class="edd_submit" value="<?php _e( 'Log In', 'easy-digital-downloads' ); ?>"/>
|
27 |
</p>
|
28 |
<p class="edd-lost-password">
|
29 |
+
<a href="<?php echo wp_lostpassword_url(); ?>">
|
30 |
<?php _e( 'Lost Password?', 'easy-digital-downloads' ); ?>
|
31 |
</a>
|
32 |
</p>
|
templates/shortcode-profile-editor.php
CHANGED
@@ -10,6 +10,8 @@ if ( is_user_logged_in() ):
|
|
10 |
$last_name = get_user_meta( $user_id, 'last_name', true );
|
11 |
$display_name = $current_user->display_name;
|
12 |
$address = edd_get_customer_address( $user_id );
|
|
|
|
|
13 |
|
14 |
if ( edd_is_cart_saved() ): ?>
|
15 |
<?php $restore_url = add_query_arg( array( 'edd_action' => 'restore_cart', 'edd_cart_token' => edd_get_cart_token() ), edd_get_checkout_uri() ); ?>
|
@@ -53,11 +55,72 @@ if ( is_user_logged_in() ):
|
|
53 |
</p>
|
54 |
<?php do_action( 'edd_profile_editor_after_name' ); ?>
|
55 |
<p>
|
56 |
-
<label for="edd_email"><?php _e( 'Email Address', 'easy-digital-downloads' ); ?></label>
|
57 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
58 |
<?php do_action( 'edd_profile_editor_email' ); ?>
|
|
|
59 |
</p>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
60 |
<?php do_action( 'edd_profile_editor_after_email' ); ?>
|
|
|
61 |
<span id="edd_profile_billing_address_label"><legend><?php _e( 'Change your Billing Address', 'easy-digital-downloads' ); ?></legend></span>
|
62 |
<p id="edd_profile_billing_address_wrap">
|
63 |
<label for="edd_address_line1"><?php _e( 'Line 1', 'easy-digital-downloads' ); ?></label>
|
@@ -79,8 +142,19 @@ if ( is_user_logged_in() ):
|
|
79 |
<?php endforeach; ?>
|
80 |
</select>
|
81 |
<br/>
|
82 |
-
<label for="edd_address_state"><?php _e( 'State / Province', '
|
83 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
84 |
<br/>
|
85 |
<?php do_action( 'edd_profile_editor_address' ); ?>
|
86 |
</p>
|
@@ -94,7 +168,6 @@ if ( is_user_logged_in() ):
|
|
94 |
<input name="edd_new_user_pass2" id="edd_new_user_pass2" class="password edd-input" type="password"/>
|
95 |
<?php do_action( 'edd_profile_editor_password' ); ?>
|
96 |
</p>
|
97 |
-
<p class="edd_password_change_notice"><?php _e( 'Please note after changing your password, you must log back in.', 'easy-digital-downloads' ); ?></p>
|
98 |
<?php do_action( 'edd_profile_editor_after_password' ); ?>
|
99 |
<p id="edd_profile_submit_wrap">
|
100 |
<input type="hidden" name="edd_profile_editor_nonce" value="<?php echo wp_create_nonce( 'edd-profile-editor-nonce' ); ?>"/>
|
10 |
$last_name = get_user_meta( $user_id, 'last_name', true );
|
11 |
$display_name = $current_user->display_name;
|
12 |
$address = edd_get_customer_address( $user_id );
|
13 |
+
$states = edd_get_shop_states( $address['country'] );
|
14 |
+
$state = ( ! empty( $address['state'] ) ) ? $address['state'] : '';
|
15 |
|
16 |
if ( edd_is_cart_saved() ): ?>
|
17 |
<?php $restore_url = add_query_arg( array( 'edd_action' => 'restore_cart', 'edd_cart_token' => edd_get_cart_token() ), edd_get_checkout_uri() ); ?>
|
55 |
</p>
|
56 |
<?php do_action( 'edd_profile_editor_after_name' ); ?>
|
57 |
<p>
|
58 |
+
<label for="edd_email"><?php _e( 'Primary Email Address', 'easy-digital-downloads' ); ?></label>
|
59 |
+
<?php $customer = new EDD_Customer( $user_id, true ); ?>
|
60 |
+
<?php if ( $customer->id > 0 ) : ?>
|
61 |
+
|
62 |
+
<?php if ( 1 === count( $customer->emails ) ) : ?>
|
63 |
+
<input name="edd_email" id="edd_email" class="text edd-input required" type="email" value="<?php echo esc_attr( $customer->email ); ?>" />
|
64 |
+
<?php else: ?>
|
65 |
+
<?php
|
66 |
+
$emails = array();
|
67 |
+
$customer->emails = array_reverse( $customer->emails, true );
|
68 |
+
|
69 |
+
foreach ( $customer->emails as $email ) {
|
70 |
+
$emails[ $email ] = $email;
|
71 |
+
}
|
72 |
+
|
73 |
+
$email_select_args = array(
|
74 |
+
'options' => $emails,
|
75 |
+
'name' => 'edd_email',
|
76 |
+
'id' => 'edd_email',
|
77 |
+
'selected' => $customer->email,
|
78 |
+
'show_option_none' => false,
|
79 |
+
'show_option_all' => false,
|
80 |
+
);
|
81 |
+
|
82 |
+
echo EDD()->html->select( $email_select_args );
|
83 |
+
?>
|
84 |
+
<?php endif; ?>
|
85 |
+
<?php else: ?>
|
86 |
+
<input name="edd_email" id="edd_email" class="text edd-input required" type="email" value="<?php echo esc_attr( $current_user->user_email ); ?>" />
|
87 |
+
<?php endif; ?>
|
88 |
+
|
89 |
<?php do_action( 'edd_profile_editor_email' ); ?>
|
90 |
+
|
91 |
</p>
|
92 |
+
|
93 |
+
<?php if ( $customer->id > 0 && count( $customer->emails ) > 1 ) : ?>
|
94 |
+
<div>
|
95 |
+
<label for="edd_emails"><?php _e( 'Additional Email Addresses', 'easy-digital-downloads' ); ?></label>
|
96 |
+
<ul class="edd-profile-emails">
|
97 |
+
<?php foreach ( $customer->emails as $email ) : ?>
|
98 |
+
<?php if ( $email === $customer->email ) { continue; } ?>
|
99 |
+
<li class="edd-profile-email">
|
100 |
+
<?php echo $email; ?>
|
101 |
+
<span class="actions">
|
102 |
+
<?php
|
103 |
+
$remove_url = wp_nonce_url(
|
104 |
+
add_query_arg(
|
105 |
+
array(
|
106 |
+
'email' => $email,
|
107 |
+
'edd_action' => 'profile-remove-email',
|
108 |
+
'redirect' => esc_url( edd_get_current_page_url() ),
|
109 |
+
)
|
110 |
+
),
|
111 |
+
'edd-remove-customer-email'
|
112 |
+
);
|
113 |
+
?>
|
114 |
+
<a href="<?php echo $remove_url ?>" class="delete"><?php _e( 'Remove', 'easy-digital-downloads' ); ?></a>
|
115 |
+
</span>
|
116 |
+
</li>
|
117 |
+
<?php endforeach; ?>
|
118 |
+
</ul>
|
119 |
+
</div>
|
120 |
+
<?php endif; ?>
|
121 |
+
|
122 |
<?php do_action( 'edd_profile_editor_after_email' ); ?>
|
123 |
+
|
124 |
<span id="edd_profile_billing_address_label"><legend><?php _e( 'Change your Billing Address', 'easy-digital-downloads' ); ?></legend></span>
|
125 |
<p id="edd_profile_billing_address_wrap">
|
126 |
<label for="edd_address_line1"><?php _e( 'Line 1', 'easy-digital-downloads' ); ?></label>
|
142 |
<?php endforeach; ?>
|
143 |
</select>
|
144 |
<br/>
|
145 |
+
<label for="edd_address_state"><?php _e( 'State / Province', 'edd' ); ?></label>
|
146 |
+
<?php
|
147 |
+
if( ! empty( $states ) ) : ?>
|
148 |
+
<select name="edd_address_state" id="edd_address_state" class="select edd-select">
|
149 |
+
<?php
|
150 |
+
foreach( $states as $state_code => $state_name ) {
|
151 |
+
echo '<option value="' . $state_code . '"' . selected( $state_code, $state, false ) . '>' . $state_name . '</option>';
|
152 |
+
}
|
153 |
+
?>
|
154 |
+
</select>
|
155 |
+
<?php else : ?>
|
156 |
+
<input name="edd_address_state" id="edd_address_state" class="text edd-input" type="text" value="<?php echo esc_attr( $state ); ?>" />
|
157 |
+
<?php endif; ?>
|
158 |
<br/>
|
159 |
<?php do_action( 'edd_profile_editor_address' ); ?>
|
160 |
</p>
|
168 |
<input name="edd_new_user_pass2" id="edd_new_user_pass2" class="password edd-input" type="password"/>
|
169 |
<?php do_action( 'edd_profile_editor_password' ); ?>
|
170 |
</p>
|
|
|
171 |
<?php do_action( 'edd_profile_editor_after_password' ); ?>
|
172 |
<p id="edd_profile_submit_wrap">
|
173 |
<input type="hidden" name="edd_profile_editor_nonce" value="<?php echo wp_create_nonce( 'edd-profile-editor-nonce' ); ?>"/>
|
templates/shortcode-receipt.php
CHANGED
@@ -22,7 +22,7 @@ $user = edd_get_payment_meta_user_info( $payment->ID );
|
|
22 |
$email = edd_get_payment_user_email( $payment->ID );
|
23 |
$status = edd_get_payment_status( $payment, true );
|
24 |
?>
|
25 |
-
<table id="edd_purchase_receipt">
|
26 |
<thead>
|
27 |
<?php do_action( 'edd_payment_receipt_before', $payment, $edd_receipt_args ); ?>
|
28 |
|
@@ -118,7 +118,7 @@ $status = edd_get_payment_status( $payment, true );
|
|
118 |
|
119 |
<h3><?php echo apply_filters( 'edd_payment_receipt_products_title', __( 'Products', 'easy-digital-downloads' ) ); ?></h3>
|
120 |
|
121 |
-
<table id="edd_purchase_receipt_products">
|
122 |
<thead>
|
123 |
<th><?php _e( 'Name', 'easy-digital-downloads' ); ?></th>
|
124 |
<?php if ( edd_use_skus() ) { ?>
|
22 |
$email = edd_get_payment_user_email( $payment->ID );
|
23 |
$status = edd_get_payment_status( $payment, true );
|
24 |
?>
|
25 |
+
<table id="edd_purchase_receipt" class="edd-table">
|
26 |
<thead>
|
27 |
<?php do_action( 'edd_payment_receipt_before', $payment, $edd_receipt_args ); ?>
|
28 |
|
118 |
|
119 |
<h3><?php echo apply_filters( 'edd_payment_receipt_products_title', __( 'Products', 'easy-digital-downloads' ) ); ?></h3>
|
120 |
|
121 |
+
<table id="edd_purchase_receipt_products" class="edd-table">
|
122 |
<thead>
|
123 |
<th><?php _e( 'Name', 'easy-digital-downloads' ); ?></th>
|
124 |
<?php if ( edd_use_skus() ) { ?>
|
templates/shortcode-register.php
CHANGED
@@ -16,12 +16,12 @@ edd_print_errors(); ?>
|
|
16 |
|
17 |
<p>
|
18 |
<label for="edd-user-login"><?php _e( 'Username', 'easy-digital-downloads' ); ?></label>
|
19 |
-
<input id="edd-user-login" class="required edd-input" type="text" name="edd_user_login"
|
20 |
</p>
|
21 |
|
22 |
<p>
|
23 |
<label for="edd-user-email"><?php _e( 'Email', 'easy-digital-downloads' ); ?></label>
|
24 |
-
<input id="edd-user-email" class="required edd-input" type="email" name="edd_user_email"
|
25 |
</p>
|
26 |
|
27 |
<p>
|
16 |
|
17 |
<p>
|
18 |
<label for="edd-user-login"><?php _e( 'Username', 'easy-digital-downloads' ); ?></label>
|
19 |
+
<input id="edd-user-login" class="required edd-input" type="text" name="edd_user_login" />
|
20 |
</p>
|
21 |
|
22 |
<p>
|
23 |
<label for="edd-user-email"><?php _e( 'Email', 'easy-digital-downloads' ); ?></label>
|
24 |
+
<input id="edd-user-email" class="required edd-input" type="email" name="edd_user_email" />
|
25 |
</p>
|
26 |
|
27 |
<p>
|
uninstall.php
CHANGED
@@ -85,6 +85,7 @@ if( edd_get_option( 'uninstall_on_delete' ) ) {
|
|
85 |
|
86 |
// Remove all database tables
|
87 |
$wpdb->query( "DROP TABLE IF EXISTS " . $wpdb->prefix . "edd_customers" );
|
|
|
88 |
|
89 |
/** Cleanup Cron Events */
|
90 |
wp_clear_scheduled_hook( 'edd_daily_scheduled_events' );
|
@@ -92,6 +93,6 @@ if( edd_get_option( 'uninstall_on_delete' ) ) {
|
|
92 |
wp_clear_scheduled_hook( 'edd_weekly_cron' );
|
93 |
|
94 |
// Remove any transients we've left behind
|
95 |
-
$wpdb->query( "DELETE FROM $wpdb->options WHERE option_name LIKE '
|
96 |
-
$wpdb->query( "DELETE FROM $wpdb->options WHERE option_name LIKE '
|
97 |
}
|
85 |
|
86 |
// Remove all database tables
|
87 |
$wpdb->query( "DROP TABLE IF EXISTS " . $wpdb->prefix . "edd_customers" );
|
88 |
+
$wpdb->query( "DROP TABLE IF EXISTS " . $wpdb->prefix . "edd_customermeta" );
|
89 |
|
90 |
/** Cleanup Cron Events */
|
91 |
wp_clear_scheduled_hook( 'edd_daily_scheduled_events' );
|
93 |
wp_clear_scheduled_hook( 'edd_weekly_cron' );
|
94 |
|
95 |
// Remove any transients we've left behind
|
96 |
+
$wpdb->query( "DELETE FROM $wpdb->options WHERE option_name LIKE '\_transient\_edd\_%'" );
|
97 |
+
$wpdb->query( "DELETE FROM $wpdb->options WHERE option_name LIKE '\_transient\_timeout\_edd\_%'" );
|
98 |
}
|