Give – Donation Plugin and Fundraising Platform - Version 1.8.4

Version Description

  • Fix: When a donation form has guest donations enabled and the registration + login option enabled the optional fields were being incorrect required. #1553
  • Fix: Minor RTL style issue with the i18n banner that displays asking help translating Give when WP-Admin is in a non-supported language. #1547
  • Fix: Updated the included add-on software licensing class and fixed active license placeholders. #1556
Download this release

Release Info

Developer dlocc
Plugin Icon 128x128 Give – Donation Plugin and Fundraising Platform
Version 1.8.4
Comparing to
See all releases

Code changes from version 1.8.3 to 1.8.4

give.php CHANGED
@@ -5,7 +5,7 @@
5
  * Description: The most robust, flexible, and intuitive way to accept donations on WordPress.
6
  * Author: WordImpress
7
  * Author URI: https://wordimpress.com
8
- * Version: 1.8.3
9
  * Text Domain: give
10
  * Domain Path: /languages
11
  * GitHub Plugin URI: https://github.com/WordImpress/Give
@@ -260,7 +260,7 @@ if ( ! class_exists( 'Give' ) ) :
260
 
261
  // Plugin version
262
  if ( ! defined( 'GIVE_VERSION' ) ) {
263
- define( 'GIVE_VERSION', '1.8.3' );
264
  }
265
 
266
  // Plugin Folder Path
5
  * Description: The most robust, flexible, and intuitive way to accept donations on WordPress.
6
  * Author: WordImpress
7
  * Author URI: https://wordimpress.com
8
+ * Version: 1.8.4
9
  * Text Domain: give
10
  * Domain Path: /languages
11
  * GitHub Plugin URI: https://github.com/WordImpress/Give
260
 
261
  // Plugin version
262
  if ( ! defined( 'GIVE_VERSION' ) ) {
263
+ define( 'GIVE_VERSION', '1.8.4' );
264
  }
265
 
266
  // Plugin Folder Path
includes/admin/EDD_SL_Plugin_Updater.php CHANGED
@@ -1,54 +1,69 @@
1
  <?php
2
 
3
- // uncomment this line for testing
4
- // set_site_transient( 'update_plugins', null );
5
- // Exit if accessed directly.
6
- if ( ! defined( 'ABSPATH' ) ) {
7
- exit;
8
- }
9
 
10
  /**
11
  * Allows plugins to use their own update API.
12
  *
13
- * @author Pippin Williamson
14
- * @version 1.6
15
  */
