backup-ongoing.php
11 months ago
backup_controller.php
11 months ago
backups-table-header.php
11 months ago
backups-under-table.php
11 months ago
before-update-backup-errors.php
11 months ago
email-errors.php
11 months ago
quota-errors.php
11 months ago
security-plugins-warning.php
11 months ago
super-quick-migration.php
11 months ago
support-chat.php
11 months ago
upload-backup.php
11 months ago
security-plugins-warning.php
55 lines
| 1 | <?php |
| 2 | |
| 3 | // Namespace |
| 4 | namespace BMI\Plugin\Dashboard; |
| 5 | use BMI\Plugin\Backup_Migration_Plugin AS BMP; |
| 6 | |
| 7 | // Exit on direct access |
| 8 | if (!defined('ABSPATH')) exit; |
| 9 | |
| 10 | $securityPlugins = BMP::get_active_security_plugins(); |
| 11 | |
| 12 | if (empty($securityPlugins)) { |
| 13 | return; |
| 14 | } |
| 15 | |
| 16 | if (get_option('bmi_security_warning_dismiss', false) == true) { |
| 17 | return; |
| 18 | } |
| 19 | // add to the key value <b></b> to make it bold |
| 20 | array_walk($securityPlugins, function(&$plugin) { |
| 21 | $plugin = '<b style="display: inline-block">' . esc_html($plugin) . '</b>'; |
| 22 | }); |
| 23 | $pluginsList = implode(', ', $securityPlugins); |
| 24 | |
| 25 | |
| 26 | ?> |
| 27 | |
| 28 | |
| 29 | <div class="error-noticer warn" id="security-plugin-warning"> |
| 30 | <div class="error-header"> |
| 31 | <div class="cf"> |
| 32 | <div class="left"> |
| 33 | <?php _e('Security Restrictions May Affect Backup or Download', 'backup-backup'); ?> |
| 34 | </div> |
| 35 | <div class="right hoverable"> |
| 36 | <span class="bmi-error-toggle" data-expand="<?php _e('Expand', 'backup-backup'); ?>" data-collapse="<?php _e('Collapse', 'backup-backup'); ?>"> |
| 37 | <?php _e('Expand', 'backup-backup'); ?> |
| 38 | </span> | |
| 39 | <span id="bmi-error-dismiss"> |
| 40 | <?php _e('Dismiss', 'backup-backup'); ?> |
| 41 | </span> |
| 42 | </div> |
| 43 | </div> |
| 44 | </div> |
| 45 | <div class="error-body"> |
| 46 | <?php |
| 47 | $errorBody = sprintf( |
| 48 | __('We noticed you\'re using %s. Security plugins can sometimes block backup creation or backup download process, depending on how strict their settings are. In such cases, you can either whitelist Backup Migration plugin, ease up on restrictions or just temporarily disable security plugins, until backups/migrations are performed.', 'backup-backup'), |
| 49 | $pluginsList |
| 50 | ); |
| 51 | _e($errorBody, 'backup-backup'); |
| 52 | ?> |
| 53 | </div> |
| 54 | </div> |
| 55 |