Version Description
- Fixed: Cross-Site Scripting.
- Fixed: 10Web Booster integration for connected websites.
Download this release
Release Info
Developer | 10web |
Plugin | Photo Gallery by WD – Responsive Photo Gallery |
Version | 1.7.1 |
Comparing to | |
See all releases |
Code changes from version 1.7.0 to 1.7.1
- admin/controllers/Speed.php +38 -3
- admin/views/Speed.php +38 -15
- css/bwg_speed.css +9 -9
- js/bwg_speed.js +49 -4
- photo-gallery.php +6 -5
- readme.txt +20 -16
- wd/includes/notices.php +1 -1
admin/controllers/Speed.php
CHANGED
@@ -42,6 +42,11 @@ class SpeedController_bwg {
|
|
42 |
*/
|
43 |
private $tenweb_is_paid = FALSE;
|
44 |
|
|
|
|
|
|
|
|
|
|
|
45 |
/**
|
46 |
* @var array $google_api_keys
|
47 |
*/
|
@@ -70,12 +75,15 @@ class SpeedController_bwg {
|
|
70 |
* Set values to $booster_plugin_status, $booster_is_connected, $tenweb_is_paid
|
71 |
*/
|
72 |
public function set_booster_data() {
|
|
|
|
|
73 |
$booster_plugin_status = get_option('bwg_speed');
|
74 |
-
if( !empty($booster_plugin_status)
|
|
|
75 |
$this->booster_plugin_status = $booster_plugin_status['booster_plugin_status'];
|
76 |
}
|
77 |
|
78 |
-
if( ( defined('TENWEB_CONNECTED_SPEED') &&
|
79 |
class_exists('\Tenweb_Authorization\Login') &&
|
80 |
\Tenweb_Authorization\Login::get_instance()->check_logged_in() &&
|
81 |
\Tenweb_Authorization\Login::get_instance()->get_connection_type() == TENWEB_CONNECTED_SPEED ) ||
|
@@ -192,6 +200,8 @@ class SpeedController_bwg {
|
|
192 |
|
193 |
$params['booster_is_connected'] = $this->booster_is_connected;
|
194 |
$params['tenweb_is_paid'] = $this->tenweb_is_paid;
|
|
|
|
|
195 |
$this->view->display($params);
|
196 |
}
|
197 |
|
@@ -260,7 +270,11 @@ class SpeedController_bwg {
|
|
260 |
}
|
261 |
}
|
262 |
|
263 |
-
echo json_encode( array(
|
|
|
|
|
|
|
|
|
264 |
die;
|
265 |
}
|
266 |
|
@@ -394,6 +408,27 @@ class SpeedController_bwg {
|
|
394 |
die;
|
395 |
}
|
396 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
397 |
/**
|
398 |
* Ajax action Get google page speed scor for desktop and mobile
|
399 |
*
|
42 |
*/
|
43 |
private $tenweb_is_paid = FALSE;
|
44 |
|
45 |
+
/**
|
46 |
+
* @var mixed $subscription_id
|
47 |
+
*/
|
48 |
+
private $subscription_id = FALSE;
|
49 |
+
|
50 |
/**
|
51 |
* @var array $google_api_keys
|
52 |
*/
|
75 |
* Set values to $booster_plugin_status, $booster_is_connected, $tenweb_is_paid
|
76 |
*/
|
77 |
public function set_booster_data() {
|
78 |
+
$this->subscription_id = get_transient('tenweb_subscription_id');
|
79 |
+
|
80 |
$booster_plugin_status = get_option('bwg_speed');
|
81 |
+
if ( !empty($booster_plugin_status)
|
82 |
+
&& isset($booster_plugin_status['booster_plugin_status']) ) {
|
83 |
$this->booster_plugin_status = $booster_plugin_status['booster_plugin_status'];
|
84 |
}
|
85 |
|
86 |
+
if ( ( defined('TENWEB_CONNECTED_SPEED') &&
|
87 |
class_exists('\Tenweb_Authorization\Login') &&
|
88 |
\Tenweb_Authorization\Login::get_instance()->check_logged_in() &&
|
89 |
\Tenweb_Authorization\Login::get_instance()->get_connection_type() == TENWEB_CONNECTED_SPEED ) ||
|
200 |
|
201 |
$params['booster_is_connected'] = $this->booster_is_connected;
|
202 |
$params['tenweb_is_paid'] = $this->tenweb_is_paid;
|
203 |
+
$params['subscription_id'] = $this->subscription_id;
|
204 |
+
|
205 |
$this->view->display($params);
|
206 |
}
|
207 |
|
270 |
}
|
271 |
}
|
272 |
|
273 |
+
echo json_encode( array(
|
274 |
+
'booster_plugin_status' => esc_html($booster_plugin_status),
|
275 |
+
'booster_is_connected' => esc_html($this->booster_is_connected),
|
276 |
+
'subscription_id' => esc_html($this->subscription_id),
|
277 |
+
) );
|
278 |
die;
|
279 |
}
|
280 |
|
408 |
die;
|
409 |
}
|
410 |
|
411 |
+
/**
|
412 |
+
* Connect to dashboard.
|
413 |
+
*
|
414 |
+
* @return void
|
415 |
+
*/
|
416 |
+
public function connect_to_dashboard() {
|
417 |
+
$speed_ajax_nonce = WDWLibrary::get('speed_ajax_nonce');
|
418 |
+
if ( !wp_verify_nonce($speed_ajax_nonce, 'speed_ajax_nonce') ){
|
419 |
+
die('Permission Denied.');
|
420 |
+
}
|
421 |
+
|
422 |
+
if ( class_exists('\TenWebOptimizer\OptimizerUtils') ) {
|
423 |
+
$two_connect_link = \TenWebOptimizer\OptimizerUtils::get_tenweb_connection_link('login');
|
424 |
+
echo json_encode(array( 'status' => 'success', 'booster_connect_url' => $two_connect_link ));
|
425 |
+
}
|
426 |
+
else {
|
427 |
+
echo json_encode(array( 'status' => 'error' ) );
|
428 |
+
}
|
429 |
+
die;
|
430 |
+
}
|
431 |
+
|
432 |
/**
|
433 |
* Ajax action Get google page speed scor for desktop and mobile
|
434 |
*
|
admin/views/Speed.php
CHANGED
@@ -18,24 +18,30 @@ class SpeedView_bwg extends AdminView_bwg {
|
|
18 |
* @param $params
|
19 |
*/
|
20 |
public function display( $params = array() ) {
|
21 |
-
|
22 |
<div class="wrap">
|
23 |
<div class="bwg-speed-header">
|
24 |
<?php
|
25 |
if ( $params['booster_plugin_status'] !== 2 ) {
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
|
30 |
-
|
31 |
-
|
|
|
|
|
|
|
32 |
} else {
|
33 |
-
|
34 |
}
|
|
|
|
|
|
|
|
|
35 |
}
|
36 |
?>
|
37 |
</div>
|
38 |
-
|
39 |
<div class="bwg-speed-body">
|
40 |
<div class="bwg-speed-body-container">
|
41 |
<p class="bwg-section-title"><?php esc_html_e('PageSpeed score', 'photo-gallery'); ?></p>
|
@@ -135,11 +141,11 @@ class SpeedView_bwg extends AdminView_bwg {
|
|
135 |
?>
|
136 |
<div class="bwg-analyze-img_optimizer-container bwg-optimize_pending">
|
137 |
<div>
|
138 |
-
<p class="bwg-section-title"><?php esc_html_e('Image optimizer
|
139 |
<p class="bwg-header-description"><?php esc_html_e('Compress images without compromising the quality.', 'photo-gallery') ?></p>
|
140 |
<ul>
|
141 |
<li><?php esc_html_e('Optimize all uploaded images', 'photo-gallery') ?></li>
|
142 |
-
<li><?php esc_html_e('
|
143 |
<li><?php esc_html_e('Speed up website and reduce load time', 'photo-gallery') ?></li>
|
144 |
</ul>
|
145 |
<div class="bwg-optimize-now-tooltip bwg-hidden"><?php esc_html_e('Installing 10Web Booster and signing up are required for image optimization.', 'photo-gallery'); ?></div>
|
@@ -226,21 +232,38 @@ class SpeedView_bwg extends AdminView_bwg {
|
|
226 |
}
|
227 |
|
228 |
/**
|
229 |
-
*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
230 |
*
|
231 |
* @param int $booster_plugin_status 2-active, 1-installed, 0-not installed
|
232 |
*/
|
233 |
public function sign_up_booster_view( $booster_plugin_status ) {
|
234 |
?>
|
235 |
-
<div class="bwg-sign_up-booster-container <?php echo esc_html($booster_plugin_status != 2) ? 'bwg-hidden' : ''; ?>">
|
236 |
<p class="bwg-section-title"><?php esc_html_e('10Web Booster plugin is installed!', 'photo-gallery') ?></p>
|
237 |
<p class="bwg-description"><?php esc_html_e('Sign up to activate 10Web Booster on your website and start optimization process.', 'photo-gallery') ?></p>
|
238 |
<p class="bwg-description"><?php esc_html_e('Optimization will start automatically after the sign up.', 'photo-gallery') ?></p>
|
239 |
<input type="email" class="bwg-sign-up-input" placeholder="Email address">
|
240 |
<div class="bwg-sign-up-dashboard-button-container">
|
241 |
-
<a class="bwg-sign-up-dashboard-button"><?php esc_html_e('Sign up',
|
242 |
<div>
|
243 |
-
<?php esc_html_e('By signing up, you agree to 10Web’s.',
|
244 |
<br>
|
245 |
<a href="https://10web.io/terms-of-service/" target="_blank"><?php esc_html_e('Terms of Services', 'photo-gallery'); ?></a>
|
246 |
<?php esc_html_e(' and ', 'photo-gallery'); ?>
|
18 |
* @param $params
|
19 |
*/
|
20 |
public function display( $params = array() ) {
|
21 |
+
?>
|
22 |
<div class="wrap">
|
23 |
<div class="bwg-speed-header">
|
24 |
<?php
|
25 |
if ( $params['booster_plugin_status'] !== 2 ) {
|
26 |
+
$this->install_booster_view( $params['booster_plugin_status'] );
|
27 |
+
$this->sign_up_booster_view( $params['booster_plugin_status'] );
|
28 |
+
$this->connected_booster_view( $params );
|
29 |
+
$this->connect_to_platform_view($params['booster_plugin_status']);
|
30 |
+
}
|
31 |
+
else {
|
32 |
+
if ( !$params['booster_is_connected'] ) {
|
33 |
+
if ( $params['subscription_id'] ) {
|
34 |
+
$this->connect_to_platform_view($params['booster_plugin_status']);
|
35 |
} else {
|
36 |
+
$this->sign_up_booster_view( $params['booster_plugin_status'] );
|
37 |
}
|
38 |
+
}
|
39 |
+
else {
|
40 |
+
$this->connected_booster_view( $params );
|
41 |
+
}
|
42 |
}
|
43 |
?>
|
44 |
</div>
|
|
|
45 |
<div class="bwg-speed-body">
|
46 |
<div class="bwg-speed-body-container">
|
47 |
<p class="bwg-section-title"><?php esc_html_e('PageSpeed score', 'photo-gallery'); ?></p>
|
141 |
?>
|
142 |
<div class="bwg-analyze-img_optimizer-container bwg-optimize_pending">
|
143 |
<div>
|
144 |
+
<p class="bwg-section-title"><?php esc_html_e('Image optimizer', 'photo-gallery') ?></p>
|
145 |
<p class="bwg-header-description"><?php esc_html_e('Compress images without compromising the quality.', 'photo-gallery') ?></p>
|
146 |
<ul>
|
147 |
<li><?php esc_html_e('Optimize all uploaded images', 'photo-gallery') ?></li>
|
148 |
+
<li><?php esc_html_e('Serve Images in WebP format', 'photo-gallery') ?></li>
|
149 |
<li><?php esc_html_e('Speed up website and reduce load time', 'photo-gallery') ?></li>
|
150 |
</ul>
|
151 |
<div class="bwg-optimize-now-tooltip bwg-hidden"><?php esc_html_e('Installing 10Web Booster and signing up are required for image optimization.', 'photo-gallery'); ?></div>
|
232 |
}
|
233 |
|
234 |
/**
|
235 |
+
* HTML content for case when booster plugin installed and the website has any subscription plan.
|
236 |
+
*
|
237 |
+
* @return void
|
238 |
+
*/
|
239 |
+
public function connect_to_platform_view($booster_plugin_status) {
|
240 |
+
?>
|
241 |
+
<div class="bwg-booster-container bwg-connect-to-dashboard-container <?php echo esc_html($booster_plugin_status != 2) ? 'bwg-hidden' : ''; ?>">
|
242 |
+
<p class="bwg-section-title"><?php esc_html_e('10Web Booster plugin is installed!', 'photo-gallery') ?></p>
|
243 |
+
<p class="bwg-description"><?php esc_html_e('Connect to 10Web dashboard to activate 10Web Booster on your website and start optimization process. Optimization will start automatically.', 'photo-gallery') ?></p>
|
244 |
+
<div class="bwg-sign-up-dashboard-button-container">
|
245 |
+
<a class="bwg-booster-button bwg-connect-to-dashboard-button"><?php esc_html_e('Connect', 'photo-gallery'); ?></a>
|
246 |
+
</div>
|
247 |
+
</div>
|
248 |
+
<?php
|
249 |
+
}
|
250 |
+
|
251 |
+
/**
|
252 |
+
* HTML content for case when booster plugin installed but user didn't sign up
|
253 |
*
|
254 |
* @param int $booster_plugin_status 2-active, 1-installed, 0-not installed
|
255 |
*/
|
256 |
public function sign_up_booster_view( $booster_plugin_status ) {
|
257 |
?>
|
258 |
+
<div class="bwg-booster-container bwg-sign_up-booster-container <?php echo esc_html($booster_plugin_status != 2) ? 'bwg-hidden' : ''; ?>">
|
259 |
<p class="bwg-section-title"><?php esc_html_e('10Web Booster plugin is installed!', 'photo-gallery') ?></p>
|
260 |
<p class="bwg-description"><?php esc_html_e('Sign up to activate 10Web Booster on your website and start optimization process.', 'photo-gallery') ?></p>
|
261 |
<p class="bwg-description"><?php esc_html_e('Optimization will start automatically after the sign up.', 'photo-gallery') ?></p>
|
262 |
<input type="email" class="bwg-sign-up-input" placeholder="Email address">
|
263 |
<div class="bwg-sign-up-dashboard-button-container">
|
264 |
+
<a class="bwg-booster-button bwg-sign-up-dashboard-button"><?php esc_html_e('Sign up', 'photo-gallery'); ?></a>
|
265 |
<div>
|
266 |
+
<?php esc_html_e('By signing up, you agree to 10Web’s.', 'photo-gallery'); ?>
|
267 |
<br>
|
268 |
<a href="https://10web.io/terms-of-service/" target="_blank"><?php esc_html_e('Terms of Services', 'photo-gallery'); ?></a>
|
269 |
<?php esc_html_e(' and ', 'photo-gallery'); ?>
|
css/bwg_speed.css
CHANGED
@@ -23,7 +23,7 @@
|
|
23 |
}
|
24 |
|
25 |
.bwg-install-booster-container p.bwg-section-title,
|
26 |
-
.bwg-
|
27 |
.bwg-speed-body-container p.bwg-section-title,
|
28 |
.bwg-connected-booster-content p.bwg-section-title{
|
29 |
padding: 0;
|
@@ -98,7 +98,7 @@
|
|
98 |
|
99 |
a.bwg-install-booster,
|
100 |
a.bwg-manage-booster,
|
101 |
-
a.bwg-
|
102 |
display: block;
|
103 |
width: 235px;
|
104 |
height: 40px;
|
@@ -120,7 +120,7 @@ a.bwg-manage-booster {
|
|
120 |
}
|
121 |
|
122 |
a.bwg-install-booster:hover,
|
123 |
-
a.bwg-
|
124 |
a.bwg-optimize-now-button:hover,
|
125 |
a.bwg-optimize-add-pages,
|
126 |
a.bwg-manage-booster {
|
@@ -149,11 +149,11 @@ a.bwg-disable-link:hover {
|
|
149 |
width: 15px;
|
150 |
}
|
151 |
|
152 |
-
.bwg-
|
153 |
display: flex;
|
154 |
}
|
155 |
|
156 |
-
.bwg-
|
157 |
padding: 0 0 0 15px;
|
158 |
box-sizing: border-box;
|
159 |
max-width: 420px;
|
@@ -162,7 +162,7 @@ a.bwg-disable-link:hover {
|
|
162 |
color: #323A45;
|
163 |
}
|
164 |
|
165 |
-
.bwg-
|
166 |
color: #323A45;
|
167 |
}
|
168 |
|
@@ -903,18 +903,18 @@ input.bwg-sign-up-input {
|
|
903 |
width: 100%;
|
904 |
}
|
905 |
|
906 |
-
.bwg-
|
907 |
display: block;
|
908 |
}
|
909 |
|
910 |
-
a.bwg-
|
911 |
display: block;
|
912 |
width: 210px;
|
913 |
height: 40px;
|
914 |
margin-bottom: 15px;
|
915 |
}
|
916 |
|
917 |
-
.bwg-
|
918 |
padding: 0;
|
919 |
}
|
920 |
|
23 |
}
|
24 |
|
25 |
.bwg-install-booster-container p.bwg-section-title,
|
26 |
+
.bwg-booster-container p.bwg-section-title,
|
27 |
.bwg-speed-body-container p.bwg-section-title,
|
28 |
.bwg-connected-booster-content p.bwg-section-title{
|
29 |
padding: 0;
|
98 |
|
99 |
a.bwg-install-booster,
|
100 |
a.bwg-manage-booster,
|
101 |
+
a.bwg-booster-button {
|
102 |
display: block;
|
103 |
width: 235px;
|
104 |
height: 40px;
|
120 |
}
|
121 |
|
122 |
a.bwg-install-booster:hover,
|
123 |
+
a.bwg-booster-button:hover,
|
124 |
a.bwg-optimize-now-button:hover,
|
125 |
a.bwg-optimize-add-pages,
|
126 |
a.bwg-manage-booster {
|
149 |
width: 15px;
|
150 |
}
|
151 |
|
152 |
+
.bwg-booster-container > div {
|
153 |
display: flex;
|
154 |
}
|
155 |
|
156 |
+
.bwg-booster-container > div > div {
|
157 |
padding: 0 0 0 15px;
|
158 |
box-sizing: border-box;
|
159 |
max-width: 420px;
|
162 |
color: #323A45;
|
163 |
}
|
164 |
|
165 |
+
.bwg-booster-container > div > div a {
|
166 |
color: #323A45;
|
167 |
}
|
168 |
|
903 |
width: 100%;
|
904 |
}
|
905 |
|
906 |
+
.bwg-booster-container > div {
|
907 |
display: block;
|
908 |
}
|
909 |
|
910 |
+
a.bwg-booster-button {
|
911 |
display: block;
|
912 |
width: 210px;
|
913 |
height: 40px;
|
914 |
margin-bottom: 15px;
|
915 |
}
|
916 |
|
917 |
+
.bwg-booster-container > div > div {
|
918 |
padding: 0;
|
919 |
}
|
920 |
|
js/bwg_speed.js
CHANGED
@@ -5,7 +5,11 @@ jQuery(function () {
|
|
5 |
});
|
6 |
|
7 |
jQuery(".bwg-sign-up-dashboard-button").on("click", function () {
|
8 |
-
sign_up_dashboard( this )
|
|
|
|
|
|
|
|
|
9 |
});
|
10 |
|
11 |
jQuery(".bwg-analyze-input-button").on("click", function () {
|
@@ -110,10 +114,15 @@ function install_booster_plugin( that ) {
|
|
110 |
jQuery(".bwg-install-booster").text(bwg_speed.install_button_text);
|
111 |
return;
|
112 |
}
|
113 |
-
if( parseInt(data.booster_plugin_status) === 2 ) {
|
114 |
jQuery(".bwg-install-booster-container").addClass("bwg-hidden");
|
115 |
if ( !data.booster_is_connected ) {
|
116 |
-
|
|
|
|
|
|
|
|
|
|
|
117 |
} else {
|
118 |
jQuery(".bwg-connected-booster-container").removeClass("bwg-hidden");
|
119 |
}
|
@@ -198,7 +207,41 @@ function sign_up_dashboard( that ) {
|
|
198 |
email_input.after('<p class="bwg-error-msg">' + bwg_speed.something_wrong + '</p>');
|
199 |
}
|
200 |
});
|
|
|
|
|
|
|
|
|
|
|
|
|
201 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
202 |
}
|
203 |
|
204 |
/**
|
@@ -272,7 +315,9 @@ function bwg_get_google_score( that, home_url, last_api_key_index ) {
|
|
272 |
return;
|
273 |
}
|
274 |
|
275 |
-
jQuery(".
|
|
|
|
|
276 |
jQuery(".speed_circle").addClass("bwg-hidden");
|
277 |
jQuery(".bwg-load-time-mobile span").text("-");
|
278 |
jQuery(".bwg-load-time-desktop span").text("-");
|
5 |
});
|
6 |
|
7 |
jQuery(".bwg-sign-up-dashboard-button").on("click", function () {
|
8 |
+
sign_up_dashboard( this );
|
9 |
+
});
|
10 |
+
|
11 |
+
jQuery(".bwg-connect-to-dashboard-button").on("click", function () {
|
12 |
+
connect_to_dashboard( this );
|
13 |
});
|
14 |
|
15 |
jQuery(".bwg-analyze-input-button").on("click", function () {
|
114 |
jQuery(".bwg-install-booster").text(bwg_speed.install_button_text);
|
115 |
return;
|
116 |
}
|
117 |
+
if ( parseInt(data.booster_plugin_status) === 2 ) {
|
118 |
jQuery(".bwg-install-booster-container").addClass("bwg-hidden");
|
119 |
if ( !data.booster_is_connected ) {
|
120 |
+
if ( data.subscription_id ) {
|
121 |
+
jQuery(".bwg-connect-to-dashboard-container").removeClass("bwg-hidden");
|
122 |
+
}
|
123 |
+
else {
|
124 |
+
jQuery(".bwg-sign_up-booster-container").removeClass("bwg-hidden");
|
125 |
+
}
|
126 |
} else {
|
127 |
jQuery(".bwg-connected-booster-container").removeClass("bwg-hidden");
|
128 |
}
|
207 |
email_input.after('<p class="bwg-error-msg">' + bwg_speed.something_wrong + '</p>');
|
208 |
}
|
209 |
});
|
210 |
+
}
|
211 |
+
|
212 |
+
function connect_to_dashboard( that ) {
|
213 |
+
if ( jQuery(that).hasClass("bwg-disable-link") ) {
|
214 |
+
return false;
|
215 |
+
}
|
216 |
|
217 |
+
jQuery.ajax( {
|
218 |
+
url: ajaxurl,
|
219 |
+
type: "POST",
|
220 |
+
data: {
|
221 |
+
action: "speed_bwg",
|
222 |
+
task: "connect_to_dashboard",
|
223 |
+
speed_ajax_nonce: bwg_speed.speed_ajax_nonce
|
224 |
+
},
|
225 |
+
success: function ( result ) {
|
226 |
+
if ( !isValidJSONString(result) ) {
|
227 |
+
jQuery(that).text(bwg_speed.connect);
|
228 |
+
jQuery(that).removeClass('bwg-disable-link');
|
229 |
+
return;
|
230 |
+
}
|
231 |
+
var data = JSON.parse(result);
|
232 |
+
if ( data['status'] === 'success' ) {
|
233 |
+
window.location.href = data['booster_connect_url'];
|
234 |
+
} else {
|
235 |
+
jQuery(that).text(bwg_speed.connect);
|
236 |
+
jQuery(that).removeClass('bwg-disable-link');
|
237 |
+
return;
|
238 |
+
}
|
239 |
+
},
|
240 |
+
error: function ( xhr ) {
|
241 |
+
jQuery(that).text(bwg_speed.connect);
|
242 |
+
jQuery(that).removeClass('bwg-disable-link');
|
243 |
+
}
|
244 |
+
});
|
245 |
}
|
246 |
|
247 |
/**
|
315 |
return;
|
316 |
}
|
317 |
|
318 |
+
if ( jQuery(".speed_circle_loader").length === 0 ) {
|
319 |
+
jQuery(".speed_circle").after("<div class='speed_circle_loader'></div>");
|
320 |
+
}
|
321 |
jQuery(".speed_circle").addClass("bwg-hidden");
|
322 |
jQuery(".bwg-load-time-mobile span").text("-");
|
323 |
jQuery(".bwg-load-time-desktop span").text("-");
|
photo-gallery.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Plugin Name: Photo Gallery
|
4 |
* Plugin URI: https://10web.io/plugins/wordpress-photo-gallery/?utm_source=photo_gallery&utm_medium=free_plugin
|
5 |
* Description: This plugin is a fully responsive gallery plugin with advanced functionality. It allows having different image galleries for your posts and pages. You can create unlimited number of galleries, combine them into albums, and provide descriptions and tags.
|
6 |
-
* Version: 1.7.
|
7 |
* Author: Photo Gallery Team
|
8 |
* Author URI: https://10web.io/plugins/?utm_source=photo_gallery&utm_medium=free_plugin
|
9 |
* Text Domain: photo-gallery
|
@@ -106,8 +106,8 @@ final class BWG {
|
|
106 |
$this->plugin_url = plugins_url(plugin_basename(dirname(__FILE__)));
|
107 |
$this->front_url = $this->plugin_url;
|
108 |
$this->main_file = plugin_basename(__FILE__);
|
109 |
-
$this->plugin_version = '1.7.
|
110 |
-
$this->db_version = '1.7.
|
111 |
$this->prefix = 'bwg';
|
112 |
$this->nicename = __('Photo Gallery', 'photo-gallery');
|
113 |
require_once($this->plugin_dir . '/framework/WDWLibrary.php');
|
@@ -513,7 +513,7 @@ final class BWG {
|
|
513 |
$themes_page = add_submenu_page($parent_slug, __('Themes', 'photo-gallery'), __('Themes', 'photo-gallery'), $themes_permission, 'themes_' . $this->prefix, array($this , 'admin_pages'));
|
514 |
add_action('load-' . $themes_page, array($this, 'themes_per_page_option'));
|
515 |
|
516 |
-
if( $this->is_pro ) {
|
517 |
$comments_page = add_submenu_page($parent_slug, __('Comments', 'photo-gallery'), __('Comments', 'photo-gallery'), 'manage_options', 'comments_' . $this->prefix, array($this , 'admin_pages'));
|
518 |
add_action('load-' . $comments_page, array($this, 'comments_per_page_option'));
|
519 |
|
@@ -544,7 +544,7 @@ final class BWG {
|
|
544 |
public function is_appsumo_subscription() {
|
545 |
$user_info = get_option('tenweb_user_info');
|
546 |
|
547 |
-
if ( !empty($user_info) ) {
|
548 |
$agreement_info = $user_info['agreement_info'];
|
549 |
$subscription_cat = $agreement_info->subscription_category;
|
550 |
if ( $subscription_cat == 'appsumo' || $subscription_cat == '10WebX_ltd' ) {
|
@@ -657,6 +657,7 @@ final class BWG {
|
|
657 |
'enter_page_url' => __('Please enter a Page URL.', 'photo-gallery'),
|
658 |
'page_is_not_public' => __('This page is not public. Please publish the page to check the score.', 'photo-gallery'),
|
659 |
'sign_up' => __('Sign up', 'photo-gallery'),
|
|
|
660 |
'home_url' => get_home_url(),
|
661 |
'home_speed_status' => $this->check_home_speed_status(),
|
662 |
'analyze_button_text' => __('Analyze', 'photo-gallery'),
|
3 |
* Plugin Name: Photo Gallery
|
4 |
* Plugin URI: https://10web.io/plugins/wordpress-photo-gallery/?utm_source=photo_gallery&utm_medium=free_plugin
|
5 |
* Description: This plugin is a fully responsive gallery plugin with advanced functionality. It allows having different image galleries for your posts and pages. You can create unlimited number of galleries, combine them into albums, and provide descriptions and tags.
|
6 |
+
* Version: 1.7.1
|
7 |
* Author: Photo Gallery Team
|
8 |
* Author URI: https://10web.io/plugins/?utm_source=photo_gallery&utm_medium=free_plugin
|
9 |
* Text Domain: photo-gallery
|
106 |
$this->plugin_url = plugins_url(plugin_basename(dirname(__FILE__)));
|
107 |
$this->front_url = $this->plugin_url;
|
108 |
$this->main_file = plugin_basename(__FILE__);
|
109 |
+
$this->plugin_version = '1.7.1';
|
110 |
+
$this->db_version = '1.7.1';
|
111 |
$this->prefix = 'bwg';
|
112 |
$this->nicename = __('Photo Gallery', 'photo-gallery');
|
113 |
require_once($this->plugin_dir . '/framework/WDWLibrary.php');
|
513 |
$themes_page = add_submenu_page($parent_slug, __('Themes', 'photo-gallery'), __('Themes', 'photo-gallery'), $themes_permission, 'themes_' . $this->prefix, array($this , 'admin_pages'));
|
514 |
add_action('load-' . $themes_page, array($this, 'themes_per_page_option'));
|
515 |
|
516 |
+
if ( $this->is_pro ) {
|
517 |
$comments_page = add_submenu_page($parent_slug, __('Comments', 'photo-gallery'), __('Comments', 'photo-gallery'), 'manage_options', 'comments_' . $this->prefix, array($this , 'admin_pages'));
|
518 |
add_action('load-' . $comments_page, array($this, 'comments_per_page_option'));
|
519 |
|
544 |
public function is_appsumo_subscription() {
|
545 |
$user_info = get_option('tenweb_user_info');
|
546 |
|
547 |
+
if ( !empty($user_info) && !empty($user_info['agreement_info']) && !empty($user_info['agreement_info']->subscription_category) ) {
|
548 |
$agreement_info = $user_info['agreement_info'];
|
549 |
$subscription_cat = $agreement_info->subscription_category;
|
550 |
if ( $subscription_cat == 'appsumo' || $subscription_cat == '10WebX_ltd' ) {
|
657 |
'enter_page_url' => __('Please enter a Page URL.', 'photo-gallery'),
|
658 |
'page_is_not_public' => __('This page is not public. Please publish the page to check the score.', 'photo-gallery'),
|
659 |
'sign_up' => __('Sign up', 'photo-gallery'),
|
660 |
+
'connect' => __('Connect', 'photo-gallery'),
|
661 |
'home_url' => get_home_url(),
|
662 |
'home_speed_status' => $this->check_home_speed_status(),
|
663 |
'analyze_button_text' => __('Analyze', 'photo-gallery'),
|
readme.txt
CHANGED
@@ -3,7 +3,7 @@ Contributors: webdorado,wdsupport,photogallerysupport,10web
|
|
3 |
Tags: gallery, photo gallery, image gallery, responsive gallery, wordpress gallery plugin, photo albums, gallery slider, gallery lightbox, wordpress photo gallery plugin, fullscreen gallery, watermarking, video gallery
|
4 |
Requires at least: 4.6
|
5 |
Tested up to: 6.0
|
6 |
-
Stable tag: 1.7.
|
7 |
License: GPLv2 or later
|
8 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
9 |
|
@@ -42,7 +42,7 @@ Check the extensive feature list of the plugin bellow, have a look at the plugin
|
|
42 |
|
43 |
= CUSTOMIZABLE VIEWS =
|
44 |
|
45 |
-
Photo Gallery provides a number of view options to organize your galleries and albums in beautiful views, including Slideshow, Thumbnails, Masonry
|
46 |
|
47 |
= UNLIMITED PHOTOS, GALLERIES AND ALBUMS =
|
48 |
|
@@ -50,7 +50,7 @@ Sounds great, right? With plugin you can have as many galleries and albums as yo
|
|
50 |
|
51 |
= POWERFUL LIGHTBOX =
|
52 |
|
53 |
-
You can display your media content in a responsive lightbox that comes with 15 slideshow effects
|
54 |
|
55 |
= AUDIO AND VIDEO SUPPORT =
|
56 |
|
@@ -66,15 +66,15 @@ With watermarking feature of the Photo Gallery plugin you can add text or image
|
|
66 |
|
67 |
= PRELOADED THEMES =
|
68 |
|
69 |
-
The plugin comes with two default Themes.
|
70 |
|
71 |
= SOCIAL SHARING =
|
72 |
|
73 |
-
|
74 |
|
75 |
= ADD-ONS =
|
76 |
|
77 |
-
Photo Gallery comes with a number of add-ons that can help you
|
78 |
|
79 |
|
80 |
|
@@ -82,20 +82,20 @@ Photo Gallery comes with a number of add-ons that can help you sell digital imag
|
|
82 |
= SETTINGS/CUSTOMIZATION =
|
83 |
*Some customizations described here are available in [Premium version](https://10web.io/plugins/wordpress-photo-gallery/) . Please refer to feature summary for additional info.
|
84 |
|
85 |
-
Photo Gallery allows you to create unlimited galleries and organize them into different photo albums providing detailed gallery descriptions and tags.The plugin supports both image and video content
|
86 |
-
Adding photos and videos to the galleries from the WordPress dashboard is simple and easy with its user-friendly admin panel. You’ll get all the tools you need to add and edit photos in the galleries.The file manager will help to rename, upload, remove, copy images and/or image directories with a few simple steps.
|
87 |
-
Under the social options tab you’ll find settings for the Instagram
|
88 |
|
89 |
|
90 |
[Premium version adds](https://10web.io/plugins/wordpress-photo-gallery/)
|
91 |
|
92 |
-
*
|
93 |
-
*
|
94 |
-
*
|
95 |
-
|
96 |
|
97 |
= Photo Gallery Add-ons =
|
98 |
-
[Google Photos Add-on](https://10web.io/plugins/wordpress-photo-gallery/) - Link and display your Google Photos albums in one click
|
99 |
[Export/Import Add-on](https://10web.io/plugins/wordpress-photo-gallery/) Export/import galleries, albums and all related data from one WordPress site to another.
|
100 |
|
101 |
###IMPORTANT:
|
@@ -273,9 +273,13 @@ Choose whether to display random or the first/last specific number of images.
|
|
273 |
|
274 |
== Changelog ==
|
275 |
|
|
|
|
|
|
|
|
|
276 |
= 1.7.0 =
|
277 |
-
* Added: 10Web Booster integration
|
278 |
-
* Improved: Updated Views and Widgets
|
279 |
|
280 |
= 1.6.10 =
|
281 |
* Fixed: Security vulnerability.
|
3 |
Tags: gallery, photo gallery, image gallery, responsive gallery, wordpress gallery plugin, photo albums, gallery slider, gallery lightbox, wordpress photo gallery plugin, fullscreen gallery, watermarking, video gallery
|
4 |
Requires at least: 4.6
|
5 |
Tested up to: 6.0
|
6 |
+
Stable tag: 1.7.1
|
7 |
License: GPLv2 or later
|
8 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
9 |
|
42 |
|
43 |
= CUSTOMIZABLE VIEWS =
|
44 |
|
45 |
+
Photo Gallery provides a number of view options to organize your galleries and albums in beautiful views, including Slideshow, Thumbnails, Masonry, Image Browser, Extended and Compact Album, Blog Style, Mosaic. The layouts give you the flexibility to customize them to match your needs.
|
46 |
|
47 |
= UNLIMITED PHOTOS, GALLERIES AND ALBUMS =
|
48 |
|
50 |
|
51 |
= POWERFUL LIGHTBOX =
|
52 |
|
53 |
+
You can display your media content in a responsive lightbox that comes with 15 slideshow effects, supports social sharing, full width view option, filmstrip, image commenting (Premium version), lightbox autoplay and many more options that make your lightbox look awesome.
|
54 |
|
55 |
= AUDIO AND VIDEO SUPPORT =
|
56 |
|
66 |
|
67 |
= PRELOADED THEMES =
|
68 |
|
69 |
+
The plugin comes with two default Themes. The themes are giving you the option to add new themes with custom styling, colors, layout settings, and image navigation options.
|
70 |
|
71 |
= SOCIAL SHARING =
|
72 |
|
73 |
+
You can allow users to share photos on Facebook, Twitter, Pinterest and Tumblr with social sharing buttons.
|
74 |
|
75 |
= ADD-ONS =
|
76 |
|
77 |
+
Photo Gallery comes with a number of add-ons that can help you import/export galleries and albums from one WordPress website to another.
|
78 |
|
79 |
|
80 |
|
82 |
= SETTINGS/CUSTOMIZATION =
|
83 |
*Some customizations described here are available in [Premium version](https://10web.io/plugins/wordpress-photo-gallery/) . Please refer to feature summary for additional info.
|
84 |
|
85 |
+
Photo Gallery allows you to create unlimited galleries and organize them into different photo albums providing detailed gallery descriptions and tags.The plugin supports both image and video content.
|
86 |
+
Adding photos and videos to the galleries from the WordPress dashboard is simple and easy with its user-friendly admin panel. You’ll get all the tools you need to add and edit photos in the galleries.The file manager will help to rename, upload, remove, copy images and/or image directories with a few simple steps. Under the options (settings) tab in admin panel you’ll find an extensive list of settings for galleries, thumbnails, watermarking, social accounts and slideshow that you can configure based on your needs. Plugin features a powerful lightbox that supports filmstrip and image carousel display. Also, you can enable image comments options and show the comments of the images right in the lightbox. There is a dedicated section for lightbox settings where you can choose to enable/disable AddThis display, image download option, image count and other lightbox features.
|
87 |
+
Under the social options tab you’ll find settings for the Instagram galleries, where you can specify Instagram feed auto update interval. With the available user roles you can choose who can add/edit galleries, images, albums and tags (Premium feature).
|
88 |
|
89 |
|
90 |
[Premium version adds](https://10web.io/plugins/wordpress-photo-gallery/)
|
91 |
|
92 |
+
* Commenting possibility with Captcha protection
|
93 |
+
* Dynamic Tag Cloud widget with image tag cloud and text tag cloud options
|
94 |
+
* Add ons support.
|
95 |
+
* Possibility of changing the roles of who can edit the galleries/albums/images (Author/All Users)
|
96 |
|
97 |
= Photo Gallery Add-ons =
|
98 |
+
[Google Photos Add-on](https://10web.io/plugins/wordpress-photo-gallery/) - Link and display your Google Photos albums in one click.
|
99 |
[Export/Import Add-on](https://10web.io/plugins/wordpress-photo-gallery/) Export/import galleries, albums and all related data from one WordPress site to another.
|
100 |
|
101 |
###IMPORTANT:
|
273 |
|
274 |
== Changelog ==
|
275 |
|
276 |
+
= 1.7.1 =
|
277 |
+
* Fixed: Cross-Site Scripting.
|
278 |
+
* Fixed: 10Web Booster integration for connected websites.
|
279 |
+
|
280 |
= 1.7.0 =
|
281 |
+
* Added: 10Web Booster integration․
|
282 |
+
* Improved: Updated Views and Widgets․
|
283 |
|
284 |
= 1.6.10 =
|
285 |
* Fixed: Security vulnerability.
|
wd/includes/notices.php
CHANGED
@@ -211,7 +211,7 @@ class TenWebNewLibNotices {
|
|
211 |
<li><span class="dashicons dashicons-smiley"></span><a href="' . esc_url($two_week_review_ignore) . '"> ' . __('I\'ve already left a review', 'photo-gallery') . '</a></li>
|
212 |
<li><span class="dashicons dashicons-calendar-alt"></span><a href="' . esc_url($two_week_review_temp) . '">' . __('Maybe Later', 'photo-gallery') . '</a></li>
|
213 |
<li><span class="dashicons dashicons-dismiss"></span><a href="' . esc_url($two_week_review_ignore) . '">' . __('Never show again', 'photo-gallery') . '</a></li>',
|
214 |
-
'later_link' => $two_week_review_temp,
|
215 |
'int' => 14,
|
216 |
);
|
217 |
$this->admin_notice($notices);
|
211 |
<li><span class="dashicons dashicons-smiley"></span><a href="' . esc_url($two_week_review_ignore) . '"> ' . __('I\'ve already left a review', 'photo-gallery') . '</a></li>
|
212 |
<li><span class="dashicons dashicons-calendar-alt"></span><a href="' . esc_url($two_week_review_temp) . '">' . __('Maybe Later', 'photo-gallery') . '</a></li>
|
213 |
<li><span class="dashicons dashicons-dismiss"></span><a href="' . esc_url($two_week_review_ignore) . '">' . __('Never show again', 'photo-gallery') . '</a></li>',
|
214 |
+
'later_link' => esc_url($two_week_review_temp),
|
215 |
'int' => 14,
|
216 |
);
|
217 |
$this->admin_notice($notices);
|