Version Description
- Added text domain and path for localization
- Bugfix: W3C compatibility
- Bugfix: Some fixes for fr_FR locale
Download this release
Release Info
Developer | widgetpack |
Plugin | Google Reviews Widget |
Version | 1.8.7 |
Comparing to | |
See all releases |
Code changes from version 1.8.6 to 1.8.7
- grw-reviews-helper.php +1 -1
- grw-reviews.php +12 -1
- grw.php +10 -5
- languages/grw-fr_FR.mo +0 -0
- languages/grw-fr_FR.po +3 -0
- readme.txt +7 -2
grw-reviews-helper.php
CHANGED
@@ -136,7 +136,7 @@ function grw_trim_text($text, $size) {
|
|
136 |
}
|
137 |
|
138 |
function grw_anchor($url, $class, $text, $open_link, $nofollow_link) {
|
139 |
-
|
140 |
}
|
141 |
|
142 |
function grw_image($src, $alt, $lazy, $def_ava = 'data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7', $atts = '') {
|
136 |
}
|
137 |
|
138 |
function grw_anchor($url, $class, $text, $open_link, $nofollow_link) {
|
139 |
+
echo '<a href="' . $url . '"' . ($class ? ' class="' . $class . '"' : '') . ($open_link ? ' target="_blank"' : '') . ' rel="' . ($nofollow_link ? 'nofollow ' : '') . 'noopener">' . $text . '</a>';
|
140 |
}
|
141 |
|
142 |
function grw_image($src, $alt, $lazy, $def_ava = 'data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7', $atts = '') {
|
grw-reviews.php
CHANGED
@@ -36,6 +36,17 @@ if (is_numeric($max_height)) {
|
|
36 |
$max_height = $max_height . 'px';
|
37 |
}
|
38 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
39 |
if ($refresh_reviews) {
|
40 |
$schedule_step = 60 * 60 * 55;
|
41 |
$args = array($place_id);
|
@@ -51,7 +62,7 @@ if ($refresh_reviews) {
|
|
51 |
|
52 |
if ($view_mode == 'list' || $view_mode == '') { ?>
|
53 |
|
54 |
-
<div class="wp-gr wpac"
|
55 |
<div class="wp-google-list<?php if ($dark_theme) { ?> wp-dark<?php } ?>">
|
56 |
<div class="wp-google-place">
|
57 |
<?php grw_place($rating, $place, $place_img, $reviews, $dark_theme, $hide_based_on); ?>
|
36 |
$max_height = $max_height . 'px';
|
37 |
}
|
38 |
|
39 |
+
$style = '';
|
40 |
+
if (isset($max_width) && strlen($max_width) > 0) {
|
41 |
+
$style .= 'width:' . $max_width . '!important;';
|
42 |
+
}
|
43 |
+
if (isset($max_height) && strlen($max_height) > 0) {
|
44 |
+
$style .= 'height:' . $max_height . '!important;overflow-y:auto!important;';
|
45 |
+
}
|
46 |
+
if ($centered) {
|
47 |
+
$style .= 'margin:0 auto!important;';
|
48 |
+
}
|
49 |
+
|
50 |
if ($refresh_reviews) {
|
51 |
$schedule_step = 60 * 60 * 55;
|
52 |
$args = array($place_id);
|
62 |
|
63 |
if ($view_mode == 'list' || $view_mode == '') { ?>
|
64 |
|
65 |
+
<div class="wp-gr wpac"<?php if ($style) { ?> style="<?php echo $style;?>"<?php } ?>>
|
66 |
<div class="wp-google-list<?php if ($dark_theme) { ?> wp-dark<?php } ?>">
|
67 |
<div class="wp-google-place">
|
68 |
<?php grw_place($rating, $place, $place_img, $reviews, $dark_theme, $hide_based_on); ?>
|
grw.php
CHANGED
@@ -4,8 +4,10 @@ Plugin Name: Google Reviews Widget
|
|
4 |
Plugin URI: https://richplugins.com/business-reviews-bundle-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.8.
|
8 |
Author URI: https://richplugins.com
|
|
|
|
|
9 |
*/
|
10 |
|
11 |
require(ABSPATH . 'wp-includes/version.php');
|
@@ -13,7 +15,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.8.
|
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/s50-c/114307615494839964028.jpg');
|
19 |
define('GRW_PLUGIN_URL', plugins_url(basename(plugin_dir_path(__FILE__ )), basename(__FILE__)));
|
@@ -149,8 +151,11 @@ function grw_exist_install($current_version, $last_active_version) {
|
|
149 |
grw_refresh_reviews(array($place_id));
|
150 |
}
|
151 |
break;
|
152 |
-
case version_compare($last_active_version, '1.8.
|
153 |
-
$wpdb->
|
|
|
|
|
|
|
154 |
break;
|
155 |
}
|
156 |
}
|
@@ -248,7 +253,7 @@ function grw_shortcode($atts) {
|
|
248 |
if (empty($place_id)) {
|
249 |
?>
|
250 |
<div class="grw-error" style="padding:10px;color:#b94a48;background-color:#f2dede;border-color:#eed3d7;max-width:200px;">
|
251 |
-
<?php echo grw_i('<b>Google Reviews
|
252 |
</div>
|
253 |
<?php
|
254 |
} else {
|
4 |
Plugin URI: https://richplugins.com/business-reviews-bundle-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.8.7
|
8 |
Author URI: https://richplugins.com
|
9 |
+
Text Domain: widget-google-reviews
|
10 |
+
Domain Path: /languages
|
11 |
*/
|
12 |
|
13 |
require(ABSPATH . 'wp-includes/version.php');
|
15 |
include_once(dirname(__FILE__) . '/api/urlopen.php');
|
16 |
include_once(dirname(__FILE__) . '/helper/debug.php');
|
17 |
|
18 |
+
define('GRW_VERSION', '1.8.7');
|
19 |
define('GRW_GOOGLE_PLACE_API', 'https://maps.googleapis.com/maps/api/place/');
|
20 |
define('GRW_GOOGLE_AVATAR', 'https://lh3.googleusercontent.com/-8hepWJzFXpE/AAAAAAAAAAI/AAAAAAAAAAA/I80WzYfIxCQ/s50-c/114307615494839964028.jpg');
|
21 |
define('GRW_PLUGIN_URL', plugins_url(basename(plugin_dir_path(__FILE__ )), basename(__FILE__)));
|
151 |
grw_refresh_reviews(array($place_id));
|
152 |
}
|
153 |
break;
|
154 |
+
case version_compare($last_active_version, '1.8.7', '<'):
|
155 |
+
$row = $wpdb->get_results("SELECT COLUMN_NAME FROM INFORMATION_SCHEMA.COLUMNS WHERE table_name = '" . $wpdb->prefix . "grp_google_review' AND column_name = 'hide'");
|
156 |
+
if(empty($row)){
|
157 |
+
$wpdb->query("ALTER TABLE " . $wpdb->prefix . "grp_google_review ADD hide VARCHAR(1) DEFAULT '' NOT NULL");
|
158 |
+
}
|
159 |
break;
|
160 |
}
|
161 |
}
|
253 |
if (empty($place_id)) {
|
254 |
?>
|
255 |
<div class="grw-error" style="padding:10px;color:#b94a48;background-color:#f2dede;border-color:#eed3d7;max-width:200px;">
|
256 |
+
<?php echo grw_i('<b>Google Reviews Widget</b>: required attribute place_id is not defined'); ?>
|
257 |
</div>
|
258 |
<?php
|
259 |
} else {
|
languages/grw-fr_FR.mo
CHANGED
Binary file
|
languages/grw-fr_FR.po
CHANGED
@@ -25,3 +25,6 @@ msgstr "Utilisateur Google"
|
|
25 |
|
26 |
msgid "read more"
|
27 |
msgstr "plus"
|
|
|
|
|
|
25 |
|
26 |
msgid "read more"
|
27 |
msgstr "plus"
|
28 |
+
|
29 |
+
msgid "Based on %s reviews"
|
30 |
+
msgstr "Basé sur %s avis"
|
readme.txt
CHANGED
@@ -3,8 +3,8 @@ Contributors: richplugins
|
|
3 |
Donate link: https://richplugins.com/business-reviews-bundle-wordpress-plugin
|
4 |
Tags: Google, reviews, widget, testimonials, Google Places reviews
|
5 |
Requires at least: 2.8
|
6 |
-
Tested up to: 5.
|
7 |
-
Stable tag: 1.8.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -79,6 +79,11 @@ Why limit your reviews to just Google Reviews? Check out our other free reviews
|
|
79 |
|
80 |
== Changelog ==
|
81 |
|
|
|
|
|
|
|
|
|
|
|
82 |
= 1.8.6 =
|
83 |
* Bugfix: create db fixes
|
84 |
|
3 |
Donate link: https://richplugins.com/business-reviews-bundle-wordpress-plugin
|
4 |
Tags: Google, reviews, widget, testimonials, Google Places reviews
|
5 |
Requires at least: 2.8
|
6 |
+
Tested up to: 5.4
|
7 |
+
Stable tag: 1.8.7
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
79 |
|
80 |
== Changelog ==
|
81 |
|
82 |
+
= 1.8.7 =
|
83 |
+
* Added text domain and path for localization
|
84 |
+
* Bugfix: W3C compatibility
|
85 |
+
* Bugfix: Some fixes for fr_FR locale
|
86 |
+
|
87 |
= 1.8.6 =
|
88 |
* Bugfix: create db fixes
|
89 |
|