nginx_helper_default_settings() ); $site_options = get_site_option( 'rt_wp_nginx_helper_options', array() ); foreach ( $nginx_helper_admin->nginx_helper_default_settings() as $default_setting_field => $default_setting_value ) { // Uncheck checkbox fields whose default value is `1` but user has unchecked. if ( 1 === $default_setting_value && isset( $site_options[ $default_setting_field ] ) && empty( $all_inputs[ $default_setting_field ] ) ) { $nginx_settings[ $default_setting_field ] = 0; } // Populate the setting field with default value when it is empty. if ( '' === $nginx_settings[ $default_setting_field ] ) { $nginx_settings[ $default_setting_field ] = $default_setting_value; } } if ( ( ! is_numeric( $nginx_settings['log_filesize'] ) ) || ( empty( $nginx_settings['log_filesize'] ) ) ) { $error_log_filesize = __( 'Log file size must be a number.', 'nginx-helper' ); unset( $nginx_settings['log_filesize'] ); } if ( $nginx_settings['enable_map'] ) { $nginx_helper_admin->update_map(); } update_site_option( 'rt_wp_nginx_helper_options', $nginx_settings ); echo '

' . esc_html__( 'Settings saved.', 'nginx-helper' ) . '

'; } $nginx_helper_settings = $nginx_helper_admin->nginx_helper_settings(); $log_path = $nginx_helper_admin->functional_asset_path(); $log_url = $nginx_helper_admin->functional_asset_url(); /** * Get setting url for single multiple with subdomain OR multiple with subdirectory site. */ $nginx_setting_link = '#'; if ( is_multisite() ) { if ( SUBDOMAIN_INSTALL === false ) { $nginx_setting_link = 'https://easyengine.io/wordpress-nginx/tutorials/multisite/subdirectories/fastcgi-cache-with-purging/'; } else { $nginx_setting_link = 'https://easyengine.io/wordpress-nginx/tutorials/multisite/subdomains/fastcgi-cache-with-purging/'; } } else { $nginx_setting_link = 'https://easyengine.io/wordpress-nginx/tutorials/single-site/fastcgi-cache-with-purging/'; } ?>

/>
>

 

/>
is_nginx_log_enabled(), true ); ?> />
/>
is_nginx_log_enabled() ) ? ' style="display: none;"' : ''; ?>>


'; echo wp_kses( sprintf( // translators: %s file url. __( 'Check you have write permission on %s', 'nginx-helper' ), esc_url( $log_path . 'nginx.log' ) ), array( 'strong' => array() ) ); ?>