Version Description
Fixed a bug where an admin notice could be closed but the state was not being saved.
Download this release
Release Info
Developer | jorisverwater |
Plugin | Product Feed PRO for WooCommerce |
Version | 7.3.6 |
Comparing to | |
See all releases |
Code changes from version 7.3.5 to 7.3.6
- classes/class-activate.php +5 -4
- classes/class-deactivate-cleanup.php +1 -0
- classes/class-uninstall-cleanup.php +1 -0
- js/woosea_key.js +1 -1
- js/woosea_manage.js +2 -2
- readme.txt +7 -1
- woocommerce-sea.php +43 -13
classes/class-activate.php
CHANGED
@@ -1871,7 +1871,7 @@ class WooSEA_Activation {
|
|
1871 |
/**
|
1872 |
* Function for checking if license is valid
|
1873 |
*/
|
1874 |
-
|
1875 |
|
1876 |
if(!get_option("license_information")){
|
1877 |
|
@@ -1879,9 +1879,10 @@ class WooSEA_Activation {
|
|
1879 |
|
1880 |
$license_created = "";
|
1881 |
$license_valid = "false";
|
1882 |
-
$message = "Thank you for becoming a user of our product feed pro plugin
|
1883 |
-
|
1884 |
-
|
|
|
1885 |
|
1886 |
$license_information = array (
|
1887 |
'license_valid' => $license_valid,
|
1871 |
/**
|
1872 |
* Function for checking if license is valid
|
1873 |
*/
|
1874 |
+
if (!wp_next_scheduled( 'woosea_check_license' ) ) {
|
1875 |
|
1876 |
if(!get_option("license_information")){
|
1877 |
|
1879 |
|
1880 |
$license_created = "";
|
1881 |
$license_valid = "false";
|
1882 |
+
$message = "Thank you for becoming a user of our <strong>product feed pro for WooCommerce plugin</strong>, much appreciated! Some of the features of this plugin have been locked as you are using the free version of this plugin. The added extra fields such as Brand and GTIN, WPML support, Aelia currency switcher support and the WooCommerce structured data bug fix are Elite features of this plugin. You can get <strong><a href=\"https://adtribes.io/pro-vs-elite/?utm_source=$domain&utm_medium=plugin&utm_campaign=upgrade-elite\" target=\"_blank\">your license key here</a></strong>.";
|
1883 |
+
//$message_type = "notice notice-info is-dismissible";
|
1884 |
+
$message_type = "updated woocommerce-message is-dismissible";
|
1885 |
+
$notice = "true";
|
1886 |
|
1887 |
$license_information = array (
|
1888 |
'license_valid' => $license_valid,
|
classes/class-deactivate-cleanup.php
CHANGED
@@ -9,5 +9,6 @@ class WooSEA_Deactivate_Cleanup {
|
|
9 |
wp_clear_scheduled_hook('woosea_cron_hook');
|
10 |
wp_clear_scheduled_hook('woosea_check_license');
|
11 |
delete_option('woosea_getelite_notification');
|
|
|
12 |
}
|
13 |
}
|
9 |
wp_clear_scheduled_hook('woosea_cron_hook');
|
10 |
wp_clear_scheduled_hook('woosea_check_license');
|
11 |
delete_option('woosea_getelite_notification');
|
12 |
+
delete_option('woosea_license_notification_closed'); // This one is new
|
13 |
}
|
14 |
}
|
classes/class-uninstall-cleanup.php
CHANGED
@@ -12,5 +12,6 @@ class WooSEA_Uninstall_Cleanup {
|
|
12 |
delete_option( 'license_information' );
|
13 |
delete_option( 'cron_projects' );
|
14 |
delete_option('woosea_getelite_notification');
|
|
|
15 |
}
|
16 |
}
|
12 |
delete_option( 'license_information' );
|
13 |
delete_option( 'cron_projects' );
|
14 |
delete_option('woosea_getelite_notification');
|
15 |
+
delete_option('woosea_license_notification_closed'); // This one is new
|
16 |
}
|
17 |
}
|
js/woosea_key.js
CHANGED
@@ -27,7 +27,7 @@ jQuery(document).ready(function($) {
|
|
27 |
var license_key = $('#license-key').val();
|
28 |
|
29 |
jQuery.ajax({
|
30 |
-
url: 'https://www.adtribes.io/check/license.php?key=' + license_key + '&email=' + license_email + '&domain=' + root_domain + '&version=7.3.
|
31 |
jsonp: 'callback',
|
32 |
dataType: 'jsonp',
|
33 |
type: 'GET',
|
27 |
var license_key = $('#license-key').val();
|
28 |
|
29 |
jQuery.ajax({
|
30 |
+
url: 'https://www.adtribes.io/check/license.php?key=' + license_key + '&email=' + license_email + '&domain=' + root_domain + '&version=7.3.6',
|
31 |
jsonp: 'callback',
|
32 |
dataType: 'jsonp',
|
33 |
type: 'GET',
|
js/woosea_manage.js
CHANGED
@@ -46,8 +46,8 @@ jQuery(document).ready(function($) {
|
|
46 |
|
47 |
});
|
48 |
|
49 |
-
$(".
|
50 |
-
$(".
|
51 |
|
52 |
jQuery.ajax({
|
53 |
method: "POST",
|
46 |
|
47 |
});
|
48 |
|
49 |
+
$(".license_notification").click(function(){
|
50 |
+
$(".license_notification").remove();
|
51 |
|
52 |
jQuery.ajax({
|
53 |
method: "POST",
|
readme.txt
CHANGED
@@ -5,7 +5,7 @@ License URI: http://www.gnu.org/licenses/gpl.html
|
|
5 |
Tags: Product Feed, Google Shopping, Google Shopping Feed, WooCommerce Product Feed, WooCommerce Product Feed PRO, Bing Shopping, Bing product feed, Bing remarking, Google Merchant Feed, Google DRM Feed, Google Dynamic Remarketing Feed, Facebook feed, Google feed, Bing feed, Facebook Product Feed, Facebook Dynamic remarketing, Data Feed, WooCommerce Feed, XML product feed, CSV product feed, TSV, TXT product feed, comparison shopping engines, comparison shopping websites, vergelijk.nl, vergelijk.be, vertaa.fi, beslist.nl, kieskeurig.nl, bol.com, raketten, pricerunner, pricegrabber, Buy, leGuide, Kelkoo, Twenga, Yandex, Etsy, Dealtime, Shopzilla, Billiger, Google Product Review feed
|
6 |
Requires at least: 4.5
|
7 |
Tested up to: 5.3
|
8 |
-
Stable tag: 7.3.
|
9 |
|
10 |
== Description ==
|
11 |
|
@@ -312,6 +312,9 @@ Questions left or unanswered? Please do not hesitate to contact us at support@ad
|
|
312 |
|
313 |
=== Changelog ===
|
314 |
|
|
|
|
|
|
|
315 |
= 7.3.5 (2020-01-29) =
|
316 |
* Fixed a bug where "empty" rules on sale prices did not work as expected. This issue has been fixed.
|
317 |
|
@@ -2334,6 +2337,9 @@ Questions left or unanswered? Please do not hesitate to contact us at support@ad
|
|
2334 |
|
2335 |
== Upgrade Notice ==
|
2336 |
|
|
|
|
|
|
|
2337 |
= 7.3.5 =
|
2338 |
Fixed a bug where "empty" rules on sale prices did not work as expected. This issue has been fixed.
|
2339 |
|
5 |
Tags: Product Feed, Google Shopping, Google Shopping Feed, WooCommerce Product Feed, WooCommerce Product Feed PRO, Bing Shopping, Bing product feed, Bing remarking, Google Merchant Feed, Google DRM Feed, Google Dynamic Remarketing Feed, Facebook feed, Google feed, Bing feed, Facebook Product Feed, Facebook Dynamic remarketing, Data Feed, WooCommerce Feed, XML product feed, CSV product feed, TSV, TXT product feed, comparison shopping engines, comparison shopping websites, vergelijk.nl, vergelijk.be, vertaa.fi, beslist.nl, kieskeurig.nl, bol.com, raketten, pricerunner, pricegrabber, Buy, leGuide, Kelkoo, Twenga, Yandex, Etsy, Dealtime, Shopzilla, Billiger, Google Product Review feed
|
6 |
Requires at least: 4.5
|
7 |
Tested up to: 5.3
|
8 |
+
Stable tag: 7.3.6
|
9 |
|
10 |
== Description ==
|
11 |
|
312 |
|
313 |
=== Changelog ===
|
314 |
|
315 |
+
= 7.3.6 (2020-01-30) =
|
316 |
+
* Fixed a bug where an admin notice could be closed but the state was not being saved.
|
317 |
+
|
318 |
= 7.3.5 (2020-01-29) =
|
319 |
* Fixed a bug where "empty" rules on sale prices did not work as expected. This issue has been fixed.
|
320 |
|
2337 |
|
2338 |
== Upgrade Notice ==
|
2339 |
|
2340 |
+
= 7.3.6 =
|
2341 |
+
Fixed a bug where an admin notice could be closed but the state was not being saved.
|
2342 |
+
|
2343 |
= 7.3.5 =
|
2344 |
Fixed a bug where "empty" rules on sale prices did not work as expected. This issue has been fixed.
|
2345 |
|
woocommerce-sea.php
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?php
|
2 |
/**
|
3 |
* Plugin Name: Product Feed PRO for WooCommerce
|
4 |
-
* Version: 7.3.
|
5 |
* Plugin URI: https://www.adtribes.io/support/?utm_source=wpadmin&utm_medium=plugin&utm_campaign=woosea_product_feed_pro
|
6 |
* Description: Configure and maintain your WooCommerce product feeds for Google Shopping, Facebook, Remarketing, Bing, Yandex, Comparison shopping websites and over a 100 channels more.
|
7 |
* Author: AdTribes.io
|
@@ -48,7 +48,7 @@ if (!defined('ABSPATH')) {
|
|
48 |
* Plugin versionnumber, please do not override.
|
49 |
* Define some constants
|
50 |
*/
|
51 |
-
define( 'WOOCOMMERCESEA_PLUGIN_VERSION', '7.3.
|
52 |
define( 'WOOCOMMERCESEA_PLUGIN_NAME', 'woocommerce-product-feed-pro' );
|
53 |
define( 'WOOCOMMERCESEA_PLUGIN_NAME_SHORT', 'woo-product-feed-pro' );
|
54 |
|
@@ -130,6 +130,7 @@ function woosea_scripts($hook) {
|
|
130 |
// JS for managing keys
|
131 |
wp_register_script( 'woosea_key-js', plugin_dir_url( __FILE__ ) . 'js/woosea_key.js', '',WOOCOMMERCESEA_PLUGIN_VERSION, true );
|
132 |
wp_enqueue_script( 'woosea_key-js' );
|
|
|
133 |
}
|
134 |
// JS for manage projects page
|
135 |
wp_register_script( 'woosea_manage-js', plugin_dir_url( __FILE__ ) . 'js/woosea_manage.js', '',WOOCOMMERCESEA_PLUGIN_VERSION, true );
|
@@ -726,25 +727,54 @@ function activate_woosea_feed(){
|
|
726 |
register_activation_hook(__FILE__, 'activate_woosea_feed');
|
727 |
|
728 |
/**
|
729 |
-
*
|
730 |
**/
|
731 |
function woosea_license_notice(){
|
732 |
$license_information = get_option( 'license_information' );
|
733 |
$license_notification = get_option( 'woosea_license_notification_closed' );
|
734 |
$screen = get_current_screen();
|
|
|
|
|
735 |
|
736 |
-
|
737 |
-
|
738 |
-
|
739 |
-
|
740 |
-
|
741 |
-
|
742 |
-
|
743 |
-
|
744 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
745 |
}
|
746 |
add_action('admin_notices', 'woosea_license_notice');
|
747 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
748 |
/**
|
749 |
* Close the get Elite notification
|
750 |
**/
|
@@ -3740,7 +3770,7 @@ function woosea_license_valid(){
|
|
3740 |
|
3741 |
if(!empty($license_information['license_key'])){
|
3742 |
$curl = curl_init();
|
3743 |
-
$url = "https://www.adtribes.io/check/license.php?key=$license_information[license_key]&email=$license_information[license_email]&domain=$domain&version=7.3.
|
3744 |
|
3745 |
curl_setopt_array($curl, array(
|
3746 |
CURLOPT_RETURNTRANSFER => 1,
|
1 |
<?php
|
2 |
/**
|
3 |
* Plugin Name: Product Feed PRO for WooCommerce
|
4 |
+
* Version: 7.3.6
|
5 |
* Plugin URI: https://www.adtribes.io/support/?utm_source=wpadmin&utm_medium=plugin&utm_campaign=woosea_product_feed_pro
|
6 |
* Description: Configure and maintain your WooCommerce product feeds for Google Shopping, Facebook, Remarketing, Bing, Yandex, Comparison shopping websites and over a 100 channels more.
|
7 |
* Author: AdTribes.io
|
48 |
* Plugin versionnumber, please do not override.
|
49 |
* Define some constants
|
50 |
*/
|
51 |
+
define( 'WOOCOMMERCESEA_PLUGIN_VERSION', '7.3.6' );
|
52 |
define( 'WOOCOMMERCESEA_PLUGIN_NAME', 'woocommerce-product-feed-pro' );
|
53 |
define( 'WOOCOMMERCESEA_PLUGIN_NAME_SHORT', 'woo-product-feed-pro' );
|
54 |
|
130 |
// JS for managing keys
|
131 |
wp_register_script( 'woosea_key-js', plugin_dir_url( __FILE__ ) . 'js/woosea_key.js', '',WOOCOMMERCESEA_PLUGIN_VERSION, true );
|
132 |
wp_enqueue_script( 'woosea_key-js' );
|
133 |
+
|
134 |
}
|
135 |
// JS for manage projects page
|
136 |
wp_register_script( 'woosea_manage-js', plugin_dir_url( __FILE__ ) . 'js/woosea_manage.js', '',WOOCOMMERCESEA_PLUGIN_VERSION, true );
|
727 |
register_activation_hook(__FILE__, 'activate_woosea_feed');
|
728 |
|
729 |
/**
|
730 |
+
* Show the license notification
|
731 |
**/
|
732 |
function woosea_license_notice(){
|
733 |
$license_information = get_option( 'license_information' );
|
734 |
$license_notification = get_option( 'woosea_license_notification_closed' );
|
735 |
$screen = get_current_screen();
|
736 |
+
$current_date = strtotime(date( 'd-m-Y' ));
|
737 |
+
$off_date = strtotime($license_notification['timestamp']);
|
738 |
|
739 |
+
// Show notification again after 30 days
|
740 |
+
$diff_days = 2592000;
|
741 |
+
$diff = ($current_date - $off_date);
|
742 |
+
|
743 |
+
// 30 days have passed
|
744 |
+
if($diff > $diff_days){
|
745 |
+
$license_notification['show'] = "yes";
|
746 |
+
}
|
747 |
+
|
748 |
+
// Add a check, notification should not show in the plugin pages itself as it will duplicate notices
|
749 |
+
$page = basename($_SERVER['REQUEST_URI']);
|
750 |
+
|
751 |
+
if (!preg_match("/woo-product-feed-pro|woosea_manage_feed|woosea_manage_settings/i",$page)){
|
752 |
+
|
753 |
+
if((isset($license_information['notice'])) and ($license_information['notice'] == "true") and ($license_notification['show'] == "yes")){
|
754 |
+
?>
|
755 |
+
<div class="<?php print "$license_information[message_type]"; ?> license_notification">
|
756 |
+
<p><?php _e( $license_information['message'], 'sample-text-domain' ); ?></p>
|
757 |
+
</div>
|
758 |
+
<?php
|
759 |
+
}
|
760 |
+
}
|
761 |
}
|
762 |
add_action('admin_notices', 'woosea_license_notice');
|
763 |
|
764 |
+
/**
|
765 |
+
* Close the license notification
|
766 |
+
**/
|
767 |
+
function woosea_license_notification(){
|
768 |
+
|
769 |
+
$get_admin_notice = array(
|
770 |
+
"show" => "no",
|
771 |
+
"timestamp" => date( 'd-m-Y' )
|
772 |
+
);
|
773 |
+
|
774 |
+
update_option('woosea_license_notification_closed', $get_admin_notice);
|
775 |
+
}
|
776 |
+
add_action('wp_ajax_woosea_license_notification', 'woosea_license_notification');
|
777 |
+
|
778 |
/**
|
779 |
* Close the get Elite notification
|
780 |
**/
|
3770 |
|
3771 |
if(!empty($license_information['license_key'])){
|
3772 |
$curl = curl_init();
|
3773 |
+
$url = "https://www.adtribes.io/check/license.php?key=$license_information[license_key]&email=$license_information[license_email]&domain=$domain&version=7.3.6";
|
3774 |
|
3775 |
curl_setopt_array($curl, array(
|
3776 |
CURLOPT_RETURNTRANSFER => 1,
|