16
  class EDD_SL_Plugin_Updater {
17
- private $api_url = '';
18
- private $api_data = array();
19
- private $name = '';
20
- private $slug = '';
 
 
 
 
21
 
22
  /**
23
  * Class constructor.
24
  *
25
- * @param string $_api_url The URL pointing to the custom API endpoint.
26
- * @param string $_plugin_file Path to the plugin file.
27
- * @param array $_api_data Optional data to send with API calls.
 
 
 
28
  */
29
- function __construct( $_api_url, $_plugin_file, $_api_data = null ) {
30
- $this->api_url = trailingslashit( $_api_url );
31
- $this->api_data = $_api_data;
32
- $this->name = plugin_basename( $_plugin_file );
33
- $this->slug = basename( $_plugin_file, '.php' );
34
- $this->version = $_api_data['version'];
 
 
 
 
 
 
 
 
35
 
36
  // Set up hooks.
37
  $this->init();
38
- add_action( 'admin_init', array( $this, 'show_changelog' ) );
39
  }
40
 
41
  /**
42
  * Set up WordPress filters to hook into WP's update process.
43
  *
 
 
44
  * @return void
45
  */
46
  public function init() {
47
 
48
  add_filter( 'pre_set_site_transient_update_plugins', array( $this, 'check_update' ) );
49
  add_filter( 'plugins_api', array( $this, 'plugins_api_filter' ), 10, 3 );
50
-
51
  add_action( 'after_plugin_row_' . $this->name, array( $this, 'show_update_notification' ), 10, 2 );
 
 
52
  }
53
 
54
  /**
@@ -61,40 +76,45 @@ class EDD_SL_Plugin_Updater {
61
  *
62
  * @uses api_request()
63
  *
64
- * @param array $_transient_data Update array build by WordPress.
65
- *
66
- * @return stdClass Modified update array with custom plugin data
67
  */
68
- function check_update( $_transient_data ) {
69
 
70
- $screen = get_current_screen();
71
 
72
  if ( ! is_object( $_transient_data ) ) {
73
  $_transient_data = new stdClass;
74
  }
75
 
76
- if ( is_object( $screen ) && 'plugins.php' == $screen->parent_file && is_multisite() ) {
77
  return $_transient_data;
78
  }
79
 
80
- if ( empty( $_transient_data->response ) || empty( $_transient_data->response[ $this->name ] ) ) {
 
 
81
 
82
- $version_info = $this->api_request( 'plugin_latest_version', array( 'slug' => $this->slug ) );
83
 
84
- if ( false !== $version_info && is_object( $version_info ) && isset( $version_info->new_version ) ) {
 
85
 
86
- $this->did_check = true;
87
 
88
- if ( version_compare( $this->version, $version_info->new_version, '<' ) ) {
89
 
90
- $_transient_data->response[ $this->name ] = $version_info;
91
 
92
- }
93
 
94
- $_transient_data->last_checked = time();
95
- $_transient_data->checked[ $this->name ] = $this->version;
96
 
97
  }
 
 
 
 
98
  }
99
 
100
  return $_transient_data;
@@ -103,16 +123,20 @@ class EDD_SL_Plugin_Updater {
103
  /**
104
  * show update nofication row -- needed for multisite subsites, because WP won't tell you otherwise!
105
  *
106
- * @param string $file
107
- * @param array $plugin
108
  */
109
  public function show_update_notification( $file, $plugin ) {
110
 
111
- if ( ! current_user_can( 'update_plugins' ) ) {
112
  return;
113
  }
114
 
115
- if ( ! is_multisite() ) {
 
 
 
 
116
  return;
117
  }
118
 
@@ -125,16 +149,16 @@ class EDD_SL_Plugin_Updater {
125
 
126
  $update_cache = get_site_transient( 'update_plugins' );
127
 
128
- if ( ! is_object( $update_cache ) || empty( $update_cache->response ) || empty( $update_cache->response[ $this->name ] ) ) {
129
 
130
- $cache_key = md5( 'edd_plugin_' . sanitize_key( $this->name ) . '_version_info' );
131
- $version_info = get_transient( $cache_key );
132
 
133
- if ( false === $version_info ) {
134
 
135
- $version_info = $this->api_request( 'plugin_latest_version', array( 'slug' => $this->slug ) );
 
136
 
137
- set_transient( $cache_key, $version_info, 3600 );
138
  }
139
 
140
  if ( ! is_object( $version_info ) ) {
@@ -147,7 +171,7 @@ class EDD_SL_Plugin_Updater {
147
 
148
  }
149
 
150
- $update_cache->last_checked = time();
151
  $update_cache->checked[ $this->name ] = $this->version;
152
 
153
  set_site_transient( 'update_plugins', $update_cache );
@@ -165,46 +189,50 @@ class EDD_SL_Plugin_Updater {
165
 
166
  // build a plugin list row, with update notification
167
  $wp_list_table = _get_list_table( 'WP_Plugins_List_Table' );
168
- echo '<tr class="plugin-update-tr"><td colspan="' . $wp_list_table->get_column_count() . '" class="plugin-update colspanchange"><div class="update-message">';
 
 
 
169
 
170
  $changelog_link = self_admin_url( 'index.php?edd_sl_action=view_plugin_changelog&plugin=' . $this->name . '&slug=' . $this->slug . '&TB_iframe=true&width=772&height=911' );
171
 
172
  if ( empty( $version_info->download_link ) ) {
173
  printf(
174
- /* translators: 1: name 2: changelog URL 3: version */
175
- __( 'There is a new version of %1$s available. <a target="_blank" class="thickbox" href="%2$s">View version %3$s details</a>.', 'give' ),
176
  esc_html( $version_info->name ),
177
- esc_url( $changelog_link ),
178
- esc_html( $version_info->new_version )
 
179
  );
180
  } else {
181
  printf(
182
- /* translators: 1: name 2: changelog URL 3: version 4: update URL */
183
- __( 'There is a new version of %1$s available. <a target="_blank" class="thickbox" href="%2$s">View version %3$s details</a> or <a href="%4$s">update now</a>.', 'give' ),
184
  esc_html( $version_info->name ),
185
- esc_url( $changelog_link ),
186
  esc_html( $version_info->new_version ),
187
- esc_url( wp_nonce_url( self_admin_url( 'update.php?action=upgrade-plugin&plugin=' ) . $this->name, 'upgrade-plugin_' . $this->name ) )
 
 
188
  );
189
  }
190
 
 
 
191
  echo '</div></td></tr>';
192
  }
193
  }
194
 
195
-
196
  /**
197
  * Updates information on the "View version x.x details" page with custom data.
198
  *
199
  * @uses api_request()
200
  *
201
- * @param mixed $_data
202
- * @param string $_action
203
- * @param object $_args
204
- *
205
  * @return object $_data
206
  */
207
- function plugins_api_filter( $_data, $_action = '', $_args = null ) {
208
 
209
  if ( $_action != 'plugin_information' ) {
210
 
@@ -222,80 +250,108 @@ class EDD_SL_Plugin_Updater {
222
  'slug' => $this->slug,
223
  'is_ssl' => is_ssl(),
224
  'fields' => array(
225
- 'banners' => false, // These will be supported soon hopefully
226
- 'reviews' => false,
227
- ),
228
  );
229
 
230
- $api_response = $this->api_request( 'plugin_information', $to_send );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
231
 
232
- if ( false !== $api_response ) {
233
- $_data = $api_response;
 
 
 
 
 
 
 
 
 
234
  }
235
 
236
  return $_data;
237
  }
238
 
239
-
240
  /**
241
  * Disable SSL verification in order to prevent download update failures
242
  *
243
- * @param array $args
244
- * @param string $url
245
- *
246
  * @return object $array
247
  */
248
- function http_request_args( $args, $url ) {
249
  // If it is an https request and we are performing a package download, disable ssl verification
250
  if ( strpos( $url, 'https://' ) !== false && strpos( $url, 'edd_action=package_download' ) ) {
251
  $args['sslverify'] = false;
252
  }
253
-
254
  return $args;
255
  }
256
 
257
  /**
258
  * Calls the API and, if successfull, returns the object delivered by the API.
259
  *
260
- * @uses get_bloginfo()
261
- * @uses wp_remote_post()
262
- * @uses is_wp_error()
263
- *
264
- * @param string $_action The requested action.
265
- * @param array $_data Parameters for the API action.
266
  *
267
- * @return false||object
 
 
268
  */
269
  private function api_request( $_action, $_data ) {
270
 
 
 
271
  $data = array_merge( $this->api_data, $_data );
272
 
273
  if ( $data['slug'] != $this->slug ) {
274
  return;
275
  }
276
 
277
- if ( empty( $data['license'] ) ) {
278
- return;
279
- }
280
-
281
- if ( $this->api_url == home_url() ) {
282
  return false; // Don't allow a plugin to ping itself
283
  }
284
 
285
  $api_params = array(
286
  'edd_action' => 'get_version',
287
- 'license' => $data['license'],
288
  'item_name' => isset( $data['item_name'] ) ? $data['item_name'] : false,
289
  'item_id' => isset( $data['item_id'] ) ? $data['item_id'] : false,
 
290
  'slug' => $data['slug'],
291
  'author' => $data['author'],
292
  'url' => home_url(),
 
293
  );
294
 
295
- $request = wp_remote_post( $this->api_url, array( 'timeout' => 15,
296
- 'sslverify' => false,
297
- 'body' => $api_params,
298
- ) );
299
 
300
  if ( ! is_wp_error( $request ) ) {
301
  $request = json_decode( wp_remote_retrieve_body( $request ) );
@@ -307,34 +363,115 @@ class EDD_SL_Plugin_Updater {
307
  $request = false;
308
  }
309
 
 
 
 
 
 
 
 
 
 
 
310
  return $request;
311
  }
312
 
313
  public function show_changelog() {
314
 
315
- if ( empty( $_REQUEST['edd_sl_action'] ) || 'view_plugin_changelog' != $_REQUEST['edd_sl_action'] ) {
 
 
316
  return;
317
  }
318
 
319
- if ( empty( $_REQUEST['plugin'] ) ) {
320
  return;
321
  }
322
 
323
- if ( empty( $_REQUEST['slug'] ) ) {
324
  return;
325
  }
326
 
327
- if ( ! current_user_can( 'update_plugins' ) ) {
328
- wp_die( esc_html__( 'You do not have permission to install plugin updates.', 'give' ), esc_html__( 'Error', 'give' ), array( 'response' => 403 ) );
329
  }
330
 
331
- $response = $this->api_request( 'plugin_latest_version', array( 'slug' => $_REQUEST['slug'] ) );
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
332
 
333
- if ( $response && isset( $response->sections['changelog'] ) ) {
334
- echo '<div style="background:#fff;padding:10px;">' . $response->sections['changelog'] . '</div>';
 
 
335
  }
336
 
337
  exit;
338
  }
339
 
340
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  <?php
2
 
3
+ // Exit if accessed directly
4
+ if ( ! defined( 'ABSPATH' ) ) exit;
 
 
 
 
5
 
6
  /**
7
  * Allows plugins to use their own update API.
8
  *
9
+ * @author Easy Digital Downloads
10
+ * @version 1.6.11
11
  */
12
  class EDD_SL_Plugin_Updater {
13
+
14
+ private $api_url = '';
15
+ private $api_data = array();
16
+ private $name = '';
17
+ private $slug = '';
18
+ private $version = '';
19
+ private $wp_override = false;
20
+ private $cache_key = '';
21
 
22
  /**
23
  * Class constructor.
24
  *
25
+ * @uses plugin_basename()
26
+ * @uses hook()
27
+ *
28
+ * @param string $_api_url The URL pointing to the custom API endpoint.
29
+ * @param string $_plugin_file Path to the plugin file.
30
+ * @param array $_api_data Optional data to send with API calls.
31
  */
32
+ public function __construct( $_api_url, $_plugin_file, $_api_data = null ) {
33
+
34
+ global $edd_plugin_data;
35
+
36
+ $this->api_url = trailingslashit( $_api_url );
37
+ $this->api_data = $_api_data;
38
+ $this->name = plugin_basename( $_plugin_file );
39
+ $this->slug = basename( $_plugin_file, '.php' );
40
+ $this->version = $_api_data['version'];
41
+ $this->wp_override = isset( $_api_data['wp_override'] ) ? (bool) $_api_data['wp_override'] : false;
42
+ $this->beta = ! empty( $this->api_data['beta'] ) ? true : false;
43
+ $this->cache_key = md5( serialize( $this->slug . $this->api_data['license'] . $this->beta ) );
44
+
45
+ $edd_plugin_data[ $this->slug ] = $this->api_data;
46
 
47
  // Set up hooks.
48
  $this->init();
49
+
50
  }
51
 
52
  /**
53
  * Set up WordPress filters to hook into WP's update process.
54
  *
55
+ * @uses add_filter()
56
+ *
57
  * @return void
58
  */
59
  public function init() {
60
 
61
  add_filter( 'pre_set_site_transient_update_plugins', array( $this, 'check_update' ) );
62
  add_filter( 'plugins_api', array( $this, 'plugins_api_filter' ), 10, 3 );
63
+ remove_action( 'after_plugin_row_' . $this->name, 'wp_plugin_update_row', 10 );
64
  add_action( 'after_plugin_row_' . $this->name, array( $this, 'show_update_notification' ), 10, 2 );
65
+ add_action( 'admin_init', array( $this, 'show_changelog' ) );
66
+
67
  }
68
 
69
  /**
76
  *
77
  * @uses api_request()
78
  *
79
+ * @param array $_transient_data Update array build by WordPress.
80
+ * @return array Modified update array with custom plugin data.
 
81
  */
82
+ public function check_update( $_transient_data ) {
83
 
84
+ global $pagenow;
85
 
86
  if ( ! is_object( $_transient_data ) ) {
87
  $_transient_data = new stdClass;
88
  }
89
 
90
+ if ( 'plugins.php' == $pagenow && is_multisite() ) {
91
  return $_transient_data;
92
  }
93
 
94
+ if ( ! empty( $_transient_data->response ) && ! empty( $_transient_data->response[ $this->name ] ) && false === $this->wp_override ) {
95
+ return $_transient_data;
96
+ }
97
 
98
+ $version_info = $this->get_cached_version_info();
99
 
100
+ if ( false === $version_info ) {
101
+ $version_info = $this->api_request( 'plugin_latest_version', array( 'slug' => $this->slug, 'beta' => $this->beta ) );
102
 
103
+ $this->set_version_info_cache( $version_info );
104
 
105
+ }
106
 
107
+ if ( false !== $version_info && is_object( $version_info ) && isset( $version_info->new_version ) ) {
108
 
109
+ if ( version_compare( $this->version, $version_info->new_version, '<' ) ) {
110
 
111
+ $_transient_data->response[ $this->name ] = $version_info;
 
112
 
113
  }
114
+
115
+ $_transient_data->last_checked = current_time( 'timestamp' );
116
+ $_transient_data->checked[ $this->name ] = $this->version;
117
+
118
  }
119
 
120
  return $_transient_data;
123
  /**
124
  * show update nofication row -- needed for multisite subsites, because WP won't tell you otherwise!
125
  *
126
+ * @param string $file
127
+ * @param array $plugin
128
  */
129
  public function show_update_notification( $file, $plugin ) {
130
 
131
+ if ( is_network_admin() ) {
132
  return;
133
  }
134
 
135
+ if( ! current_user_can( 'update_plugins' ) ) {
136
+ return;
137
+ }
138
+
139
+ if( ! is_multisite() ) {
140
  return;
141
  }
142
 
149
 
150
  $update_cache = get_site_transient( 'update_plugins' );
151
 
152
+ $update_cache = is_object( $update_cache ) ? $update_cache : new stdClass();
153
 
154
+ if ( empty( $update_cache->response ) || empty( $update_cache->response[ $this->name ] ) ) {
 
155
 
156
+ $version_info = $this->get_cached_version_info();
157
 
158
+ if ( false === $version_info ) {
159
+ $version_info = $this->api_request( 'plugin_latest_version', array( 'slug' => $this->slug, 'beta' => $this->beta ) );
160
 
161
+ $this->set_version_info_cache( $version_info );
162
  }
163
 
164
  if ( ! is_object( $version_info ) ) {
171
 
172
  }
173
 
174
+ $update_cache->last_checked = current_time( 'timestamp' );
175
  $update_cache->checked[ $this->name ] = $this->version;
176
 
177
  set_site_transient( 'update_plugins', $update_cache );
189
 
190
  // build a plugin list row, with update notification
191
  $wp_list_table = _get_list_table( 'WP_Plugins_List_Table' );
192
+ # <tr class="plugin-update-tr"><td colspan="' . $wp_list_table->get_column_count() . '" class="plugin-update colspanchange">
193
+ echo '<tr class="plugin-update-tr" id="' . $this->slug . '-update" data-slug="' . $this->slug . '" data-plugin="' . $this->slug . '/' . $file . '">';
194
+ echo '<td colspan="3" class="plugin-update colspanchange">';
195
+ echo '<div class="update-message notice inline notice-warning notice-alt">';
196
 
197
  $changelog_link = self_admin_url( 'index.php?edd_sl_action=view_plugin_changelog&plugin=' . $this->name . '&slug=' . $this->slug . '&TB_iframe=true&width=772&height=911' );
198
 
199
  if ( empty( $version_info->download_link ) ) {
200
  printf(
201
+ __( 'There is a new version of %1$s available. %2$sView version %3$s details%4$s.', 'easy-digital-downloads' ),
 
202
  esc_html( $version_info->name ),
203
+ '<a target="_blank" class="thickbox" href="' . esc_url( $changelog_link ) . '">',
204
+ esc_html( $version_info->new_version ),
205
+ '</a>'
206
  );
207
  } else {
208
  printf(
209
+ __( 'There is a new version of %1$s available. %2$sView version %3$s details%4$s or %5$supdate now%6$s.', 'easy-digital-downloads' ),
 
210
  esc_html( $version_info->name ),
211
+ '<a target="_blank" class="thickbox" href="' . esc_url( $changelog_link ) . '">',
212
  esc_html( $version_info->new_version ),
213
+ '</a>',
214
+ '<a href="' . esc_url( wp_nonce_url( self_admin_url( 'update.php?action=upgrade-plugin&plugin=' ) . $this->name, 'upgrade-plugin_' . $this->name ) ) .'">',
215
+ '</a>'
216
  );
217
  }
218
 
219
+ do_action( "in_plugin_update_message-{$file}", $plugin, $version_info );
220
+
221
  echo '</div></td></tr>';
222
  }
223
  }
224
 
 
225
  /**
226
  * Updates information on the "View version x.x details" page with custom data.
227
  *
228
  * @uses api_request()
229
  *
230
+ * @param mixed $_data
231
+ * @param string $_action
232
+ * @param object $_args
 
233
  * @return object $_data
234
  */
235
+ public function plugins_api_filter( $_data, $_action = '', $_args = null ) {
236
 
237
  if ( $_action != 'plugin_information' ) {
238
 
250
  'slug' => $this->slug,
251
  'is_ssl' => is_ssl(),
252
  'fields' => array(
253
+ 'banners' => array(),
254
+ 'reviews' => false
255
+ )
256
  );
257
 
258
+ $cache_key = 'edd_api_request_' . md5( serialize( $this->slug . $this->api_data['license'] . $this->beta ) );
259
+
260
+ // Get the transient where we store the api request for this plugin for 24 hours
261
+ $edd_api_request_transient = $this->get_cached_version_info( $cache_key );
262
+
263
+ //If we have no transient-saved value, run the API, set a fresh transient with the API value, and return that value too right now.
264
+ if ( empty( $edd_api_request_transient ) ) {
265
+
266
+ $api_response = $this->api_request( 'plugin_information', $to_send );
267
+
268
+ // Expires in 3 hours
269
+ $this->set_version_info_cache( $api_response, $cache_key );
270
+
271
+ if ( false !== $api_response ) {
272
+ $_data = $api_response;
273
+ }
274
+
275
+ } else {
276
+ $_data = $edd_api_request_transient;
277
+ }
278
+
279
+ // Convert sections into an associative array, since we're getting an object, but Core expects an array.
280
+ if ( isset( $_data->sections ) && ! is_array( $_data->sections ) ) {
281
+ $new_sections = array();
282
+ foreach ( $_data->sections as $key => $key ) {
283
+ $new_sections[ $key ] = $key;
284
+ }
285
 
286
+ $_data->sections = $new_sections;
287
+ }
288
+
289
+ // Convert banners into an associative array, since we're getting an object, but Core expects an array.
290
+ if ( isset( $_data->banners ) && ! is_array( $_data->banners ) ) {
291
+ $new_banners = array();
292
+ foreach ( $_data->banners as $key => $key ) {
293
+ $new_banners[ $key ] = $key;
294
+ }
295
+
296
+ $_data->banners = $new_banners;
297
  }
298
 
299
  return $_data;
300
  }
301
 
 
302
  /**
303
  * Disable SSL verification in order to prevent download update failures
304
  *
305
+ * @param array $args
306
+ * @param string $url
 
307
  * @return object $array
308
  */
309
+ public function http_request_args( $args, $url ) {
310
  // If it is an https request and we are performing a package download, disable ssl verification
311
  if ( strpos( $url, 'https://' ) !== false && strpos( $url, 'edd_action=package_download' ) ) {
312
  $args['sslverify'] = false;
313
  }
 
314
  return $args;
315
  }
316
 
317
  /**
318
  * Calls the API and, if successfull, returns the object delivered by the API.
319
  *
320
+ * @uses get_bloginfo()
321
+ * @uses wp_remote_post()
322
+ * @uses is_wp_error()
 
 
 
323
  *
324
+ * @param string $_action The requested action.
325
+ * @param array $_data Parameters for the API action.
326
+ * @return false|object
327
  */
328
  private function api_request( $_action, $_data ) {
329
 
330
+ global $wp_version;
331
+
332
  $data = array_merge( $this->api_data, $_data );
333
 
334
  if ( $data['slug'] != $this->slug ) {
335
  return;
336
  }
337
 
338
+ if( $this->api_url == trailingslashit (home_url() ) ) {
 
 
 
 
339
  return false; // Don't allow a plugin to ping itself
340
  }
341
 
342
  $api_params = array(
343
  'edd_action' => 'get_version',
344
+ 'license' => ! empty( $data['license'] ) ? $data['license'] : '',
345
  'item_name' => isset( $data['item_name'] ) ? $data['item_name'] : false,
346
  'item_id' => isset( $data['item_id'] ) ? $data['item_id'] : false,
347
+ 'version' => isset( $data['version'] ) ? $data['version'] : false,
348
  'slug' => $data['slug'],
349
  'author' => $data['author'],
350
  'url' => home_url(),
351
+ 'beta' => ! empty( $data['beta'] ),
352
  );
353
 
354
+ $request = wp_remote_post( $this->api_url, array( 'timeout' => 15, 'sslverify' => false, 'body' => $api_params ) );
 
 
 
355
 
356
  if ( ! is_wp_error( $request ) ) {
357
  $request = json_decode( wp_remote_retrieve_body( $request ) );
363
  $request = false;
364
  }
365
 
366
+ if ( $request && isset( $request->banners ) ) {
367
+ $request->banners = maybe_unserialize( $request->banners );
368
+ }
369
+
370
+ if( ! empty( $request->sections ) ) {
371
+ foreach( $request->sections as $key => $section ) {
372
+ $request->$key = (array) $section;
373
+ }
374
+ }
375
+
376
  return $request;
377
  }
378
 
379
  public function show_changelog() {
380
 
381
+ global $edd_plugin_data;
382
+
383
+ if( empty( $_REQUEST['edd_sl_action'] ) || 'view_plugin_changelog' != $_REQUEST['edd_sl_action'] ) {
384
  return;
385
  }
386
 
387
+ if( empty( $_REQUEST['plugin'] ) ) {
388
  return;
389
  }
390
 
391
+ if( empty( $_REQUEST['slug'] ) ) {
392
  return;
393
  }
394
 
395
+ if( ! current_user_can( 'update_plugins' ) ) {
396
+ wp_die( __( 'You do not have permission to install plugin updates', 'easy-digital-downloads' ), __( 'Error', 'easy-digital-downloads' ), array( 'response' => 403 ) );
397
  }
398
 
399
+ $data = $edd_plugin_data[ $_REQUEST['slug'] ];
400
+ $beta = ! empty( $data['beta'] ) ? true : false;
401
+ $cache_key = md5( 'edd_plugin_' . sanitize_key( $_REQUEST['plugin'] ) . '_' . $beta . '_version_info' );
402
+ $version_info = $this->get_cached_version_info( $cache_key );
403
+
404
+ if( false === $version_info ) {
405
+
406
+ $api_params = array(
407
+ 'edd_action' => 'get_version',
408
+ 'item_name' => isset( $data['item_name'] ) ? $data['item_name'] : false,
409
+ 'item_id' => isset( $data['item_id'] ) ? $data['item_id'] : false,
410
+ 'slug' => $_REQUEST['slug'],
411
+ 'author' => $data['author'],
412
+ 'url' => home_url(),
413
+ 'beta' => ! empty( $data['beta'] )
414
+ );
415
+
416
+ $request = wp_remote_post( $this->api_url, array( 'timeout' => 15, 'sslverify' => false, 'body' => $api_params ) );
417
+
418
+ if ( ! is_wp_error( $request ) ) {
419
+ $version_info = json_decode( wp_remote_retrieve_body( $request ) );
420
+ }
421
+
422
+
423
+ if ( ! empty( $version_info ) && isset( $version_info->sections ) ) {
424
+ $version_info->sections = maybe_unserialize( $version_info->sections );
425
+ } else {
426
+ $version_info = false;
427
+ }
428
+
429
+ if( ! empty( $version_info ) ) {
430
+ foreach( $version_info->sections as $key => $section ) {
431
+ $version_info->$key = (array) $section;
432
+ }
433
+ }
434
+
435
+ $this->set_version_info_cache( $version_info, $cache_key );
436
 
437
+ }
438
+
439
+ if( ! empty( $version_info ) && isset( $version_info->sections['changelog'] ) ) {
440
+ echo '<div style="background:#fff;padding:10px;">' . $version_info->sections['changelog'] . '</div>';
441
  }
442
 
443
  exit;
444
  }
445
 
446
+ public function get_cached_version_info( $cache_key = '' ) {
447
+
448
+ if( empty( $cache_key ) ) {
449
+ $cache_key = $this->cache_key;
450
+ }
451
+
452
+ $cache = get_option( $cache_key );
453
+
454
+ if( empty( $cache['timeout'] ) || current_time( 'timestamp' ) > $cache['timeout'] ) {
455
+ return false; // Cache is expired
456
+ }
457
+
458
+ return json_decode( $cache['value'] );
459
+
460
+ }
461
+
462
+ public function set_version_info_cache( $value = '', $cache_key = '' ) {
463
+
464
+ if( empty( $cache_key ) ) {
465
+ $cache_key = $this->cache_key;
466
+ }
467
+
468
+ $data = array(
469
+ 'timeout' => strtotime( '+3 hours', current_time( 'timestamp' ) ),
470
+ 'value' => json_encode( $value )
471
+ );
472
+
473
+ update_option( $cache_key, $data );
474
+
475
+ }
476
+
477
+ }
includes/admin/class-i18n-module.php CHANGED
@@ -64,16 +64,15 @@ class Give_i18n_Banner {
64
  * Give_i18n constructor.
65
  *
66
  * @param $args
67
- *
68
  */
69
  public function __construct( $args ) {
70
 
71
- //Only for admins.
72
  if ( ! is_admin() ) {
73
  return;
74
  }
75
 
76
- //This plugin is en_US native.
77
  $this->locale = get_locale();
78
  if ( 'en_US' === $this->locale ) {
79
  return;
@@ -130,7 +129,7 @@ class Give_i18n_Banner {
130
  private function promo_message() {
131
  $message = false;
132
 
133
- //Using a translation less than 90% complete.
134
  if ( $this->translation_exists && $this->translation_loaded && $this->percent_translated < 90 ) {
135
  $message = __( 'As you can see, there is a translation of this plugin in %1$s. This translation is currently %3$d%% complete. We need your help to make it complete and to fix any errors. Please register at %4$s to help %5$s to %1$s!', 'give' );
136
  } elseif ( ! $this->translation_loaded && $this->translation_exists ) {
@@ -139,14 +138,13 @@ class Give_i18n_Banner {
139
  $message = __( 'You\'re using WordPress in a language we don\'t support yet. We\'d love for %2$s to be translated in that language too, but unfortunately, it isn\'t right now. You can change that! Register at %4$s to help translate it!', 'give' );
140
  }
141
 
142
- //Links.
143
  $registration_link = sprintf( '<a href="%1$s" target="_blank">%2$s</a>', 'https://wordpress.org/support/register.php', esc_html__( 'WordPress.org', 'give' ) );
144
  $translations_link = sprintf( '<a href="%1$s" target="_blank">%2$s</a>', 'https://translate.wordpress.org/projects/wp-plugins/give', esc_html__( 'complete the translation', 'give' ) );
145
 
146
- //Message.
147
  $message = sprintf( $message, $this->locale_name, 'Give', $this->percent_translated, $registration_link, $translations_link );
148
 
149
-
150
  return $message;
151
 
152
  }
@@ -206,6 +204,16 @@ class Give_i18n_Banner {
206
  div.give-addon-alert .dismiss:hover {
207
  color: #333;
208
  }
 
 
 
 
 
 
 
 
 
 
209
  </style>
210
  <div id="give-i18n-notice" class="give-addon-alert updated" style="">
211
 
@@ -318,4 +326,4 @@ $give_i18n = new Give_i18n_Banner(
318
  'hook' => 'give_forms_page_give-settings',
319
  'glotpress_url' => 'https://translate.wordpress.org/api/projects/wp-plugins/give/stable/',
320
  )
321
- );
64
  * Give_i18n constructor.
65
  *
66
  * @param $args
 
67
  */
68
  public function __construct( $args ) {
69
 
70
+ // Only for admins.
71
  if ( ! is_admin() ) {
72
  return;
73
  }
74
 
75
+ // This plugin is en_US native.
76
  $this->locale = get_locale();
77
  if ( 'en_US' === $this->locale ) {
78
  return;
129
  private function promo_message() {
130
  $message = false;
131
 
132
+ // Using a translation less than 90% complete.
133
  if ( $this->translation_exists && $this->translation_loaded && $this->percent_translated < 90 ) {
134
  $message = __( 'As you can see, there is a translation of this plugin in %1$s. This translation is currently %3$d%% complete. We need your help to make it complete and to fix any errors. Please register at %4$s to help %5$s to %1$s!', 'give' );
135
  } elseif ( ! $this->translation_loaded && $this->translation_exists ) {
138
  $message = __( 'You\'re using WordPress in a language we don\'t support yet. We\'d love for %2$s to be translated in that language too, but unfortunately, it isn\'t right now. You can change that! Register at %4$s to help translate it!', 'give' );
139
  }
140
 
141
+ // Links.
142
  $registration_link = sprintf( '<a href="%1$s" target="_blank">%2$s</a>', 'https://wordpress.org/support/register.php', esc_html__( 'WordPress.org', 'give' ) );
143
  $translations_link = sprintf( '<a href="%1$s" target="_blank">%2$s</a>', 'https://translate.wordpress.org/projects/wp-plugins/give', esc_html__( 'complete the translation', 'give' ) );
144
 
145
+ // Message.
146
  $message = sprintf( $message, $this->locale_name, 'Give', $this->percent_translated, $registration_link, $translations_link );
147
 
 
148
  return $message;
149
 
150
  }
204
  div.give-addon-alert .dismiss:hover {
205
  color: #333;
206
  }
207
+
208
+ /* RTL Styles for banner */
209
+ body.rtl .give-i18n-notice-content {
210
+ margin: 0 125px 0 30px;
211
+ }
212
+ body.rtl div.give-addon-alert .dismiss {
213
+ left:20px;
214
+ right:auto;
215
+ }
216
+
217
  </style>
218
  <div id="give-i18n-notice" class="give-addon-alert updated" style="">
219
 
326
  'hook' => 'give_forms_page_give-settings',
327
  'glotpress_url' => 'https://translate.wordpress.org/api/projects/wp-plugins/give/stable/',
328
  )
329
+ );
includes/admin/settings/class-settings-license.php CHANGED
@@ -47,6 +47,7 @@ if ( ! class_exists( 'Give_Settings_License' ) ) :
47
 
48
  add_filter( 'give-settings_tabs_array', array( $this, 'add_settings_page' ), 20 );
49
  add_action( "give-settings_settings_{$this->id}_page", array( $this, 'output' ) );
 
50
  }
51
 
52
  /**
@@ -104,6 +105,26 @@ if ( ! class_exists( 'Give_Settings_License' ) ) :
104
 
105
  Give_Admin_Settings::output_fields( $settings, 'give_settings' );
106
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
107
  }
108
 
109
  endif;
47
 
48
  add_filter( 'give-settings_tabs_array', array( $this, 'add_settings_page' ), 20 );
49
  add_action( "give-settings_settings_{$this->id}_page", array( $this, 'output' ) );
50
+ add_action( "give-settings_save_{$this->id}", array( $this, 'save' ) );
51
  }
52
 
53
  /**
105
 
106
  Give_Admin_Settings::output_fields( $settings, 'give_settings' );
107
  }
108
+
109
+ /**
110
+ * Save settings.
111
+ *
112
+ * @since 1.8
113
+ * @return void
114
+ */
115
+ public function save() {
116
+ $settings = $this->get_settings();
117
+ $current_section = give_get_current_setting_section();
118
+
119
+ Give_Admin_Settings::save_fields( $settings, 'give_settings' );
120
+
121
+ /**
122
+ * Trigger Action
123
+ *
124
+ * @since 1.8
125
+ */
126
+ do_action( 'give_update_options_' . $this->id . '_' . $current_section );
127
+ }
128
  }
129
 
130
  endif;
includes/process-donation.php CHANGED
@@ -275,6 +275,17 @@ function give_purchase_form_validate_fields() {
275
  give_purchase_form_validate_agree_to_terms();
276
  }
277
 
 
 
 
 
 
 
 
 
 
 
 
278
  if ( is_user_logged_in() ) {
279
  // Collect logged in user data
280
  $valid_data['logged_in_user'] = give_purchase_form_validate_logged_in_user();
@@ -556,7 +567,7 @@ function give_purchase_form_validate_new_user() {
556
  );
557
 
558
  // Get user data.
559
- $user_data = wp_parse_args( array_map( 'trim', give_clean( $_POST ) ), $default_user_data );
560
  $registering_new_user = false;
561
  $form_id = absint( $user_data['give-form-id'] );
562
 
@@ -580,18 +591,18 @@ function give_purchase_form_validate_new_user() {
580
  }
581
 
582
  // Check if we have an username to register.
583
- if( give_validate_username( $user_data['give_user_login'] ) ) {
584
- $registering_new_user = true;
585
  $valid_user_data['user_login'] = $user_data['give_user_login'];
586
  }
587
 
588
  // Check if we have an email to verify.
589
- if( give_validate_user_email( $user_data['give_email'], $registering_new_user ) ) {
590
  $valid_user_data['user_email'] = $user_data['give_email'];
591
  }
592
 
593
  // Check password.
594
- if( give_validate_user_password( $user_data['give_user_pass'], $user_data['give_user_pass_confirm'], $registering_new_user)){
595
  // All is good to go.
596
  $valid_user_data['user_pass'] = $user_data['give_user_pass'];
597
  }
275
  give_purchase_form_validate_agree_to_terms();
276
  }
277
 
278
+ // Stop processing donor registration, if donor registration is optional and donor can do guest checkout.
279
+ // If registration form username field is empty that means donor do not want to registration instead want guest checkout.
280
+ if (
281
+ ! give_logged_in_only( $form_id )
282
+ && isset( $_POST['give-purchase-var'] )
283
+ && $_POST['give-purchase-var'] == 'needs-to-register'
284
+ && empty( $_POST['give_user_login'] )
285
+ ) {
286
+ unset( $_POST['give-purchase-var'] );
287
+ }
288
+
289
  if ( is_user_logged_in() ) {
290
  // Collect logged in user data
291
  $valid_data['logged_in_user'] = give_purchase_form_validate_logged_in_user();
567
  );
568
 
569
  // Get user data.
570
+ $user_data = wp_parse_args( array_map( 'trim', give_clean( $_POST ) ), $default_user_data );
571
  $registering_new_user = false;
572
  $form_id = absint( $user_data['give-form-id'] );
573
 
591
  }
592
 
593
  // Check if we have an username to register.
594
+ if ( give_validate_username( $user_data['give_user_login'] ) ) {
595
+ $registering_new_user = true;
596
  $valid_user_data['user_login'] = $user_data['give_user_login'];
597
  }
598
 
599
  // Check if we have an email to verify.
600
+ if ( give_validate_user_email( $user_data['give_email'], $registering_new_user ) ) {
601
  $valid_user_data['user_email'] = $user_data['give_email'];
602
  }
603
 
604
  // Check password.
605
+ if ( give_validate_user_password( $user_data['give_user_pass'], $user_data['give_user_pass_confirm'], $registering_new_user ) ) {
606
  // All is good to go.
607
  $valid_user_data['user_pass'] = $user_data['give_user_pass'];
608
  }
includes/user-functions.php CHANGED
@@ -320,7 +320,7 @@ function give_validate_username( $username, $form_id = 0 ) {
320
  }
321
  } else {
322
  // Username is empty.
323
- give_set_error( 'username_empty', esc_html__( 'Enter an username.', 'give' ) );
324
  $valid = false;
325
 
326
  // Check if guest checkout is disable for form.
320
  }
321
  } else {
322
  // Username is empty.
323
+ give_set_error( 'username_empty', esc_html__( 'Enter a username.', 'give' ) );
324
  $valid = false;
325
 
326
  // Check if guest checkout is disable for form.
languages/give.pot CHANGED
@@ -875,31 +875,31 @@ msgstr ""
875
  msgid "You can create API keys for individual users within their profile edit screen. API keys allow users to use the <a href=\"%1$s\" target=\"_blank\">Give REST API</a> to retrieve donation data in JSON or XML for external applications or devices, such as <a href=\"%2$s\" target=\"_blank\">Zapier</a>."
876
  msgstr ""
877
 
878
- #: includes/admin/class-i18n-module.php:135
879
  msgid "As you can see, there is a translation of this plugin in %1$s. This translation is currently %3$d%% complete. We need your help to make it complete and to fix any errors. Please register at %4$s to help %5$s to %1$s!"
880
  msgstr ""
881
 
882
- #: includes/admin/class-i18n-module.php:137
883
  msgid "You're using WordPress in %1$s. While %2$s has been %3$d%% translated to %1$s, it has not been shipped with the plugin yet. You can help! Register at %4$s to help complete the translation to %1$s!"
884
  msgstr ""
885
 
886
- #: includes/admin/class-i18n-module.php:139
887
  msgid "You're using WordPress in a language we don't support yet. We'd love for %2$s to be translated in that language too, but unfortunately, it isn't right now. You can change that! Register at %4$s to help translate it!"
888
  msgstr ""
889
 
890
- #: includes/admin/class-i18n-module.php:143
891
  msgid "WordPress.org"
892
  msgstr ""
893
 
894
- #: includes/admin/class-i18n-module.php:144
895
  msgid "complete the translation"
896
  msgstr ""
897
 
898
- #: includes/admin/class-i18n-module.php:217
899
  msgid "Help Translate Give to %s"
900
  msgstr ""
901
 
902
- #: includes/admin/class-i18n-module.php:220
903
  msgid "Register now &raquo;"
904
  msgstr ""
905
 
@@ -959,7 +959,7 @@ msgstr ""
959
  msgid "You do not have permission to edit this donor."
960
  msgstr ""
961
 
962
- #: includes/admin/customers/customer-actions.php:31, includes/admin/customers/customer-actions.php:43, includes/admin/customers/customer-actions.php:195, includes/admin/customers/customer-actions.php:207, includes/admin/customers/customer-actions.php:273, includes/admin/customers/customer-actions.php:286, includes/admin/customers/customer-actions.php:368, includes/admin/customers/customer-actions.php:379, includes/admin/customers/customer-actions.php:545, includes/admin/customers/customer-actions.php:589, includes/admin/EDD_SL_Plugin_Updater.php:328, includes/admin/forms/dashboard-columns.php:237, includes/admin/payments/actions.php:31, includes/admin/payments/actions.php:88, includes/admin/payments/actions.php:99, includes/admin/payments/actions.php:314, includes/admin/payments/actions.php:334, includes/admin/payments/actions.php:367, includes/admin/payments/actions.php:389, includes/admin/payments/view-order-details.php:24, includes/admin/payments/view-order-details.php:34, includes/admin/reporting/class-api-requests-logs-list-table.php:141, includes/admin/reporting/class-export.php:177, includes/admin/reporting/class-gateway-error-logs-list-table.php:128, includes/admin/reporting/export/class-batch-export.php:133, includes/admin/reporting/export/export-actions.php:26, includes/admin/reporting/pdf-reports.php:31, includes/admin/reporting/pdf-reports.php:35, includes/admin/reporting/tools/class-give-tools-delete-test-transactions.php:157, includes/admin/reporting/tools/class-give-tools-recount-all-stats.php:206, includes/admin/reporting/tools/class-give-tools-recount-customer-stats.php:195, includes/admin/reporting/tools/class-give-tools-recount-form-stats.php:220, includes/admin/reporting/tools/class-give-tools-recount-income.php:157, includes/admin/reporting/tools/class-give-tools-recount-single-customer-stats.php:152, includes/admin/reporting/tools/class-give-tools-reset-stats.php:185, includes/admin/upgrades/upgrade-functions.php:167, includes/admin/upgrades/upgrade-functions.php:279, includes/admin/upgrades/upgrade-functions.php:316, includes/admin/upgrades/upgrade-functions.php:687, includes/api/class-give-api.php:1691, includes/api/class-give-api.php:1696, includes/api/class-give-api.php:1714, includes/api/class-give-api.php:1724, includes/class-give-license-handler.php:323, includes/class-give-license-handler.php:421, includes/emails/actions.php:56, includes/emails/template.php:270, includes/error-tracking.php:50, includes/formatting.php:470, includes/gateways/manual.php:38
963
  msgid "Error"
964
  msgstr ""
965
 
@@ -1015,7 +1015,7 @@ msgstr ""
1015
  msgid "Nonce verification failed."
1016
  msgstr ""
1017
 
1018
- #: includes/admin/customers/customer-actions.php:472, includes/login-register.php:254, includes/process-donation.php:526, includes/process-donation.php:700, includes/user-functions.php:368
1019
  msgid "Invalid email."
1020
  msgstr ""
1021
 
@@ -1276,18 +1276,6 @@ msgid_plural "%s Give Forms"
1276
  msgstr[0] ""
1277
  msgstr[1] ""
1278
 
1279
- #: includes/admin/EDD_SL_Plugin_Updater.php:175
1280
- msgid "There is a new version of %1$s available. <a target=\"_blank\" class=\"thickbox\" href=\"%2$s\">View version %3$s details</a>."
1281
- msgstr ""
1282
-
1283
- #: includes/admin/EDD_SL_Plugin_Updater.php:183
1284
- msgid "There is a new version of %1$s available. <a target=\"_blank\" class=\"thickbox\" href=\"%2$s\">View version %3$s details</a> or <a href=\"%4$s\">update now</a>."
1285
- msgstr ""
1286
-
1287
- #: includes/admin/EDD_SL_Plugin_Updater.php:328
1288
- msgid "You do not have permission to install plugin updates."
1289
- msgstr ""
1290
-
1291
  #: includes/admin/forms/class-metabox-form-data.php:49
1292
  msgid "Donation Form Options"
1293
  msgstr ""
@@ -5853,7 +5841,7 @@ msgstr ""
5853
  msgid "Your password"
5854
  msgstr ""
5855
 
5856
- #: includes/forms/template.php:1300, includes/process-donation.php:643, templates/shortcode-login.php:40
5857
  msgid "Reset Password"
5858
  msgstr ""
5859
 
@@ -6157,11 +6145,11 @@ msgstr ""
6157
  msgid "We're sorry, your donation failed to process. Please try again or contact site support."
6158
  msgstr ""
6159
 
6160
- #: includes/login-register.php:112, includes/process-donation.php:641
6161
  msgid "The password you entered is incorrect."
6162
  msgstr ""
6163
 
6164
- #: includes/login-register.php:115, includes/process-donation.php:664
6165
  msgid "The username you entered does not exist."
6166
  msgstr ""
6167
 
@@ -6590,71 +6578,71 @@ msgstr ""
6590
  msgid "Honeypot field detected. Go away bad bot!"
6591
  msgstr ""
6592
 
6593
- #: includes/process-donation.php:324
6594
  msgid "Please insert a valid donation amount."
6595
  msgstr ""
6596
 
6597
- #: includes/process-donation.php:333
6598
  msgid "This form has a minimum donation amount of %s."
6599
  msgstr ""
6600
 
6601
- #: includes/process-donation.php:346
6602
  msgid "The selected payment gateway is not enabled."
6603
  msgstr ""
6604
 
6605
- #: includes/process-donation.php:398, includes/scripts.php:66
6606
  msgid "You must agree to the terms and conditions."
6607
  msgstr ""
6608
 
6609
- #: includes/process-donation.php:419, includes/scripts.php:62
6610
  msgid "Please enter a valid email address."
6611
  msgstr ""
6612
 
6613
- #: includes/process-donation.php:423, includes/scripts.php:61
6614
  msgid "Please enter your first name."
6615
  msgstr ""
6616
 
6617
- #: includes/process-donation.php:432
6618
  msgid "Please enter your primary billing address."
6619
  msgstr ""
6620
 
6621
- #: includes/process-donation.php:436
6622
  msgid "Please enter your zip / postal code."
6623
  msgstr ""
6624
 
6625
- #: includes/process-donation.php:440
6626
  msgid "Please enter your billing city."
6627
  msgstr ""
6628
 
6629
- #: includes/process-donation.php:444
6630
  msgid "Please select your billing country."
6631
  msgstr ""
6632
 
6633
- #: includes/process-donation.php:448
6634
  msgid "Please enter billing state / province."
6635
  msgstr ""
6636
 
6637
- #: includes/process-donation.php:530
6638
  msgid "The user information is invalid."
6639
  msgstr ""
6640
 
6641
- #: includes/process-donation.php:619, includes/user-functions.php:328
6642
  msgid "You must register or login to complete your donation."
6643
  msgstr ""
6644
 
6645
- #: includes/process-donation.php:660, includes/scripts.php:64, includes/user-functions.php:416
6646
  msgid "Enter a password."
6647
  msgstr ""
6648
 
6649
- #: includes/process-donation.php:689
6650
  msgid "You must be logged in to donate."
6651
  msgstr ""
6652
 
6653
- #: includes/process-donation.php:713, includes/user-functions.php:363
6654
  msgid "Enter an email."
6655
  msgstr ""
6656
 
6657
- #: includes/process-donation.php:887
6658
  msgid "The zip / postal code you entered for your billing address is invalid."
6659
  msgstr ""
6660
 
@@ -6831,7 +6819,7 @@ msgid "Give Placeholder Image"
6831
  msgstr ""
6832
 
6833
  #: includes/user-functions.php:323
6834
- msgid "Enter an username."
6835
  msgstr ""
6836
 
6837
  #: includes/user-functions.php:373
875
  msgid "You can create API keys for individual users within their profile edit screen. API keys allow users to use the <a href=\"%1$s\" target=\"_blank\">Give REST API</a> to retrieve donation data in JSON or XML for external applications or devices, such as <a href=\"%2$s\" target=\"_blank\">Zapier</a>."
876
  msgstr ""
877
 
878
+ #: includes/admin/class-i18n-module.php:134
879
  msgid "As you can see, there is a translation of this plugin in %1$s. This translation is currently %3$d%% complete. We need your help to make it complete and to fix any errors. Please register at %4$s to help %5$s to %1$s!"
880
  msgstr ""
881
 
882
+ #: includes/admin/class-i18n-module.php:136
883
  msgid "You're using WordPress in %1$s. While %2$s has been %3$d%% translated to %1$s, it has not been shipped with the plugin yet. You can help! Register at %4$s to help complete the translation to %1$s!"
884
  msgstr ""
885
 
886
+ #: includes/admin/class-i18n-module.php:138
887
  msgid "You're using WordPress in a language we don't support yet. We'd love for %2$s to be translated in that language too, but unfortunately, it isn't right now. You can change that! Register at %4$s to help translate it!"
888
  msgstr ""
889
 
890
+ #: includes/admin/class-i18n-module.php:142
891
  msgid "WordPress.org"
892
  msgstr ""
893
 
894
+ #: includes/admin/class-i18n-module.php:143
895
  msgid "complete the translation"
896
  msgstr ""
897
 
898
+ #: includes/admin/class-i18n-module.php:225
899
  msgid "Help Translate Give to %s"
900
  msgstr ""
901
 
902
+ #: includes/admin/class-i18n-module.php:228
903
  msgid "Register now &raquo;"
904
  msgstr ""
905
 
959
  msgid "You do not have permission to edit this donor."
960
  msgstr ""
961
 
962
+ #: includes/admin/customers/customer-actions.php:31, includes/admin/customers/customer-actions.php:43, includes/admin/customers/customer-actions.php:195, includes/admin/customers/customer-actions.php:207, includes/admin/customers/customer-actions.php:273, includes/admin/customers/customer-actions.php:286, includes/admin/customers/customer-actions.php:368, includes/admin/customers/customer-actions.php:379, includes/admin/customers/customer-actions.php:545, includes/admin/customers/customer-actions.php:589, includes/admin/forms/dashboard-columns.php:237, includes/admin/payments/actions.php:31, includes/admin/payments/actions.php:88, includes/admin/payments/actions.php:99, includes/admin/payments/actions.php:314, includes/admin/payments/actions.php:334, includes/admin/payments/actions.php:367, includes/admin/payments/actions.php:389, includes/admin/payments/view-order-details.php:24, includes/admin/payments/view-order-details.php:34, includes/admin/reporting/class-api-requests-logs-list-table.php:141, includes/admin/reporting/class-export.php:177, includes/admin/reporting/class-gateway-error-logs-list-table.php:128, includes/admin/reporting/export/class-batch-export.php:133, includes/admin/reporting/export/export-actions.php:26, includes/admin/reporting/pdf-reports.php:31, includes/admin/reporting/pdf-reports.php:35, includes/admin/reporting/tools/class-give-tools-delete-test-transactions.php:157, includes/admin/reporting/tools/class-give-tools-recount-all-stats.php:206, includes/admin/reporting/tools/class-give-tools-recount-customer-stats.php:195, includes/admin/reporting/tools/class-give-tools-recount-form-stats.php:220, includes/admin/reporting/tools/class-give-tools-recount-income.php:157, includes/admin/reporting/tools/class-give-tools-recount-single-customer-stats.php:152, includes/admin/reporting/tools/class-give-tools-reset-stats.php:185, includes/admin/upgrades/upgrade-functions.php:167, includes/admin/upgrades/upgrade-functions.php:279, includes/admin/upgrades/upgrade-functions.php:316, includes/admin/upgrades/upgrade-functions.php:687, includes/api/class-give-api.php:1691, includes/api/class-give-api.php:1696, includes/api/class-give-api.php:1714, includes/api/class-give-api.php:1724, includes/class-give-license-handler.php:323, includes/class-give-license-handler.php:421, includes/emails/actions.php:56, includes/emails/template.php:270, includes/error-tracking.php:50, includes/formatting.php:470, includes/gateways/manual.php:38
963
  msgid "Error"
964
  msgstr ""
965
 
1015
  msgid "Nonce verification failed."
1016
  msgstr ""
1017
 
1018
+ #: includes/admin/customers/customer-actions.php:472, includes/login-register.php:254, includes/process-donation.php:537, includes/process-donation.php:711, includes/user-functions.php:368
1019
  msgid "Invalid email."
1020
  msgstr ""
1021
 
1276
  msgstr[0] ""
1277
  msgstr[1] ""
1278
 
 
 
 
 
 
 
 
 
 
 
 
 
1279
  #: includes/admin/forms/class-metabox-form-data.php:49
1280
  msgid "Donation Form Options"
1281
  msgstr ""
5841
  msgid "Your password"
5842
  msgstr ""
5843
 
5844
+ #: includes/forms/template.php:1300, includes/process-donation.php:654, templates/shortcode-login.php:40
5845
  msgid "Reset Password"
5846
  msgstr ""
5847
 
6145
  msgid "We're sorry, your donation failed to process. Please try again or contact site support."
6146
  msgstr ""
6147
 
6148
+ #: includes/login-register.php:112, includes/process-donation.php:652
6149
  msgid "The password you entered is incorrect."
6150
  msgstr ""
6151
 
6152
+ #: includes/login-register.php:115, includes/process-donation.php:675
6153
  msgid "The username you entered does not exist."
6154
  msgstr ""
6155
 
6578
  msgid "Honeypot field detected. Go away bad bot!"
6579
  msgstr ""
6580
 
6581
+ #: includes/process-donation.php:335
6582
  msgid "Please insert a valid donation amount."
6583
  msgstr ""
6584
 
6585
+ #: includes/process-donation.php:344
6586
  msgid "This form has a minimum donation amount of %s."
6587
  msgstr ""
6588
 
6589
+ #: includes/process-donation.php:357
6590
  msgid "The selected payment gateway is not enabled."
6591
  msgstr ""
6592
 
6593
+ #: includes/process-donation.php:409, includes/scripts.php:66
6594
  msgid "You must agree to the terms and conditions."
6595
  msgstr ""
6596
 
6597
+ #: includes/process-donation.php:430, includes/scripts.php:62
6598
  msgid "Please enter a valid email address."
6599
  msgstr ""
6600
 
6601
+ #: includes/process-donation.php:434, includes/scripts.php:61
6602
  msgid "Please enter your first name."
6603
  msgstr ""
6604
 
6605
+ #: includes/process-donation.php:443
6606
  msgid "Please enter your primary billing address."
6607
  msgstr ""
6608
 
6609
+ #: includes/process-donation.php:447
6610
  msgid "Please enter your zip / postal code."
6611
  msgstr ""
6612
 
6613
+ #: includes/process-donation.php:451
6614
  msgid "Please enter your billing city."
6615
  msgstr ""
6616
 
6617
+ #: includes/process-donation.php:455
6618
  msgid "Please select your billing country."
6619
  msgstr ""
6620
 
6621
+ #: includes/process-donation.php:459
6622
  msgid "Please enter billing state / province."
6623
  msgstr ""
6624
 
6625
+ #: includes/process-donation.php:541
6626
  msgid "The user information is invalid."
6627
  msgstr ""
6628
 
6629
+ #: includes/process-donation.php:630, includes/user-functions.php:328
6630
  msgid "You must register or login to complete your donation."
6631
  msgstr ""
6632
 
6633
+ #: includes/process-donation.php:671, includes/scripts.php:64, includes/user-functions.php:416
6634
  msgid "Enter a password."
6635
  msgstr ""
6636
 
6637
+ #: includes/process-donation.php:700
6638
  msgid "You must be logged in to donate."
6639
  msgstr ""
6640
 
6641
+ #: includes/process-donation.php:724, includes/user-functions.php:363
6642
  msgid "Enter an email."
6643
  msgstr ""
6644
 
6645
+ #: includes/process-donation.php:898
6646
  msgid "The zip / postal code you entered for your billing address is invalid."
6647
  msgstr ""
6648
 
6819
  msgstr ""
6820
 
6821
  #: includes/user-functions.php:323
6822
+ msgid "Enter a username."
6823
  msgstr ""
6824
 
6825
  #: includes/user-functions.php:373
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: https://givewp.com/
4
  Tags: donation, donations, donation plugin, wordpress donation plugin, wp donation, ecommerce, e-commerce, fundraising, fundraiser, crowdfunding, wordpress donations, commerce, wordpress ecommerce, giving, charity, donate, gifts, non-profit, paypal, stripe, churches, nonprofit, paypal donations, paypal donate, stripe donations, stripe donate, authorize.net, authorize.net donations
5
  Requires at least: 4.2
6
  Tested up to: 4.7.2
7
- Stable tag: 1.8.3
8
  License: GPLv3
9
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
10
 
@@ -165,6 +165,11 @@ We also really like WooCommerce. It's hands-down the most robust eCommerce platf
165
 
166
  == Changelog ==
167
 
 
 
 
 
 
168
  = 1.8.3 =
169
  * New: The new Goal Complete message has been turned into a WYSIWYG that also render oEmbeds like YouTube and WordPress shortcodes. This means now you can display a custom video or any content you'd like when a goal has completed. [#1504](https://github.com/WordImpress/Give/issues/1504), [#1545](https://github.com/WordImpress/Give/issues/1545)
170
  * New: The Give Settings API received a new API Key field type that we will be rolling out into each of the payment gateways for additional security. [#1540](https://github.com/WordImpress/Give/issues/1540)
4
  Tags: donation, donations, donation plugin, wordpress donation plugin, wp donation, ecommerce, e-commerce, fundraising, fundraiser, crowdfunding, wordpress donations, commerce, wordpress ecommerce, giving, charity, donate, gifts, non-profit, paypal, stripe, churches, nonprofit, paypal donations, paypal donate, stripe donations, stripe donate, authorize.net, authorize.net donations
5
  Requires at least: 4.2
6
  Tested up to: 4.7.2
7
+ Stable tag: 1.8.4
8
  License: GPLv3
9
  License URI: http://www.gnu.org/licenses/gpl-3.0.html
10
 
165
 
166
  == Changelog ==
167
 
168
+ = 1.8.4 =
169
+ * Fix: When a donation form has guest donations enabled and the registration + login option enabled the optional fields were being incorrect required. [#1553](https://github.com/WordImpress/Give/issues/1553)
170
+ * Fix: Minor RTL style issue with the i18n banner that displays asking help translating Give when WP-Admin is in a non-supported language. [#1547](https://github.com/WordImpress/Give/issues/1547)
171
+ * Fix: Updated the included add-on software licensing class and fixed active license placeholders. [#1556](https://github.com/WordImpress/Give/issues/1556)
172
+
173
  = 1.8.3 =
174
  * New: The new Goal Complete message has been turned into a WYSIWYG that also render oEmbeds like YouTube and WordPress shortcodes. This means now you can display a custom video or any content you'd like when a goal has completed. [#1504](https://github.com/WordImpress/Give/issues/1504), [#1545](https://github.com/WordImpress/Give/issues/1545)
175
  * New: The Give Settings API received a new API Key field type that we will be rolling out into each of the payment gateways for additional security. [#1540](https://github.com/WordImpress/Give/issues/1540)