array( 'active' => isset( $_POST['statifyblacklist']['referer']['active'] ) ? (int) $_POST['statifyblacklist']['referer']['active'] : 0, 'cron' => isset( $_POST['statifyblacklist']['referer']['cron'] ) ? (int) $_POST['statifyblacklist']['referer']['cron'] : 0, 'regexp' => isset( $_POST['statifyblacklist']['referer']['regexp'] ) ? (int) $_POST['statifyblacklist']['referer']['regexp'] : 0, 'blacklist' => array_flip( $referer ), ), 'target' => array( 'active' => isset( $_POST['statifyblacklist']['target']['active'] ) ? (int) $_POST['statifyblacklist']['target']['active'] : 0, 'cron' => isset( $_POST['statifyblacklist']['target']['cron'] ) ? (int) $_POST['statifyblacklist']['target']['cron'] : 0, 'regexp' => isset( $_POST['statifyblacklist']['target']['regexp'] ) ? (int) $_POST['statifyblacklist']['target']['regexp'] : 0, 'blacklist' => array_flip( $target ), ), 'ip' => array( 'active' => isset( $_POST['statifyblacklist']['ip']['active'] ) ? (int) $_POST['statifyblacklist']['ip']['active'] : 0, 'blacklist' => $ip, ), 'version' => StatifyBlacklist::VERSION_MAIN, ) ); // Generate messages. if ( false !== $statifyblacklist_update_result ) { $statifyblacklist_post_warning = array(); if ( ! empty( $statifyblacklist_update_result['referer']['diff'] ) ) { $statifyblacklist_post_warning[] = __( 'Some URLs are invalid and have been sanitized.', 'statify-blacklist' ); } if ( ! empty( $statifyblacklist_update_result['referer']['invalid'] ) ) { $statifyblacklist_post_warning[] = __( 'Some regular expressions are invalid:', 'statify-blacklist' ) . '
' . implode( '
', $statifyblacklist_update_result['referer']['invalid'] ); } if ( ! empty( $statifyblacklist_update_result['ip']['diff'] ) ) { // translators: List of invalid IP addresses (comma separated). $statifyblacklist_post_warning[] = sprintf( __( 'Some IPs are invalid: %s', 'statify-blacklist' ), implode( ', ', $statifyblacklist_update_result['ip']['diff'] ) ); } } else { $statifyblacklist_post_success = __( 'Settings updated successfully.', 'statify-blacklist' ); } } } /* * Disable some code style rules that are impractical for textarea content: * * phpcs:disable Squiz.PHP.EmbeddedPhp.ContentBeforeOpen * phpcs:disable Squiz.PHP.EmbeddedPhp.ContentAfterEnd */ ?>

'; esc_html_e( 'Statify plugin is not active.', 'statify-blacklist' ); print '

'; } if ( isset( $statifyblacklist_post_warning ) ) { foreach ( $statifyblacklist_post_warning as $w ) { print '

' . wp_kses( $w, array( 'br' => array() ) ) . '

'; } print '

' . esc_html__( 'Settings have not been saved yet.', 'statify-blacklist' ) . '

'; } if ( isset( $statifyblacklist_post_success ) ) { print '

' . esc_html( $statifyblacklist_post_success ) . '

'; } ?>

>

>

-
-
-

>

>

-
-
-

( /, /test/page/, /?page_id=123)

>


:

127.0.0.1, 192.168.123.0/24, 2001:db8:a0b:12f0::1/64