Version Description
- Tested up to WordPress 4.8
- Improve: change permission from activate_plugins to manage_options for the plugin's settings
- Bugfix: CURLOPT_FOLLOWLOCATION for curl used only with open_basedir and safe_mode disable
- Bugfix: cURL proxy fix
Download this release
Release Info
Developer | widgetpack |
Plugin | Google Reviews Widget |
Version | 1.5.6 |
Comparing to | |
See all releases |
Code changes from version 1.5.5 to 1.5.6
- api/urlopen.php +10 -1
- grw-reviews.php +1 -1
- grw-setting.php +1 -1
- grw.php +18 -3
- readme.txt +8 -2
- static/js/wpac-time.js +5 -4
api/urlopen.php
CHANGED
@@ -71,10 +71,19 @@ if (!function_exists('rplg_urlopen')) {
|
|
71 |
}
|
72 |
curl_setopt_array($c, $c_options);
|
73 |
|
74 |
-
|
|
|
|
|
|
|
75 |
curl_setopt($c, CURLOPT_SSL_VERIFYPEER, false);
|
76 |
|
77 |
$data = curl_exec($c);
|
|
|
|
|
|
|
|
|
|
|
|
|
78 |
list($resp_headers, $response['data']) = explode("\r\n\r\n", $data, 2);
|
79 |
|
80 |
$response['headers'] = _rplg_get_response_headers($resp_headers, $response);
|
71 |
}
|
72 |
curl_setopt_array($c, $c_options);
|
73 |
|
74 |
+
$open_basedir = ini_get('open_basedir');
|
75 |
+
if(empty($open_basedir) && filter_var(ini_get('safe_mode'), FILTER_VALIDATE_BOOLEAN) === false) {
|
76 |
+
curl_setopt($c, CURLOPT_FOLLOWLOCATION, true);
|
77 |
+
}
|
78 |
curl_setopt($c, CURLOPT_SSL_VERIFYPEER, false);
|
79 |
|
80 |
$data = curl_exec($c);
|
81 |
+
|
82 |
+
// cURL automatically handles Proxy rewrites, remove the "HTTP/1.0 200 Connection established" string
|
83 |
+
if (stripos($data, "HTTP/1.0 200 Connection established\r\n\r\n") !== false) {
|
84 |
+
$data = str_ireplace("HTTP/1.0 200 Connection established\r\n\r\n", '', $data);
|
85 |
+
}
|
86 |
+
|
87 |
list($resp_headers, $response['data']) = explode("\r\n\r\n", $data, 2);
|
88 |
|
89 |
$response['headers'] = _rplg_get_response_headers($resp_headers, $response);
|
grw-reviews.php
CHANGED
@@ -65,7 +65,7 @@ $rating = number_format((float)$rating, 1, '.', '');
|
|
65 |
<img src="<?php echo GRW_PLUGIN_URL; ?>/static/img/powered_by_google_on_<?php if ($dark_theme) { ?>non_<?php } ?>white.png" alt="powered by Google">
|
66 |
</div>
|
67 |
</div>
|
68 |
-
<img src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7" onload="grw_badge_init(this.parentNode);" style="display:none">
|
69 |
</div>
|
70 |
|
71 |
<?php } else { ?>
|
65 |
<img src="<?php echo GRW_PLUGIN_URL; ?>/static/img/powered_by_google_on_<?php if ($dark_theme) { ?>non_<?php } ?>white.png" alt="powered by Google">
|
66 |
</div>
|
67 |
</div>
|
68 |
+
<img src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7" onload="(function(el) { document.addEventListener('DOMContentLoaded', function() { grw_badge_init(el); }); })(this.parentNode);" style="display:none">
|
69 |
</div>
|
70 |
|
71 |
<?php } else { ?>
|
grw-setting.php
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
<?php
|
2 |
|
3 |
-
if (!current_user_can('
|
4 |
die('The account you\'re logged in to doesn\'t have permission to access this page.');
|
5 |
}
|
6 |
|
1 |
<?php
|
2 |
|
3 |
+
if (!current_user_can('manage_options')) {
|
4 |
die('The account you\'re logged in to doesn\'t have permission to access this page.');
|
5 |
}
|
6 |
|
grw.php
CHANGED
@@ -4,8 +4,8 @@ Plugin Name: Google Reviews Widget
|
|
4 |
Plugin URI: https://richplugins.com/google-reviews-pro-wordpress-plugin
|
5 |
Description: Instantly Google Places Reviews on your website to increase user confidence and SEO.
|
6 |
Author: RichPlugins <support@richplugins.com>
|
7 |
-
Version: 1.5.
|
8 |
-
Author URI: https://richplugins.com
|
9 |
*/
|
10 |
|
11 |
require(ABSPATH . 'wp-includes/version.php');
|
@@ -13,7 +13,7 @@ require(ABSPATH . 'wp-includes/version.php');
|
|
13 |
include_once(dirname(__FILE__) . '/api/urlopen.php');
|
14 |
include_once(dirname(__FILE__) . '/helper/debug.php');
|
15 |
|
16 |
-
define('GRW_VERSION', '1.5.
|
17 |
define('GRW_GOOGLE_PLACE_API', 'https://maps.googleapis.com/maps/api/place/');
|
18 |
define('GRW_GOOGLE_AVATAR', 'https://lh3.googleusercontent.com/-8hepWJzFXpE/AAAAAAAAAAI/AAAAAAAAAAA/I80WzYfIxCQ/s64-c/114307615494839964028.jpg');
|
19 |
define('GRW_PLUGIN_URL', plugins_url(basename(plugin_dir_path(__FILE__ )), basename(__FILE__)));
|
@@ -64,6 +64,21 @@ function grw_plugin_action_links($links, $file) {
|
|
64 |
}
|
65 |
add_filter('plugin_action_links', 'grw_plugin_action_links', 10, 2);
|
66 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
67 |
/*-------------------------------- Database --------------------------------*/
|
68 |
function grw_activation() {
|
69 |
if (grw_does_need_update()) {
|
4 |
Plugin URI: https://richplugins.com/google-reviews-pro-wordpress-plugin
|
5 |
Description: Instantly Google Places Reviews on your website to increase user confidence and SEO.
|
6 |
Author: RichPlugins <support@richplugins.com>
|
7 |
+
Version: 1.5.6
|
8 |
+
Author URI: https://richplugins.com
|
9 |
*/
|
10 |
|
11 |
require(ABSPATH . 'wp-includes/version.php');
|
13 |
include_once(dirname(__FILE__) . '/api/urlopen.php');
|
14 |
include_once(dirname(__FILE__) . '/helper/debug.php');
|
15 |
|
16 |
+
define('GRW_VERSION', '1.5.6');
|
17 |
define('GRW_GOOGLE_PLACE_API', 'https://maps.googleapis.com/maps/api/place/');
|
18 |
define('GRW_GOOGLE_AVATAR', 'https://lh3.googleusercontent.com/-8hepWJzFXpE/AAAAAAAAAAI/AAAAAAAAAAA/I80WzYfIxCQ/s64-c/114307615494839964028.jpg');
|
19 |
define('GRW_PLUGIN_URL', plugins_url(basename(plugin_dir_path(__FILE__ )), basename(__FILE__)));
|
64 |
}
|
65 |
add_filter('plugin_action_links', 'grw_plugin_action_links', 10, 2);
|
66 |
|
67 |
+
/*-------------------------------- Row Meta --------------------------------*/
|
68 |
+
function grw_plugin_row_meta($input, $file) {
|
69 |
+
if ($file != plugin_basename( __FILE__ )) {
|
70 |
+
return $input;
|
71 |
+
}
|
72 |
+
|
73 |
+
$links = array(
|
74 |
+
'<a href="' . esc_url('https://richplugins.com/documentation') . '" target="_blank">' . grw_i('View Documentation') . '</a>',
|
75 |
+
'<a href="' . esc_url('https://richplugins.com/google-reviews-pro-wordpress-plugin') . '" target="_blank">' . grw_i('Upgrade to Pro') . ' »</a>',
|
76 |
+
);
|
77 |
+
$input = array_merge($input, $links);
|
78 |
+
return $input;
|
79 |
+
}
|
80 |
+
add_filter('plugin_row_meta', 'grw_plugin_row_meta', 10, 2);
|
81 |
+
|
82 |
/*-------------------------------- Database --------------------------------*/
|
83 |
function grw_activation() {
|
84 |
if (grw_does_need_update()) {
|
readme.txt
CHANGED
@@ -3,8 +3,8 @@ Contributors: richplugins
|
|
3 |
Donate link: https://richplugins.com/google-reviews-pro-wordpress-plugin
|
4 |
Tags: google, reviews, google reviews, google places, google places reviews, testimonials, google review widget, google business reviews, slider, google review, review, google place review, google map reviews, google reviews pro, facebook reviews, facebook page reviews, yelp reviews, yelp business reviews
|
5 |
Requires at least: 2.8
|
6 |
-
Tested up to: 4.
|
7 |
-
Stable tag: 1.5.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -73,6 +73,12 @@ Why limit your reviews to just Google Reviews? Check out our other free business
|
|
73 |
|
74 |
== Changelog ==
|
75 |
|
|
|
|
|
|
|
|
|
|
|
|
|
76 |
= 1.5.5 =
|
77 |
* Update description
|
78 |
* Bugfix: use default json_encode if it's possible
|
3 |
Donate link: https://richplugins.com/google-reviews-pro-wordpress-plugin
|
4 |
Tags: google, reviews, google reviews, google places, google places reviews, testimonials, google review widget, google business reviews, slider, google review, review, google place review, google map reviews, google reviews pro, facebook reviews, facebook page reviews, yelp reviews, yelp business reviews
|
5 |
Requires at least: 2.8
|
6 |
+
Tested up to: 4.8
|
7 |
+
Stable tag: 1.5.6
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
73 |
|
74 |
== Changelog ==
|
75 |
|
76 |
+
= 1.5.6 =
|
77 |
+
* Tested up to WordPress 4.8
|
78 |
+
* Improve: change permission from activate_plugins to manage_options for the plugin's settings
|
79 |
+
* Bugfix: CURLOPT_FOLLOWLOCATION for curl used only with open_basedir and safe_mode disable
|
80 |
+
* Bugfix: cURL proxy fix
|
81 |
+
|
82 |
= 1.5.5 =
|
83 |
* Update description
|
84 |
* Bugfix: use default json_encode if it's possible
|
static/js/wpac-time.js
CHANGED
@@ -30,7 +30,8 @@ Math.round(a/30)+" Monaten"},year:"vor einem Jahr",years:function(a){return"vor
|
|
30 |
"\u0445\u0432\u0456\u043b\u0456\u043d \u0442\u0430\u043c\u0443")},hour:"\u0433\u0430\u0434\u0437\u0456\u043d\u0443 \u0442\u0430\u043c\u0443",hours:function(a){return WPacTime.declineNum(Math.round(a),"\u0433\u0430\u0434\u0437\u0456\u043d\u0443 \u0442\u0430\u043c\u0443","\u0433\u0430\u0434\u0437\u0456\u043d\u044b \u0442\u0430\u043c\u0443","\u0433\u0430\u0434\u0437\u0456\u043d \u0442\u0430\u043c\u0443")},day:"\u0434\u0437\u0435\u043d\u044c \u0442\u0430\u043c\u0443",days:function(a){return WPacTime.declineNum(Math.round(a),
|
31 |
"\u0434\u0437\u0435\u043d\u044c \u0442\u0430\u043c\u0443","\u0434\u043d\u0456 \u0442\u0430\u043c\u0443","\u0434\u0437\u0451\u043d \u0442\u0430\u043c\u0443")},month:"\u043c\u0435\u0441\u044f\u0446 \u0442\u0430\u043c\u0443",months:function(a){return WPacTime.declineNum(Math.round(a/30),"\u043c\u0435\u0441\u044f\u0446 \u0442\u0430\u043c\u0443","\u043c\u0435\u0441\u044f\u0446\u0430 \u0442\u0430\u043c\u0443","\u043c\u0435\u0441\u044f\u0446\u0430\u045e \u0442\u0430\u043c\u0443")},year:"\u0433\u043e\u0434 \u0442\u0430\u043c\u0443",
|
32 |
years:function(a){return WPacTime.declineNum(Math.round(a),"\u0433\u043e\u0434 \u0442\u0430\u043c\u0443","\u0433\u0430\u0434\u044b \u0442\u0430\u043c\u0443","\u0433\u043e\u0434 \u0442\u0430\u043c\u0443")}},it:{second:"proprio ora",minute:"un minuto fa",minutes:function(a){return WPacTime.declineNum(Math.round(a),"un minuto fa","minuti fa","minuti fa")},hour:"un'ora fa",hours:function(a){return WPacTime.declineNum(Math.round(a),"un'ora fa","ore fa","ore fa")},day:"un giorno fa",days:function(a){return WPacTime.declineNum(Math.round(a),
|
33 |
-
"un giorno fa","giorni fa","giorni fa")},month:"un mese fa",months:function(a){return WPacTime.declineNum(Math.round(a/30),"un mese fa","mesi fa","mesi fa")},year:"un anno fa",years:function(a){return WPacTime.declineNum(Math.round(a),"un anno fa","anni fa","anni fa")}},
|
34 |
-
"
|
35 |
-
year:"
|
36 |
-
minute:"
|
|
30 |
"\u0445\u0432\u0456\u043b\u0456\u043d \u0442\u0430\u043c\u0443")},hour:"\u0433\u0430\u0434\u0437\u0456\u043d\u0443 \u0442\u0430\u043c\u0443",hours:function(a){return WPacTime.declineNum(Math.round(a),"\u0433\u0430\u0434\u0437\u0456\u043d\u0443 \u0442\u0430\u043c\u0443","\u0433\u0430\u0434\u0437\u0456\u043d\u044b \u0442\u0430\u043c\u0443","\u0433\u0430\u0434\u0437\u0456\u043d \u0442\u0430\u043c\u0443")},day:"\u0434\u0437\u0435\u043d\u044c \u0442\u0430\u043c\u0443",days:function(a){return WPacTime.declineNum(Math.round(a),
|
31 |
"\u0434\u0437\u0435\u043d\u044c \u0442\u0430\u043c\u0443","\u0434\u043d\u0456 \u0442\u0430\u043c\u0443","\u0434\u0437\u0451\u043d \u0442\u0430\u043c\u0443")},month:"\u043c\u0435\u0441\u044f\u0446 \u0442\u0430\u043c\u0443",months:function(a){return WPacTime.declineNum(Math.round(a/30),"\u043c\u0435\u0441\u044f\u0446 \u0442\u0430\u043c\u0443","\u043c\u0435\u0441\u044f\u0446\u0430 \u0442\u0430\u043c\u0443","\u043c\u0435\u0441\u044f\u0446\u0430\u045e \u0442\u0430\u043c\u0443")},year:"\u0433\u043e\u0434 \u0442\u0430\u043c\u0443",
|
32 |
years:function(a){return WPacTime.declineNum(Math.round(a),"\u0433\u043e\u0434 \u0442\u0430\u043c\u0443","\u0433\u0430\u0434\u044b \u0442\u0430\u043c\u0443","\u0433\u043e\u0434 \u0442\u0430\u043c\u0443")}},it:{second:"proprio ora",minute:"un minuto fa",minutes:function(a){return WPacTime.declineNum(Math.round(a),"un minuto fa","minuti fa","minuti fa")},hour:"un'ora fa",hours:function(a){return WPacTime.declineNum(Math.round(a),"un'ora fa","ore fa","ore fa")},day:"un giorno fa",days:function(a){return WPacTime.declineNum(Math.round(a),
|
33 |
+
"un giorno fa","giorni fa","giorni fa")},month:"un mese fa",months:function(a){return WPacTime.declineNum(Math.round(a/30),"un mese fa","mesi fa","mesi fa")},year:"un anno fa",years:function(a){return WPacTime.declineNum(Math.round(a),"un anno fa","anni fa","anni fa")}},tr:{second:"az \u00f6nce",minute:"dakika \u00f6nce",minutes:function(a){return Math.round(a)+" dakika \u00f6nce"},hour:"saat \u00f6nce",hours:function(a){return Math.round(a)+" saat \u00f6nce"},day:"g\u00fcn \u00f6nce",days:function(a){return Math.round(a)+
|
34 |
+
" g\u00fcn \u00f6nce"},month:"ay \u00f6nce",months:function(a){return Math.round(a/30)+" ay \u00f6nce"},year:"y\u0131l \u00f6nce",years:function(a){return Math.round(a)+" y\u0131l \u00f6nce"}},nb:{second:"n\u00e5 nettopp",minute:"ett minutt siden",minutes:function(a){return Math.round(a)+" minutter siden"},hour:"en time siden",hours:function(a){return Math.round(a)+" timer siden"},day:"en dag siden",days:function(a){return Math.round(a)+" dager siden"},month:"en m\u00e5ned siden",months:function(a){return Math.round(a/
|
35 |
+
30)+" m\u00e5neder siden"},year:"ett \u00e5r siden",years:function(a){return Math.round(a)+" \u00e5r siden"}},da:{second:"just now",minute:"minute ago",minutes:function(a){return Math.round(a)+" minutter siden"},hour:"hour ago",hours:function(a){return Math.round(a)+" timer siden"},day:"day ago",days:function(a){return Math.round(a)+" dage siden"},month:"month ago",months:function(a){return Math.round(a/30)+" m\u00e5neder siden"},year:"year ago",years:function(a){return Math.round(a)+" \u00e5r siden"}},
|
36 |
+
nl:{second:"zojuist",minute:"minuten geleden",minutes:function(a){return Math.round(a)+" minuten geleden"},hour:"uur geleden",hours:function(a){return Math.round(a)+" uur geleden"},day:"dagen geleden",days:function(a){return Math.round(a)+" dagen geleden"},month:"maand geleden",months:function(a){return Math.round(a/30)+" maanden geleden"},year:"jaar geleden",years:function(a){return Math.round(a)+" jaar geleden"}},ca:{second:"ara mateix",minute:"fa un minut",minutes:function(a){return"fa "+Math.round(a)+
|
37 |
+
" minuts"},hour:"fa una hora",hours:function(a){return"fa "+Math.round(a)+" hores"},day:"fa un dia",days:function(a){return"fa "+Math.round(a)+" dies"},month:"fa un mes",months:function(a){return"fa "+Math.round(a/30)+" mesos"},year:"fa un any",years:function(a){return"fa "+Math.round(a)+" anys"}}};
|