PluginProbe ʕ •ᴥ•ʔ
Backup Migration / 2.1.7
Backup Migration v2.1.7
2.1.7 2.1.6 2.1.5.2 trunk 1.3.0 1.3.1 1.3.2 1.3.3 1.3.4 1.3.5 1.3.6 1.3.7 1.3.8 1.3.9 1.4.0 1.4.1 1.4.2 1.4.3 1.4.4 1.4.5 1.4.6 1.4.6.1 1.4.7 1.4.8 1.4.9 1.4.9.1 2.0.0 2.1.0 2.1.1 2.1.2 2.1.3 2.1.4 2.1.5 2.1.5.1
backup-backup / analyst / templates / forms / install.php
backup-backup / analyst / templates / forms Last commit date
deactivate.php 2 weeks ago install.php 2 weeks ago
install.php
119 lines
1 <?php if ( ! defined( 'ABSPATH' ) ) exit; ?>
2 <div id="analyst-install-modal" class="analyst-modal" style="display: none" analyst-plugin-id="<?php echo esc_attr( $pluginToInstall ); ?>">
3 <div class="analyst-modal-content" style="width: 450px">
4 <div class="analyst-disable-modal-mask" id="analyst-disable-install-modal-mask" style="display: none"></div>
5 <div style="display: flex">
6 <div class="analyst-install-image-block">
7 <img src="<?php echo esc_url( $shieldImage ); ?>"/>
8 </div>
9 <div class="analyst-install-description-block">
10 <strong class="analyst-modal-header">Stay on the safe side</strong>
11 <p class="analyst-install-description-text">Receive our plugin’s alerts in
12 case of <strong>critical security</strong>, feature & special deal
13 updates and allow non-sensitive
14 diagnostic tracking.</p>
15 </div>
16 </div>
17 <div class="analyst-modal-def-top-padding">
18 <button class="analyst-btn-success" id="analyst-install-action">Allow & Continue &gt;</button>
19 </div>
20 <div class="analyst-modal-def-top-padding" id="analyst-permissions-block" style="display: none">
21 <span>You’re granting these permissions:</span>
22 <ul class="analyst-install-permissions-list">
23 <li><strong>Your profile information</strong> (name and email) </li>
24 <li><strong>Your site information</strong> (URL, WP version, PHP info, plugins & themes)</li>
25 <li><strong>Plugin notices</strong> (updates, announcements, marketing, no spam)</li>
26 <li><strong>Plugin events</strong> (activation, deactivation and uninstall)</li>
27 </ul>
28 </div>
29 <div class="analyst-install-footer analyst-modal-def-top-padding">
30 <span class="analyst-action-text" id="analyst-permissions-toggle">Learn more</span>
31 <span id="analyst-powered-by" style="display: none;">Powered by <a href="https://sellcodes.com/blog/wordpress-feedback-system-for-plugin-creators/?utm_source=optin_screen" target="_blank" class="analyst-link">Sellcodes.com</a></span>
32 <span class="analyst-action-text analyst-install-modal-close" id="analyst-install-skip">Skip</span>
33 </div>
34 <div id="analyst-install-error" class="analyst-modal-def-top-padding" style="display: none; text-align: center">
35 <span style="color: #dc3232; font-size: 16px">Service unavailable. Please try again later</span>
36 </div>
37 </div>
38 </div>
39
40 <script type="text/javascript">
41 (function ($) {
42
43 var installPlugin = function (pluginId) {
44 var $error = $('#analyst-install-error')
45
46 $error.hide()
47
48 $.ajax({
49 url: ajaxurl,
50 method: 'POST',
51 data: {
52 action: 'analyst_install_' + pluginId,
53 analyst_nonce: analyst_opt_localize.analyst_nonce
54 },
55 success: function (data) {
56 if (data && !data.success) {
57 //error
58 $('#analyst-install-modal').hide()
59
60 return
61 }
62
63 window.location.reload()
64 },
65 error: function () {
66 $('#analyst-install-modal').hide()
67 }
68 }).done(function () {
69 $('#analyst-disable-install-modal-mask').hide()
70
71 $('#analyst-install-action')
72 .attr('disabled', false)
73 .text('Allow & Continue >')
74 })
75 }
76
77 if ($('#analyst-install-modal').attr('analyst-plugin-id')) {
78 $('#analyst-install-modal').show()
79 }
80
81
82 $('.analyst-install-modal-close').click(function () {
83 $('#analyst-install-modal').hide()
84 })
85
86 $('#analyst-install-action').click(function () {
87 var pluginId = $('#analyst-install-modal').attr('analyst-plugin-id')
88
89 $('#analyst-install-action')
90 .attr('disabled', true)
91 .text('Please wait...')
92
93 $('#analyst-disable-install-modal-mask').show()
94
95 installPlugin(pluginId)
96 })
97
98 $('#analyst-permissions-toggle').click(function () {
99 var isVisible = $('#analyst-permissions-block').toggle().is(':visible')
100
101 isVisible ? $(this).text('Close section') : $(this).text('Learn more')
102
103 var poweredBy = $('#analyst-powered-by')
104 isVisible ? poweredBy.show() : poweredBy.hide()
105 })
106
107 $('#analyst-install-skip').click(function () {
108 var pluginId = $('#analyst-install-modal').attr('analyst-plugin-id')
109
110 $.post(ajaxurl, {
111 action: 'analyst_skip_install_' + pluginId,
112 analyst_nonce: analyst_opt_localize.analyst_nonce
113 }).done(function () {
114 $('#analyst-install-modal').hide()
115 })
116 })
117 })(jQuery)
118 </script>
119