share
8 years ago
.htaccess
11 years ago
anti_malware.php
4 years ago
class-coupon.php
6 months ago
class-email-sodium.php
3 weeks ago
class-firewall-log.php
1 week ago
class-helpers.php
7 months ago
class-import-export.php
3 months ago
class-ip.php
4 months ago
class-nfw-database.php
6 months ago
class-nfw-session.php
1 week ago
class-php-session.php
1 year ago
class-plugin-upgrade.php
1 week ago
class_mail.php
3 weeks ago
event_updates.php
9 months ago
firewall.php
4 months ago
fw_centlog.php
1 week ago
fw_fileguard.php
4 months ago
fw_livelog.php
1 year ago
help.php
3 weeks ago
helpers.php
1 week ago
i18n-extra.php
3 weeks ago
i18n.php
1 year ago
index.html
13 years ago
init_update.php
1 year ago
install.php
1 year ago
install_default.php
6 months ago
loader.php
6 months ago
mail_template_firewall.php
1 year ago
mail_template_plugin.php
1 month ago
scheduled_tasks.php
3 years ago
settings_dashboard.php
1 month ago
settings_dashboard_about.php
3 weeks ago
settings_dashboard_statistics.php
1 month ago
settings_event_notifications.php
1 month ago
settings_events.php
1 month ago
settings_firewall_options.php
1 month ago
settings_firewall_policies.php
1 week ago
settings_login_protection.php
1 month ago
settings_logs.php
1 month ago
settings_logs_firewall_log.php
3 weeks ago
settings_logs_live_log.php
1 month ago
settings_monitoring.php
3 weeks ago
settings_monitoring_file_check.php
1 month ago
settings_monitoring_file_guard.php
1 month ago
settings_network.php
1 month ago
settings_security_rules.php
1 month ago
settings_security_rules_editor.php
1 month ago
settings_security_rules_update.php
1 week ago
sign.pub
7 years ago
thickbox.php
4 years ago
widget.php
3 years ago
wpplus.php
3 months ago
settings_network.php
84 lines
| 1 | <?php |
| 2 | /* |
| 3 | +---------------------------------------------------------------------+ |
| 4 | | NinjaFirewall (WP Edition) | |
| 5 | | | |
| 6 | | (c) NinTechNet - https://nintechnet.com/ | |
| 7 | +---------------------------------------------------------------------+ |
| 8 | | This program is free software: you can redistribute it and/or | |
| 9 | | modify it under the terms of the GNU General Public License as | |
| 10 | | published by the Free Software Foundation, either version 3 of | |
| 11 | | the License, or (at your option) any later version. | |
| 12 | | | |
| 13 | | This program is distributed in the hope that it will be useful, | |
| 14 | | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
| 15 | | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
| 16 | | GNU General Public License for more details. | |
| 17 | +---------------------------------------------------------------------+ i18n+ / sa / 2 |
| 18 | */ |
| 19 | |
| 20 | if (! defined( 'NFW_ENGINE_VERSION' ) ) { die( 'Forbidden' ); } |
| 21 | |
| 22 | if (! current_user_can( 'manage_network' ) ) { |
| 23 | die( '<br /><br /><br /><div class="error notice is-dismissible"><p>' . |
| 24 | sprintf( __('You are not allowed to perform this task (%s).', 'ninjafirewall'), __LINE__) . |
| 25 | '</p></div>' ); |
| 26 | } |
| 27 | |
| 28 | $nfw_options = nfw_get_option( 'nfw_options' ); |
| 29 | |
| 30 | echo ' |
| 31 | <div class="wrap"> |
| 32 | <h1><img style="vertical-align:top;width:33px;height:33px;" src="'. plugins_url( '/ninjafirewall/images/ninjafirewall_32.png' ) .'"> ' . __('Network', 'ninjafirewall') . '</h1>'; |
| 33 | |
| 34 | if (! is_multisite() ) { |
| 35 | echo '<div class="updated notice is-dismissible"><p>' . __('You do not have a multisite network.', 'ninjafirewall') . '</p></div></div>'; |
| 36 | return; |
| 37 | } |
| 38 | |
| 39 | // Saved? |
| 40 | if (! empty( $_POST['nf-network'] ) ) { |
| 41 | |
| 42 | if ( empty($_POST['nfwnonce']) || ! wp_verify_nonce($_POST['nfwnonce'], 'network_save') ) { |
| 43 | wp_nonce_ays('network_save'); |
| 44 | } |
| 45 | if ( empty( $_POST['nfw_options']['nt_show_status'] ) ) { |
| 46 | $nfw_options['nt_show_status'] = 2; |
| 47 | } else { |
| 48 | $nfw_options['nt_show_status'] = 1; |
| 49 | } |
| 50 | // Update options |
| 51 | nfw_update_option( 'nfw_options', $nfw_options ); |
| 52 | echo '<div class="updated notice is-dismissible"><p>' . __('Your changes have been saved.', 'ninjafirewall') . '</p></div>'; |
| 53 | $nfw_options = nfw_get_option( 'nfw_options' ); |
| 54 | } |
| 55 | |
| 56 | if ( empty( $nfw_options['nt_show_status'] ) || $nfw_options['nt_show_status'] == 2 ) { |
| 57 | $nt_show_status = 0; |
| 58 | } else { |
| 59 | $nt_show_status = 1; |
| 60 | } |
| 61 | ?> |
| 62 | <br /> |
| 63 | <form method="post" name="nfwnetwork"> |
| 64 | <?php wp_nonce_field('network_save', 'nfwnonce', 0); ?> |
| 65 | <h3><?php _e('NinjaFirewall Status', 'ninjafirewall') ?></h3> |
| 66 | <table class="form-table nfw-table"> |
| 67 | <tr> |
| 68 | <th scope="row" class="row-med"><?php _e('Display NinjaFirewall status icon in the WordPress ToolBar of all sites in the network', 'ninjafirewall') ?></th> |
| 69 | <td> |
| 70 | <?php nfw_toggle_switch( 'info', 'nfw_options[nt_show_status]', __('Yes', 'ninjafirewall'), __('No', 'ninjafirewall'), 'small', $nt_show_status ) ?> |
| 71 | </td> |
| 72 | </tr> |
| 73 | </table> |
| 74 | |
| 75 | <br /> |
| 76 | <br /> |
| 77 | <input class="button-primary" type="submit" name="Save" value="<?php _e('Save Network options', 'ninjafirewall') ?>" /> |
| 78 | <input type="hidden" name="nf-network" value="1" /> |
| 79 | </form> |
| 80 | </div> |
| 81 | <?php |
| 82 | // --------------------------------------------------------------------- |
| 83 | // EOF |
| 84 |