Version Description
(31-08-2020) = * Empty needle warning fixed * Appsero updated
=
Download this release
Release Info
Developer | rextheme |
Plugin | WP VR – 360 Panorama and virtual tour creator for WordPress |
Version | 6.5.0 |
Comparing to | |
See all releases |
Code changes from version 6.4.0 to 6.5.0
- README.txt +5 -1
- appsero/src/Client.php +11 -6
- appsero/src/Insights.php +133 -121
- public/class-wpvr-public.php +40 -13
- public/css/wpvr-public.css +1 -1
- wpvr.php +1 -7
README.txt
CHANGED
@@ -4,7 +4,7 @@ Donate link: https://rextheme.com/wp-vr-360-panorama-and-virtual-tour-creator-fo
|
|
4 |
Tags: virtual tour, real estate tour, panorama, panorama viewer, virtual tour, 360 panorama, interactive tour
|
5 |
Requires at least: 4.0
|
6 |
Tested up to: 5.5.0
|
7 |
-
Stable tag: 6.
|
8 |
Requires PHP: 7.0.0
|
9 |
License: GPLv2 or later
|
10 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
@@ -434,5 +434,9 @@ Simply add "/plugins/wpvr" to exclusion field (or use the location where you sto
|
|
434 |
= 6.4.0 (19-08-2020) =
|
435 |
* Media resizer fixed
|
436 |
|
|
|
|
|
|
|
|
|
437 |
== Upgrade Notice ==
|
438 |
Please do update the WP VR to the latest version. Each update makes it sure your plugin is supporting all tour features.
|
4 |
Tags: virtual tour, real estate tour, panorama, panorama viewer, virtual tour, 360 panorama, interactive tour
|
5 |
Requires at least: 4.0
|
6 |
Tested up to: 5.5.0
|
7 |
+
Stable tag: 6.5.0
|
8 |
Requires PHP: 7.0.0
|
9 |
License: GPLv2 or later
|
10 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
434 |
= 6.4.0 (19-08-2020) =
|
435 |
* Media resizer fixed
|
436 |
|
437 |
+
= 6.5.0 (31-08-2020) =
|
438 |
+
* Empty needle warning fixed
|
439 |
+
* Appsero updated
|
440 |
+
|
441 |
== Upgrade Notice ==
|
442 |
Please do update the WP VR to the latest version. Each update makes it sure your plugin is supporting all tour features.
|
appsero/src/Client.php
CHANGED
@@ -150,7 +150,6 @@ class Client {
|
|
150 |
protected function set_basename_and_slug() {
|
151 |
|
152 |
if ( strpos( $this->file, WP_CONTENT_DIR . '/themes/' ) === false ) {
|
153 |
-
|
154 |
$this->basename = plugin_basename( $this->file );
|
155 |
|
156 |
list( $this->slug, $mainfile) = explode( '/', $this->basename );
|
@@ -161,10 +160,7 @@ class Client {
|
|
161 |
|
162 |
$this->project_version = $plugin_data['Version'];
|
163 |
$this->type = 'plugin';
|
164 |
-
$this->textdomain = $this->slug;
|
165 |
-
|
166 |
} else {
|
167 |
-
|
168 |
$this->basename = str_replace( WP_CONTENT_DIR . '/themes/', '', $this->file );
|
169 |
|
170 |
list( $this->slug, $mainfile) = explode( '/', $this->basename );
|
@@ -173,8 +169,9 @@ class Client {
|
|
173 |
|
174 |
$this->project_version = $theme->version;
|
175 |
$this->type = 'theme';
|
176 |
-
|
177 |
}
|
|
|
|
|
178 |
}
|
179 |
|
180 |
/**
|
@@ -213,7 +210,9 @@ class Client {
|
|
213 |
* @return boolean
|
214 |
*/
|
215 |
public function is_local_server() {
|
216 |
-
|
|
|
|
|
217 |
}
|
218 |
|
219 |
/**
|
@@ -230,4 +229,10 @@ class Client {
|
|
230 |
return call_user_func( '__', $text, $this->textdomain );
|
231 |
}
|
232 |
|
|
|
|
|
|
|
|
|
|
|
|
|
233 |
}
|
150 |
protected function set_basename_and_slug() {
|
151 |
|
152 |
if ( strpos( $this->file, WP_CONTENT_DIR . '/themes/' ) === false ) {
|
|
|
153 |
$this->basename = plugin_basename( $this->file );
|
154 |
|
155 |
list( $this->slug, $mainfile) = explode( '/', $this->basename );
|
160 |
|
161 |
$this->project_version = $plugin_data['Version'];
|
162 |
$this->type = 'plugin';
|
|
|
|
|
163 |
} else {
|
|
|
164 |
$this->basename = str_replace( WP_CONTENT_DIR . '/themes/', '', $this->file );
|
165 |
|
166 |
list( $this->slug, $mainfile) = explode( '/', $this->basename );
|
169 |
|
170 |
$this->project_version = $theme->version;
|
171 |
$this->type = 'theme';
|
|
|
172 |
}
|
173 |
+
|
174 |
+
$this->textdomain = $this->slug;
|
175 |
}
|
176 |
|
177 |
/**
|
210 |
* @return boolean
|
211 |
*/
|
212 |
public function is_local_server() {
|
213 |
+
$is_local = in_array( $_SERVER['REMOTE_ADDR'], array( '127.0.0.1', '::1' ) );
|
214 |
+
|
215 |
+
return apply_filters( 'appsero_is_local', $is_local );
|
216 |
}
|
217 |
|
218 |
/**
|
229 |
return call_user_func( '__', $text, $this->textdomain );
|
230 |
}
|
231 |
|
232 |
+
/**
|
233 |
+
* Set project textdomain
|
234 |
+
*/
|
235 |
+
public function set_textdomain( $textdomain ) {
|
236 |
+
$this->textdomain = $textdomain;
|
237 |
+
}
|
238 |
}
|
appsero/src/Insights.php
CHANGED
@@ -180,8 +180,10 @@ class Insights {
|
|
180 |
if ( $last_send && $last_send > strtotime( '-1 week' ) ) {
|
181 |
return;
|
182 |
}
|
|
|
|
|
183 |
|
184 |
-
$response = $this->client->send_request( $
|
185 |
|
186 |
update_option( $this->client->slug . '_tracking_last_send', time() );
|
187 |
}
|
@@ -211,7 +213,6 @@ class Insights {
|
|
211 |
}
|
212 |
|
213 |
$data = array(
|
214 |
-
'version' => $this->client->project_version,
|
215 |
'url' => esc_url( home_url() ),
|
216 |
'site' => $this->get_site_name(),
|
217 |
'admin_email' => get_option( 'admin_email' ),
|
@@ -224,8 +225,8 @@ class Insights {
|
|
224 |
'active_plugins' => count( $all_plugins['active_plugins'] ),
|
225 |
'inactive_plugins' => count( $all_plugins['inactive_plugins'] ),
|
226 |
'ip_address' => $this->get_user_ip_address(),
|
227 |
-
'
|
228 |
-
'
|
229 |
);
|
230 |
|
231 |
// Add metadata
|
@@ -233,6 +234,15 @@ class Insights {
|
|
233 |
$data['extra'] = $extra;
|
234 |
}
|
235 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
236 |
return apply_filters( $this->client->slug . '_tracker_data', $data );
|
237 |
}
|
238 |
|
@@ -256,7 +266,7 @@ class Insights {
|
|
256 |
/**
|
257 |
* Explain the user which data we collect
|
258 |
*
|
259 |
-
* @return
|
260 |
*/
|
261 |
protected function data_we_collect() {
|
262 |
$data = array(
|
@@ -296,7 +306,7 @@ class Insights {
|
|
296 |
*
|
297 |
* @return boolean
|
298 |
*/
|
299 |
-
|
300 |
$hide_notice = get_option( $this->client->slug . '_tracking_notice', null );
|
301 |
|
302 |
if ( 'hide' == $hide_notice ) {
|
@@ -361,36 +371,38 @@ class Insights {
|
|
361 |
}
|
362 |
|
363 |
// don't show tracking if a local server
|
364 |
-
if (
|
365 |
-
|
366 |
-
|
367 |
|
368 |
-
|
369 |
-
|
370 |
-
} else {
|
371 |
-
$notice = $this->notice;
|
372 |
-
}
|
373 |
|
374 |
-
|
|
|
|
|
|
|
|
|
375 |
|
376 |
-
|
377 |
-
$notice .= '<p class="description" style="display:none;">' . implode( ', ', $this->data_we_collect() ) . '. No sensitive data is tracked. ';
|
378 |
-
$notice .= 'We are using Appsero to collect your data. <a href="' . $policy_url . '">Learn more</a> about how Appsero collects and handle your data.</p>';
|
379 |
|
380 |
-
|
381 |
-
|
382 |
-
|
383 |
-
echo ' <a href="' . esc_url( $optin_url ) . '" class="button-primary button-large">' . $this->client->__trans( 'Allow' ) . '</a>';
|
384 |
-
echo ' <a href="' . esc_url( $optout_url ) . '" class="button-secondary button-large">' . $this->client->__trans( 'No thanks' ) . '</a>';
|
385 |
-
echo '</p></div>';
|
386 |
|
387 |
-
|
388 |
-
|
389 |
-
|
390 |
-
|
391 |
-
|
392 |
-
|
393 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
394 |
}
|
395 |
|
396 |
/**
|
@@ -438,6 +450,8 @@ class Insights {
|
|
438 |
update_option( $this->client->slug . '_allow_tracking', 'no' );
|
439 |
update_option( $this->client->slug . '_tracking_notice', 'hide' );
|
440 |
|
|
|
|
|
441 |
$this->clear_schedule_event();
|
442 |
}
|
443 |
|
@@ -496,6 +510,14 @@ class Insights {
|
|
496 |
$wp_data['locale'] = get_locale();
|
497 |
$wp_data['version'] = get_bloginfo( 'version' );
|
498 |
$wp_data['multisite'] = is_multisite() ? 'Yes' : 'No';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
499 |
|
500 |
return $wp_data;
|
501 |
}
|
@@ -560,6 +582,10 @@ class Insights {
|
|
560 |
|
561 |
// Get user count based on user role
|
562 |
foreach ( $user_count_data['avail_roles'] as $role => $count ) {
|
|
|
|
|
|
|
|
|
563 |
$user_count[ $role ] = $count;
|
564 |
}
|
565 |
|
@@ -646,49 +672,49 @@ class Insights {
|
|
646 |
*/
|
647 |
private function get_uninstall_reasons() {
|
648 |
$reasons = array(
|
649 |
-
|
650 |
-
|
651 |
-
|
652 |
-
|
653 |
-
|
654 |
-
|
655 |
-
|
656 |
-
|
657 |
-
|
658 |
-
|
659 |
-
|
660 |
-
|
661 |
-
|
662 |
-
|
663 |
-
|
664 |
-
|
665 |
-
|
666 |
-
|
667 |
-
|
668 |
-
|
669 |
-
|
670 |
-
|
671 |
-
|
672 |
-
|
673 |
-
|
674 |
-
|
675 |
-
|
676 |
-
|
677 |
-
|
678 |
-
|
679 |
-
|
680 |
-
|
681 |
-
|
682 |
-
|
683 |
-
|
684 |
-
|
685 |
-
|
686 |
-
|
687 |
-
|
688 |
-
|
689 |
-
|
690 |
-
|
691 |
-
|
692 |
|
693 |
return $reasons;
|
694 |
}
|
@@ -703,31 +729,11 @@ class Insights {
|
|
703 |
if ( ! isset( $_POST['reason_id'] ) ) {
|
704 |
wp_send_json_error();
|
705 |
}
|
706 |
-
|
707 |
-
$
|
708 |
-
|
709 |
-
$data =
|
710 |
-
|
711 |
-
'reason_id' => sanitize_text_field( $_POST['reason_id'] ),
|
712 |
-
'reason_info' => isset( $_REQUEST['reason_info'] ) ? trim( stripslashes( $_REQUEST['reason_info'] ) ) : '',
|
713 |
-
'site' => $this->get_site_name(),
|
714 |
-
'url' => esc_url( home_url() ),
|
715 |
-
'admin_email' => get_option( 'admin_email' ),
|
716 |
-
'user_email' => $current_user->user_email,
|
717 |
-
'first_name' => $current_user->first_name,
|
718 |
-
'last_name' => $current_user->last_name,
|
719 |
-
'server' => $this->get_server_info(),
|
720 |
-
'wp' => $this->get_wp_info(),
|
721 |
-
'ip_address' => $this->get_user_ip_address(),
|
722 |
-
'theme' => get_stylesheet(),
|
723 |
-
'version' => $this->client->project_version,
|
724 |
-
);
|
725 |
-
|
726 |
-
// Add metadata
|
727 |
-
if ( $extra = $this->get_extra_data() ) {
|
728 |
-
$data['extra'] = $extra;
|
729 |
-
}
|
730 |
-
|
731 |
$this->client->send_request( $data, 'deactivate' );
|
732 |
|
733 |
wp_send_json_success();
|
@@ -763,8 +769,13 @@ class Insights {
|
|
763 |
<?php } ?>
|
764 |
</ul>
|
765 |
<p class="wd-dr-modal-reasons-bottom">
|
766 |
-
|
767 |
-
|
|
|
|
|
|
|
|
|
|
|
768 |
</p>
|
769 |
</div>
|
770 |
|
@@ -910,26 +921,7 @@ class Insights {
|
|
910 |
public function theme_deactivated( $new_name, $new_theme, $old_theme ) {
|
911 |
// Make sure this is appsero theme
|
912 |
if ( $old_theme->get_template() == $this->client->slug ) {
|
913 |
-
$
|
914 |
-
|
915 |
-
$data = array(
|
916 |
-
'hash' => $this->client->hash,
|
917 |
-
'reason_id' => 'none',
|
918 |
-
'reason_info' => '',
|
919 |
-
'site' => $this->get_site_name(),
|
920 |
-
'url' => esc_url( home_url() ),
|
921 |
-
'admin_email' => get_option( 'admin_email' ),
|
922 |
-
'user_email' => $current_user->user_email,
|
923 |
-
'first_name' => $current_user->first_name,
|
924 |
-
'last_name' => $current_user->last_name,
|
925 |
-
'server' => $this->get_server_info(),
|
926 |
-
'wp' => $this->get_wp_info(),
|
927 |
-
'ip_address' => $this->get_user_ip_address(),
|
928 |
-
'theme' => get_stylesheet(),
|
929 |
-
'version' => $this->client->project_version,
|
930 |
-
);
|
931 |
-
|
932 |
-
$this->client->send_request( $data, 'deactivate' );
|
933 |
}
|
934 |
}
|
935 |
|
@@ -969,4 +961,24 @@ class Insights {
|
|
969 |
|
970 |
return $site_name;
|
971 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
972 |
}
|
180 |
if ( $last_send && $last_send > strtotime( '-1 week' ) ) {
|
181 |
return;
|
182 |
}
|
183 |
+
|
184 |
+
$tracking_data = $this->get_tracking_data();
|
185 |
|
186 |
+
$response = $this->client->send_request( $tracking_data, 'track' );
|
187 |
|
188 |
update_option( $this->client->slug . '_tracking_last_send', time() );
|
189 |
}
|
213 |
}
|
214 |
|
215 |
$data = array(
|
|
|
216 |
'url' => esc_url( home_url() ),
|
217 |
'site' => $this->get_site_name(),
|
218 |
'admin_email' => get_option( 'admin_email' ),
|
225 |
'active_plugins' => count( $all_plugins['active_plugins'] ),
|
226 |
'inactive_plugins' => count( $all_plugins['inactive_plugins'] ),
|
227 |
'ip_address' => $this->get_user_ip_address(),
|
228 |
+
'project_version' => $this->client->project_version,
|
229 |
+
'tracking_skipped' => false,
|
230 |
);
|
231 |
|
232 |
// Add metadata
|
234 |
$data['extra'] = $extra;
|
235 |
}
|
236 |
|
237 |
+
// Check this has previously skipped tracking
|
238 |
+
$skipped = get_option( $this->client->slug . '_tracking_skipped' );
|
239 |
+
|
240 |
+
if ( $skipped === 'yes' ) {
|
241 |
+
delete_option( $this->client->slug . '_tracking_skipped' );
|
242 |
+
|
243 |
+
$data['tracking_skipped'] = true;
|
244 |
+
}
|
245 |
+
|
246 |
return apply_filters( $this->client->slug . '_tracker_data', $data );
|
247 |
}
|
248 |
|
266 |
/**
|
267 |
* Explain the user which data we collect
|
268 |
*
|
269 |
+
* @return array
|
270 |
*/
|
271 |
protected function data_we_collect() {
|
272 |
$data = array(
|
306 |
*
|
307 |
* @return boolean
|
308 |
*/
|
309 |
+
public function notice_dismissed() {
|
310 |
$hide_notice = get_option( $this->client->slug . '_tracking_notice', null );
|
311 |
|
312 |
if ( 'hide' == $hide_notice ) {
|
371 |
}
|
372 |
|
373 |
// don't show tracking if a local server
|
374 |
+
if ( $this->is_local_server() ) {
|
375 |
+
return;
|
376 |
+
}
|
377 |
|
378 |
+
$optin_url = add_query_arg( $this->client->slug . '_tracker_optin', 'true' );
|
379 |
+
$optout_url = add_query_arg( $this->client->slug . '_tracker_optout', 'true' );
|
|
|
|
|
|
|
380 |
|
381 |
+
if ( empty( $this->notice ) ) {
|
382 |
+
$notice = sprintf( $this->client->__trans( 'Want to help make <strong>%1$s</strong> even more awesome? Allow %1$s to collect non-sensitive diagnostic data and usage information.' ), $this->client->name );
|
383 |
+
} else {
|
384 |
+
$notice = $this->notice;
|
385 |
+
}
|
386 |
|
387 |
+
$policy_url = 'https://' . 'appsero.com/privacy-policy/';
|
|
|
|
|
388 |
|
389 |
+
$notice .= ' (<a class="' . $this->client->slug . '-insights-data-we-collect" href="#">' . $this->client->__trans( 'what we collect' ) . '</a>)';
|
390 |
+
$notice .= '<p class="description" style="display:none;">' . implode( ', ', $this->data_we_collect() ) . '. No sensitive data is tracked. ';
|
391 |
+
$notice .= 'We are using Appsero to collect your data. <a href="' . $policy_url . '">Learn more</a> about how Appsero collects and handle your data.</p>';
|
|
|
|
|
|
|
392 |
|
393 |
+
echo '<div class="updated"><p>';
|
394 |
+
echo $notice;
|
395 |
+
echo '</p><p class="submit">';
|
396 |
+
echo ' <a href="' . esc_url( $optin_url ) . '" class="button-primary button-large">' . $this->client->__trans( 'Allow' ) . '</a>';
|
397 |
+
echo ' <a href="' . esc_url( $optout_url ) . '" class="button-secondary button-large">' . $this->client->__trans( 'No thanks' ) . '</a>';
|
398 |
+
echo '</p></div>';
|
399 |
+
|
400 |
+
echo "<script type='text/javascript'>jQuery('." . $this->client->slug . "-insights-data-we-collect').on('click', function(e) {
|
401 |
+
e.preventDefault();
|
402 |
+
jQuery(this).parents('.updated').find('p.description').slideToggle('fast');
|
403 |
+
});
|
404 |
+
</script>
|
405 |
+
";
|
406 |
}
|
407 |
|
408 |
/**
|
450 |
update_option( $this->client->slug . '_allow_tracking', 'no' );
|
451 |
update_option( $this->client->slug . '_tracking_notice', 'hide' );
|
452 |
|
453 |
+
$this->send_tracking_skipped_request();
|
454 |
+
|
455 |
$this->clear_schedule_event();
|
456 |
}
|
457 |
|
510 |
$wp_data['locale'] = get_locale();
|
511 |
$wp_data['version'] = get_bloginfo( 'version' );
|
512 |
$wp_data['multisite'] = is_multisite() ? 'Yes' : 'No';
|
513 |
+
$wp_data['theme_slug'] = get_stylesheet();
|
514 |
+
|
515 |
+
$theme = wp_get_theme( $wp_data['theme_slug'] );
|
516 |
+
|
517 |
+
$wp_data['theme_name'] = $theme->get( 'Name' );
|
518 |
+
$wp_data['theme_version'] = $theme->get( 'Version' );
|
519 |
+
$wp_data['theme_uri'] = $theme->get( 'ThemeURI' );
|
520 |
+
$wp_data['theme_author'] = $theme->get( 'Author' );
|
521 |
|
522 |
return $wp_data;
|
523 |
}
|
582 |
|
583 |
// Get user count based on user role
|
584 |
foreach ( $user_count_data['avail_roles'] as $role => $count ) {
|
585 |
+
if ( ! $count ) {
|
586 |
+
continue;
|
587 |
+
}
|
588 |
+
|
589 |
$user_count[ $role ] = $count;
|
590 |
}
|
591 |
|
672 |
*/
|
673 |
private function get_uninstall_reasons() {
|
674 |
$reasons = array(
|
675 |
+
array(
|
676 |
+
'id' => 'could-not-understand',
|
677 |
+
'text' => $this->client->__trans( "I couldn't understand how to make it work" ),
|
678 |
+
'type' => 'textarea',
|
679 |
+
'placeholder' => $this->client->__trans( 'Would you like us to assist you?' )
|
680 |
+
),
|
681 |
+
array(
|
682 |
+
'id' => 'found-better-plugin',
|
683 |
+
'text' => $this->client->__trans( 'I found a better plugin' ),
|
684 |
+
'type' => 'text',
|
685 |
+
'placeholder' => $this->client->__trans( 'Which plugin?' )
|
686 |
+
),
|
687 |
+
array(
|
688 |
+
'id' => 'not-have-that-feature',
|
689 |
+
'text' => $this->client->__trans( "The plugin is great, but I need specific feature that you don't support" ),
|
690 |
+
'type' => 'textarea',
|
691 |
+
'placeholder' => $this->client->__trans( 'Could you tell us more about that feature?' )
|
692 |
+
),
|
693 |
+
array(
|
694 |
+
'id' => 'is-not-working',
|
695 |
+
'text' => $this->client->__trans( 'The plugin is not working' ),
|
696 |
+
'type' => 'textarea',
|
697 |
+
'placeholder' => $this->client->__trans( 'Could you tell us a bit more whats not working?' )
|
698 |
+
),
|
699 |
+
array(
|
700 |
+
'id' => 'looking-for-other',
|
701 |
+
'text' => $this->client->__trans( "It's not what I was looking for" ),
|
702 |
+
'type' => '',
|
703 |
+
'placeholder' => ''
|
704 |
+
),
|
705 |
+
array(
|
706 |
+
'id' => 'did-not-work-as-expected',
|
707 |
+
'text' => $this->client->__trans( "The plugin didn't work as expected" ),
|
708 |
+
'type' => 'textarea',
|
709 |
+
'placeholder' => $this->client->__trans( 'What did you expect?' )
|
710 |
+
),
|
711 |
+
array(
|
712 |
+
'id' => 'other',
|
713 |
+
'text' => $this->client->__trans( 'Other' ),
|
714 |
+
'type' => 'textarea',
|
715 |
+
'placeholder' => $this->client->__trans( 'Could you tell us a bit more?' )
|
716 |
+
),
|
717 |
+
);
|
718 |
|
719 |
return $reasons;
|
720 |
}
|
729 |
if ( ! isset( $_POST['reason_id'] ) ) {
|
730 |
wp_send_json_error();
|
731 |
}
|
732 |
+
|
733 |
+
$data = $this->get_tracking_data();
|
734 |
+
$data['reason_id'] = sanitize_text_field( $_POST['reason_id'] );
|
735 |
+
$data['reason_info'] = isset( $_REQUEST['reason_info'] ) ? trim( stripslashes( $_REQUEST['reason_info'] ) ) : '';
|
736 |
+
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
737 |
$this->client->send_request( $data, 'deactivate' );
|
738 |
|
739 |
wp_send_json_success();
|
769 |
<?php } ?>
|
770 |
</ul>
|
771 |
<p class="wd-dr-modal-reasons-bottom">
|
772 |
+
<?php
|
773 |
+
echo sprintf(
|
774 |
+
$this->client->__trans( 'We share your data with <a href="%1$s" target="_blank">Appsero</a> to troubleshoot problems & make product improvements. <a href="%2$s" target="_blank">Learn more</a> about how Appsero handles your data.'),
|
775 |
+
esc_url( 'https://appsero.com/' ),
|
776 |
+
esc_url( 'https://appsero.com/privacy-policy' )
|
777 |
+
);
|
778 |
+
?>
|
779 |
</p>
|
780 |
</div>
|
781 |
|
921 |
public function theme_deactivated( $new_name, $new_theme, $old_theme ) {
|
922 |
// Make sure this is appsero theme
|
923 |
if ( $old_theme->get_template() == $this->client->slug ) {
|
924 |
+
$this->client->send_request( $this->get_tracking_data(), 'deactivate' );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
925 |
}
|
926 |
}
|
927 |
|
961 |
|
962 |
return $site_name;
|
963 |
}
|
964 |
+
|
965 |
+
/**
|
966 |
+
* Send request to appsero if user skip to send tracking data
|
967 |
+
*/
|
968 |
+
private function send_tracking_skipped_request() {
|
969 |
+
$skipped = get_option( $this->client->slug . '_tracking_skipped' );
|
970 |
+
|
971 |
+
$data = [
|
972 |
+
'hash' => $this->client->hash,
|
973 |
+
'previously_skipped' => false,
|
974 |
+
];
|
975 |
+
|
976 |
+
if ( $skipped === 'yes' ) {
|
977 |
+
$data['previously_skipped'] = true;
|
978 |
+
} else {
|
979 |
+
update_option( $this->client->slug . '_tracking_skipped', 'yes' );
|
980 |
+
}
|
981 |
+
|
982 |
+
$this->client->send_request( $data, 'tracking-skipped' );
|
983 |
+
}
|
984 |
}
|
public/class-wpvr-public.php
CHANGED
@@ -86,18 +86,21 @@ class Wpvr_Public {
|
|
86 |
$current_url = home_url(add_query_arg(array($_GET), $wp->request));
|
87 |
|
88 |
if ($wpvr_script_control == 'true') {
|
|
|
89 |
foreach ($allowed_pages_modified as $value) {
|
90 |
-
if (
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
|
95 |
-
|
96 |
-
|
97 |
-
|
98 |
-
|
99 |
-
|
100 |
-
|
|
|
|
|
101 |
}
|
102 |
}
|
103 |
}
|
@@ -612,8 +615,8 @@ class Wpvr_Public {
|
|
612 |
if (wpvr_isMobileDevice()) {
|
613 |
$src_to_id_for_mobile = attachment_url_to_postid($panoscenes['scene-attachment-url']);
|
614 |
if ($src_to_id_for_mobile) {
|
615 |
-
$mobile_scene = wp_get_attachment_image_src($src_to_id_for_mobile, '
|
616 |
-
if ($mobile_scene[
|
617 |
$device_scene = $mobile_scene[0];
|
618 |
}
|
619 |
}
|
@@ -1217,6 +1220,30 @@ class Wpvr_Public {
|
|
1217 |
});';
|
1218 |
}
|
1219 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1220 |
$html .= '});';
|
1221 |
|
1222 |
$html .= '</script>';
|
86 |
$current_url = home_url(add_query_arg(array($_GET), $wp->request));
|
87 |
|
88 |
if ($wpvr_script_control == 'true') {
|
89 |
+
|
90 |
foreach ($allowed_pages_modified as $value) {
|
91 |
+
if ($value) {
|
92 |
+
if (strpos($current_url, $value) !== false) {
|
93 |
+
$fontawesome_disable = get_option('wpvr_fontawesome_disable');
|
94 |
+
if ($fontawesome_disable == 'true') {
|
95 |
+
}
|
96 |
+
else {
|
97 |
+
wp_enqueue_style( $this->plugin_name . 'fontawesome', 'https://use.fontawesome.com/releases/v5.7.2/css/all.css', array(), $this->version, 'all' );
|
98 |
+
}
|
99 |
+
wp_enqueue_style('panellium-css', plugin_dir_url( __FILE__ ) . 'lib/pannellum/src/css/pannellum.css', array(), true);
|
100 |
+
wp_enqueue_style('videojs-css', plugin_dir_url( __FILE__ ) . 'lib/pannellum/src/css/video-js.css', array(), true);
|
101 |
+
wp_enqueue_style( 'owl-css', plugin_dir_url( __FILE__ ) . 'css/owl.carousel.css', array(), $this->version, 'all' );
|
102 |
+
wp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/wpvr-public.css', array(), $this->version, 'all' );
|
103 |
+
}
|
104 |
}
|
105 |
}
|
106 |
}
|
615 |
if (wpvr_isMobileDevice()) {
|
616 |
$src_to_id_for_mobile = attachment_url_to_postid($panoscenes['scene-attachment-url']);
|
617 |
if ($src_to_id_for_mobile) {
|
618 |
+
$mobile_scene = wp_get_attachment_image_src($src_to_id_for_mobile, 'wpvr_mobile');
|
619 |
+
if ($mobile_scene[3]) {
|
620 |
$device_scene = $mobile_scene[0];
|
621 |
}
|
622 |
}
|
1220 |
});';
|
1221 |
}
|
1222 |
|
1223 |
+
$html .= '
|
1224 |
+
jQuery(".elementor-tab-title").click(function(){
|
1225 |
+
jQuery("#pano'.$id.'").children(".pnlm-render-container").remove();
|
1226 |
+
jQuery("#pano'.$id.'").children(".pnlm-ui").remove();
|
1227 |
+
console.log(jQuery("#pano'.$id.'").children(".pnlm-render-container"));
|
1228 |
+
panoshow'.$id.' = pannellum.viewer(response[0]["panoid"], scenes);
|
1229 |
+
setTimeout(function() {
|
1230 |
+
panoshow'.$id.'.loadScene("'.$default_scene.'");
|
1231 |
+
}, 2000);
|
1232 |
+
});
|
1233 |
+
';
|
1234 |
+
|
1235 |
+
// $html .= '
|
1236 |
+
// jQuery(".elementor-tab-title").click(function(){
|
1237 |
+
// panoshow'.$id.'.destroy();
|
1238 |
+
// panoshow'.$id.' = pannellum.viewer(response[0]["panoid"], scenes);
|
1239 |
+
// panoshow'.$id.'.resize();
|
1240 |
+
// panoshow'.$id.'.loadScene("'.$default_scene.'");
|
1241 |
+
// jQuery(".pnlm-ui").empty();
|
1242 |
+
// jQuery("pnlm-render-container").empty();
|
1243 |
+
//
|
1244 |
+
// });
|
1245 |
+
// ';
|
1246 |
+
|
1247 |
$html .= '});';
|
1248 |
|
1249 |
$html .= '</script>';
|
public/css/wpvr-public.css
CHANGED
@@ -50,7 +50,7 @@
|
|
50 |
margin: 0 auto;
|
51 |
}
|
52 |
.cp-logo-ctrl img {
|
53 |
-
max-width: 100px;
|
54 |
margin-left: auto;
|
55 |
display: block;
|
56 |
}
|
50 |
margin: 0 auto;
|
51 |
}
|
52 |
.cp-logo-ctrl img {
|
53 |
+
max-width: 100px !important;
|
54 |
margin-left: auto;
|
55 |
display: block;
|
56 |
}
|
wpvr.php
CHANGED
@@ -16,7 +16,7 @@
|
|
16 |
* Plugin Name: WP VR
|
17 |
* Plugin URI: https://rextheme.com/wpvr/
|
18 |
* Description: WP VR - 360 Panorama and virtual tour creator for WordPress is a customized panaroma & virtual builder tool for WordPress Website.
|
19 |
-
* Version: 6.
|
20 |
* Author: Rextheme
|
21 |
* Author URI: http://rextheme.com/
|
22 |
* License: GPL-2.0+
|
@@ -571,12 +571,6 @@ function wpvr_block_render( $attributes ) {
|
|
571 |
if ($mobile_scene[3]) {
|
572 |
$device_scene = $mobile_scene[0];
|
573 |
}
|
574 |
-
else {
|
575 |
-
$mobile_scene = wp_get_attachment_image_src($src_to_id_for_mobile, 'large');
|
576 |
-
if ($mobile_scene[3]) {
|
577 |
-
$device_scene = $mobile_scene[0];
|
578 |
-
}
|
579 |
-
}
|
580 |
}
|
581 |
}
|
582 |
else {
|
16 |
* Plugin Name: WP VR
|
17 |
* Plugin URI: https://rextheme.com/wpvr/
|
18 |
* Description: WP VR - 360 Panorama and virtual tour creator for WordPress is a customized panaroma & virtual builder tool for WordPress Website.
|
19 |
+
* Version: 6.5.0
|
20 |
* Author: Rextheme
|
21 |
* Author URI: http://rextheme.com/
|
22 |
* License: GPL-2.0+
|
571 |
if ($mobile_scene[3]) {
|
572 |
$device_scene = $mobile_scene[0];
|
573 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
574 |
}
|
575 |
}
|
576 |
else {
|