Version Description
- Improvement: reduced the number of autoloaded options to improve performance
Download this release
Release Info
Developer | ivole |
Plugin | Customer Reviews for WooCommerce |
Version | 5.7.0 |
Comparing to | |
See all releases |
Code changes from version 5.6.5 to 5.7.0
class-ivole.php
CHANGED
@@ -66,7 +66,7 @@ require_once( __DIR__ . '/includes/qna/class-cr-qna-shortcode.php' );
|
|
66 |
require_once( __DIR__ . '/includes/qna/class-cr-qna-email.php' );
|
67 |
|
68 |
class Ivole {
|
69 |
-
const CR_VERSION = '5.
|
70 |
|
71 |
public function __construct() {
|
72 |
if( function_exists( 'wc' ) ) {
|
66 |
require_once( __DIR__ . '/includes/qna/class-cr-qna-email.php' );
|
67 |
|
68 |
class Ivole {
|
69 |
+
const CR_VERSION = '5.7.0';
|
70 |
|
71 |
public function __construct() {
|
72 |
if( function_exists( 'wc' ) ) {
|
includes/emails/class-cr-email-func.php
CHANGED
@@ -384,6 +384,33 @@ if ( ! class_exists( 'CR_Email_Func' ) ) :
|
|
384 |
$headers[] = 'Bcc: ' . $data['email']['replyTo'];
|
385 |
}
|
386 |
$message = self::get_local_email_template_coupon( $data, $is_test );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
387 |
$wpmail_result = wp_mail( $data['email']['to'], $data['email']['subject'], $message, $headers );
|
388 |
$result = json_encode( array( 'status' => 'OK' ) );
|
389 |
} else {
|
384 |
$headers[] = 'Bcc: ' . $data['email']['replyTo'];
|
385 |
}
|
386 |
$message = self::get_local_email_template_coupon( $data, $is_test );
|
387 |
+
$message = apply_filters(
|
388 |
+
'cr_local_review_discount_template',
|
389 |
+
$message,
|
390 |
+
array(
|
391 |
+
'language' => $data['language'],
|
392 |
+
'email' => $data['email']['to'],
|
393 |
+
'firstname' => $data['customer']['firstname'],
|
394 |
+
'lastname' => $data['customer']['lastname'],
|
395 |
+
'order_id' => $data['order']['id'],
|
396 |
+
'order_date' => $data['order']['date'],
|
397 |
+
'items' => $data['order']['items'],
|
398 |
+
'currency' => $data['order']['currency'],
|
399 |
+
'discount_amount' => $data['discount']['amount'],
|
400 |
+
'discount_code' => $data['discount']['code'],
|
401 |
+
'is_test' => $is_test
|
402 |
+
)
|
403 |
+
);
|
404 |
+
$data['email']['subject'] = apply_filters(
|
405 |
+
'cr_local_review_discount_subject',
|
406 |
+
$data['email']['subject'],
|
407 |
+
array(
|
408 |
+
'language' => $data['language'],
|
409 |
+
'firstname' => $data['customer']['firstname'],
|
410 |
+
'lastname' => $data['customer']['lastname'],
|
411 |
+
'order_id' => $data['order']['id']
|
412 |
+
)
|
413 |
+
);
|
414 |
$wpmail_result = wp_mail( $data['email']['to'], $data['email']['subject'], $message, $headers );
|
415 |
$result = json_encode( array( 'status' => 'OK' ) );
|
416 |
} else {
|
includes/settings/class-cr-admin-menu-settings.php
CHANGED
@@ -487,9 +487,12 @@ if ( ! class_exists( 'CR_Settings_Admin_Menu' ) ):
|
|
487 |
} elseif( 'emails' === $current_tab ) {
|
488 |
if( isset( $_GET['section'] ) ) {
|
489 |
$section = $_GET['section'];
|
490 |
-
if(
|
|
|
|
|
|
|
491 |
if( ! $this->is_pro_addon_activated() ) {
|
492 |
-
if( $this->is_banner_hidden( '
|
493 |
return;
|
494 |
}
|
495 |
?>
|
@@ -514,8 +517,8 @@ if ( ! class_exists( 'CR_Settings_Admin_Menu' ) ):
|
|
514 |
</div>
|
515 |
<div class="cr-features-bnr-other">And other powerful features...</div>
|
516 |
<div class="cr-features-bnr-buttons">
|
517 |
-
<a class="button cr-features-bnr-pricing" href="https://www.cusrev.com/business/pricing.html?utm_source=wp_plugin&utm_medium=
|
518 |
-
<a class="cr-features-bnr-hide" href="#" data-banner="
|
519 |
</div>
|
520 |
</div>
|
521 |
</div>
|
487 |
} elseif( 'emails' === $current_tab ) {
|
488 |
if( isset( $_GET['section'] ) ) {
|
489 |
$section = $_GET['section'];
|
490 |
+
if(
|
491 |
+
'review_reminder' === $section ||
|
492 |
+
'review_discount' === $section
|
493 |
+
) {
|
494 |
if( ! $this->is_pro_addon_activated() ) {
|
495 |
+
if( $this->is_banner_hidden( 'emails_' . $section ) ) {
|
496 |
return;
|
497 |
}
|
498 |
?>
|
517 |
</div>
|
518 |
<div class="cr-features-bnr-other">And other powerful features...</div>
|
519 |
<div class="cr-features-bnr-buttons">
|
520 |
+
<a class="button cr-features-bnr-pricing" href="https://www.cusrev.com/business/pricing.html?utm_source=wp_plugin&utm_medium=emails_<?php esc_attr_e( $section ); ?>" target="_blank" rel="noopener noreferrer">See pricing<img src="<?php esc_attr_e( untrailingslashit( plugin_dir_url( dirname( dirname( __FILE__ ) ) ) ) . '/img/external-link-2.svg' ); ?>"></a>
|
521 |
+
<a class="cr-features-bnr-hide" href="#" data-banner="emails_<?php esc_attr_e( $section ); ?>">Hide this message</a>
|
522 |
</div>
|
523 |
</div>
|
524 |
</div>
|
includes/settings/class-cr-settings-review-reminder.php
CHANGED
@@ -308,7 +308,8 @@ if ( ! class_exists( 'CR_Review_Reminder_Settings' ) ):
|
|
308 |
'desc' => __( 'Emails will be sent N days after order status is changed to the value specified in the field below. N is a sending delay that needs to be defined in this field.', 'customer-reviews-woocommerce' ),
|
309 |
'default' => 5,
|
310 |
'id' => 'ivole_delay',
|
311 |
-
'desc_tip' => true
|
|
|
312 |
),
|
313 |
20 => array(
|
314 |
'title' => __( 'Order Status', 'customer-reviews-woocommerce' ),
|
@@ -319,7 +320,8 @@ if ( ! class_exists( 'CR_Review_Reminder_Settings' ) ):
|
|
319 |
'desc_tip' => true,
|
320 |
'class' => 'wc-enhanced-select',
|
321 |
'css' => 'min-width:300px;',
|
322 |
-
'options' => $order_statuses
|
|
|
323 |
),
|
324 |
25 => array(
|
325 |
'title' => __( 'Enable for', 'customer-reviews-woocommerce' ),
|
@@ -333,7 +335,8 @@ if ( ! class_exists( 'CR_Review_Reminder_Settings' ) ):
|
|
333 |
'options' => array(
|
334 |
'all' => __( 'All Categories', 'customer-reviews-woocommerce' ),
|
335 |
'categories' => __( 'Specific Categories', 'customer-reviews-woocommerce' )
|
336 |
-
)
|
|
|
337 |
),
|
338 |
30 => array(
|
339 |
'title' => __( 'Categories', 'customer-reviews-woocommerce' ),
|
@@ -342,7 +345,8 @@ if ( ! class_exists( 'CR_Review_Reminder_Settings' ) ):
|
|
342 |
'id' => 'ivole_enabled_categories',
|
343 |
'desc_tip' => true,
|
344 |
'class' => 'wc-enhanced-select',
|
345 |
-
'css' => 'min-width:300px;'
|
|
|
346 |
),
|
347 |
35 => array(
|
348 |
'title' => __( 'Enable for Roles', 'customer-reviews-woocommerce' ),
|
@@ -356,7 +360,8 @@ if ( ! class_exists( 'CR_Review_Reminder_Settings' ) ):
|
|
356 |
'options' => array(
|
357 |
'all' => __( 'All Roles', 'customer-reviews-woocommerce' ),
|
358 |
'roles' => __( 'Specific Roles', 'customer-reviews-woocommerce' )
|
359 |
-
)
|
|
|
360 |
),
|
361 |
40 => array(
|
362 |
'title' => __( 'Roles', 'customer-reviews-woocommerce' ),
|
@@ -365,14 +370,16 @@ if ( ! class_exists( 'CR_Review_Reminder_Settings' ) ):
|
|
365 |
'id' => 'ivole_enabled_roles',
|
366 |
'desc_tip' => true,
|
367 |
'class' => 'wc-enhanced-select',
|
368 |
-
'css' => 'min-width:300px;'
|
|
|
369 |
),
|
370 |
45 => array(
|
371 |
'title' => __( 'Enable for Guests', 'customer-reviews-woocommerce' ),
|
372 |
'desc' => __( 'Enable sending of review reminders to customers who place orders without an account (guest checkout). It is recommended to enable this checkbox, if you allow customers to place orders without creating an account on your site.', 'customer-reviews-woocommerce' ),
|
373 |
'id' => 'ivole_enable_for_guests',
|
374 |
'default' => 'yes',
|
375 |
-
'type' => 'checkbox'
|
|
|
376 |
),
|
377 |
50 => array(
|
378 |
'title' => __( 'Reminders Scheduler', 'customer-reviews-woocommerce' ),
|
@@ -383,21 +390,24 @@ if ( ! class_exists( 'CR_Review_Reminder_Settings' ) ):
|
|
383 |
'desc_tip' => true,
|
384 |
'class' => 'wc-enhanced-select',
|
385 |
'css' => 'min-width:300px;',
|
386 |
-
'options' => $scheduler_options
|
|
|
387 |
),
|
388 |
55 => array(
|
389 |
'title' => __( 'Enable Manual Reminders', 'customer-reviews-woocommerce' ),
|
390 |
'desc' => sprintf( __( 'Enable manual sending of follow-up emails with a reminder to submit a review. Manual reminders can be sent for completed orders from %1$sOrders%2$s page after enabling this option.', 'customer-reviews-woocommerce' ), '<a href="' . admin_url( 'edit.php?post_type=shop_order' ) . '">', '</a>' ),
|
391 |
'id' => 'ivole_enable_manual',
|
392 |
'default' => 'yes',
|
393 |
-
'type' => 'checkbox'
|
|
|
394 |
),
|
395 |
60 => array(
|
396 |
'title' => __( 'Limit Number of Reminders', 'customer-reviews-woocommerce' ),
|
397 |
'desc' => __( 'Enable this checkbox to make sure that no more than one review reminder is sent for each order.', 'customer-reviews-woocommerce' ),
|
398 |
'id' => 'ivole_limit_reminders',
|
399 |
'default' => 'yes',
|
400 |
-
'type' => 'checkbox'
|
|
|
401 |
),
|
402 |
65 => array(
|
403 |
'title' => __( 'Customer Consent', 'customer-reviews-woocommerce' ),
|
@@ -421,21 +431,24 @@ if ( ! class_exists( 'CR_Review_Reminder_Settings' ) ):
|
|
421 |
'desc' => __( 'By default, review reminders are sent to billing emails provided by customers during checkout. If you enable this option, the plugin will check if customers have accounts on your website, and review reminders will be sent to emails associated with their accounts. It is recommended to keep this option disabled.', 'customer-reviews-woocommerce' ),
|
422 |
'id' => 'ivole_registered_customers',
|
423 |
'default' => 'no',
|
424 |
-
'type' => 'checkbox'
|
|
|
425 |
),
|
426 |
80 => array(
|
427 |
'title' => __( 'Moderation of Reviews', 'customer-reviews-woocommerce' ),
|
428 |
'desc' => __( 'Enable manual moderation of reviews submitted by your verified customers. This setting applies only to reviews submitted in response to reminders sent by this plugin.', 'customer-reviews-woocommerce' ),
|
429 |
'id' => 'ivole_enable_moderation',
|
430 |
'default' => 'no',
|
431 |
-
'type' => 'checkbox'
|
|
|
432 |
),
|
433 |
85 => array(
|
434 |
'title' => __( 'Exclude Free Products', 'customer-reviews-woocommerce' ),
|
435 |
'desc' => __( 'Enable this checkbox to exclude free products from review invitations.', 'customer-reviews-woocommerce' ),
|
436 |
'id' => 'ivole_exclude_free_products',
|
437 |
'default' => 'no',
|
438 |
-
'type' => 'checkbox'
|
|
|
439 |
),
|
440 |
90 => array(
|
441 |
'title' => __( 'Shop Name', 'customer-reviews-woocommerce' ),
|
@@ -468,7 +481,8 @@ if ( ! class_exists( 'CR_Review_Reminder_Settings' ) ):
|
|
468 |
'id' => 'ivole_language',
|
469 |
'class' => 'wc-enhanced-select',
|
470 |
'desc_tip' => true,
|
471 |
-
'options' => $available_languages
|
|
|
472 |
);
|
473 |
$this->settings[110] = array(
|
474 |
'type' => 'sectionend',
|
308 |
'desc' => __( 'Emails will be sent N days after order status is changed to the value specified in the field below. N is a sending delay that needs to be defined in this field.', 'customer-reviews-woocommerce' ),
|
309 |
'default' => 5,
|
310 |
'id' => 'ivole_delay',
|
311 |
+
'desc_tip' => true,
|
312 |
+
'autoload' => false
|
313 |
),
|
314 |
20 => array(
|
315 |
'title' => __( 'Order Status', 'customer-reviews-woocommerce' ),
|
320 |
'desc_tip' => true,
|
321 |
'class' => 'wc-enhanced-select',
|
322 |
'css' => 'min-width:300px;',
|
323 |
+
'options' => $order_statuses,
|
324 |
+
'autoload' => false
|
325 |
),
|
326 |
25 => array(
|
327 |
'title' => __( 'Enable for', 'customer-reviews-woocommerce' ),
|
335 |
'options' => array(
|
336 |
'all' => __( 'All Categories', 'customer-reviews-woocommerce' ),
|
337 |
'categories' => __( 'Specific Categories', 'customer-reviews-woocommerce' )
|
338 |
+
),
|
339 |
+
'autoload' => false
|
340 |
),
|
341 |
30 => array(
|
342 |
'title' => __( 'Categories', 'customer-reviews-woocommerce' ),
|
345 |
'id' => 'ivole_enabled_categories',
|
346 |
'desc_tip' => true,
|
347 |
'class' => 'wc-enhanced-select',
|
348 |
+
'css' => 'min-width:300px;',
|
349 |
+
'autoload' => false
|
350 |
),
|
351 |
35 => array(
|
352 |
'title' => __( 'Enable for Roles', 'customer-reviews-woocommerce' ),
|
360 |
'options' => array(
|
361 |
'all' => __( 'All Roles', 'customer-reviews-woocommerce' ),
|
362 |
'roles' => __( 'Specific Roles', 'customer-reviews-woocommerce' )
|
363 |
+
),
|
364 |
+
'autoload' => false
|
365 |
),
|
366 |
40 => array(
|
367 |
'title' => __( 'Roles', 'customer-reviews-woocommerce' ),
|
370 |
'id' => 'ivole_enabled_roles',
|
371 |
'desc_tip' => true,
|
372 |
'class' => 'wc-enhanced-select',
|
373 |
+
'css' => 'min-width:300px;',
|
374 |
+
'autoload' => false
|
375 |
),
|
376 |
45 => array(
|
377 |
'title' => __( 'Enable for Guests', 'customer-reviews-woocommerce' ),
|
378 |
'desc' => __( 'Enable sending of review reminders to customers who place orders without an account (guest checkout). It is recommended to enable this checkbox, if you allow customers to place orders without creating an account on your site.', 'customer-reviews-woocommerce' ),
|
379 |
'id' => 'ivole_enable_for_guests',
|
380 |
'default' => 'yes',
|
381 |
+
'type' => 'checkbox',
|
382 |
+
'autoload' => false
|
383 |
),
|
384 |
50 => array(
|
385 |
'title' => __( 'Reminders Scheduler', 'customer-reviews-woocommerce' ),
|
390 |
'desc_tip' => true,
|
391 |
'class' => 'wc-enhanced-select',
|
392 |
'css' => 'min-width:300px;',
|
393 |
+
'options' => $scheduler_options,
|
394 |
+
'autoload' => false
|
395 |
),
|
396 |
55 => array(
|
397 |
'title' => __( 'Enable Manual Reminders', 'customer-reviews-woocommerce' ),
|
398 |
'desc' => sprintf( __( 'Enable manual sending of follow-up emails with a reminder to submit a review. Manual reminders can be sent for completed orders from %1$sOrders%2$s page after enabling this option.', 'customer-reviews-woocommerce' ), '<a href="' . admin_url( 'edit.php?post_type=shop_order' ) . '">', '</a>' ),
|
399 |
'id' => 'ivole_enable_manual',
|
400 |
'default' => 'yes',
|
401 |
+
'type' => 'checkbox',
|
402 |
+
'autoload' => false
|
403 |
),
|
404 |
60 => array(
|
405 |
'title' => __( 'Limit Number of Reminders', 'customer-reviews-woocommerce' ),
|
406 |
'desc' => __( 'Enable this checkbox to make sure that no more than one review reminder is sent for each order.', 'customer-reviews-woocommerce' ),
|
407 |
'id' => 'ivole_limit_reminders',
|
408 |
'default' => 'yes',
|
409 |
+
'type' => 'checkbox',
|
410 |
+
'autoload' => false
|
411 |
),
|
412 |
65 => array(
|
413 |
'title' => __( 'Customer Consent', 'customer-reviews-woocommerce' ),
|
431 |
'desc' => __( 'By default, review reminders are sent to billing emails provided by customers during checkout. If you enable this option, the plugin will check if customers have accounts on your website, and review reminders will be sent to emails associated with their accounts. It is recommended to keep this option disabled.', 'customer-reviews-woocommerce' ),
|
432 |
'id' => 'ivole_registered_customers',
|
433 |
'default' => 'no',
|
434 |
+
'type' => 'checkbox',
|
435 |
+
'autoload' => false
|
436 |
),
|
437 |
80 => array(
|
438 |
'title' => __( 'Moderation of Reviews', 'customer-reviews-woocommerce' ),
|
439 |
'desc' => __( 'Enable manual moderation of reviews submitted by your verified customers. This setting applies only to reviews submitted in response to reminders sent by this plugin.', 'customer-reviews-woocommerce' ),
|
440 |
'id' => 'ivole_enable_moderation',
|
441 |
'default' => 'no',
|
442 |
+
'type' => 'checkbox',
|
443 |
+
'autoload' => false
|
444 |
),
|
445 |
85 => array(
|
446 |
'title' => __( 'Exclude Free Products', 'customer-reviews-woocommerce' ),
|
447 |
'desc' => __( 'Enable this checkbox to exclude free products from review invitations.', 'customer-reviews-woocommerce' ),
|
448 |
'id' => 'ivole_exclude_free_products',
|
449 |
'default' => 'no',
|
450 |
+
'type' => 'checkbox',
|
451 |
+
'autoload' => false
|
452 |
),
|
453 |
90 => array(
|
454 |
'title' => __( 'Shop Name', 'customer-reviews-woocommerce' ),
|
481 |
'id' => 'ivole_language',
|
482 |
'class' => 'wc-enhanced-select',
|
483 |
'desc_tip' => true,
|
484 |
+
'options' => $available_languages,
|
485 |
+
'autoload' => false
|
486 |
);
|
487 |
$this->settings[110] = array(
|
488 |
'type' => 'sectionend',
|
ivole.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
Plugin Name: Customer Reviews for WooCommerce
|
4 |
Description: Customer Reviews for WooCommerce plugin helps you get more customer reviews for your shop by sending automated reminders and coupons.
|
5 |
Plugin URI: https://wordpress.org/plugins/customer-reviews-woocommerce/
|
6 |
-
Version: 5.
|
7 |
Author: CusRev
|
8 |
Author URI: https://www.cusrev.com/business/
|
9 |
Text Domain: customer-reviews-woocommerce
|
3 |
Plugin Name: Customer Reviews for WooCommerce
|
4 |
Description: Customer Reviews for WooCommerce plugin helps you get more customer reviews for your shop by sending automated reminders and coupons.
|
5 |
Plugin URI: https://wordpress.org/plugins/customer-reviews-woocommerce/
|
6 |
+
Version: 5.7.0
|
7 |
Author: CusRev
|
8 |
Author URI: https://www.cusrev.com/business/
|
9 |
Text Domain: customer-reviews-woocommerce
|
readme.txt
CHANGED
@@ -3,7 +3,7 @@ Contributors: ivole
|
|
3 |
Tags: woocommerce, review plugin, review reminder, customer reviews, review for discount
|
4 |
Requires at least: 4.5
|
5 |
Tested up to: 6.1
|
6 |
-
Stable tag: 5.
|
7 |
License: GPLv3 or later
|
8 |
License URI: https://www.gnu.org/licenses/gpl.html
|
9 |
|
@@ -218,6 +218,8 @@ If you would like to change how reviews are sorted on product pages, it is possi
|
|
218 |
|
219 |
== Changelog ==
|
220 |
|
|
|
|
|
221 |
= 5.6.5 =
|
222 |
* Bug fixes and minor improvements
|
223 |
= 5.6.4 =
|
3 |
Tags: woocommerce, review plugin, review reminder, customer reviews, review for discount
|
4 |
Requires at least: 4.5
|
5 |
Tested up to: 6.1
|
6 |
+
Stable tag: 5.7.0
|
7 |
License: GPLv3 or later
|
8 |
License URI: https://www.gnu.org/licenses/gpl.html
|
9 |
|
218 |
|
219 |
== Changelog ==
|
220 |
|
221 |
+
= 5.7.0 =
|
222 |
+
* Improvement: reduced the number of autoloaded options to improve performance
|
223 |
= 5.6.5 =
|
224 |
* Bug fixes and minor improvements
|
225 |
= 5.6.4 =
|