e_settings_for_all_sites' ) && C4WP_Functions::c4wp_same_settings_for_all_sites() ) ? true : false; if ( $append_link || ! is_multisite() ) { array_unshift( $links, $settings_link ); } return $links; } /** * Includs help page content. * * @return void */ public static function display_help_page() { require_once 'templates/help/index.php'; } /** * Includs upgrade page content. * * @return void */ public static function display_upgrade_page() { require_once 'templates/upgrade/index.php'; } /** * Help function to push an item to an associate array. * * @param array $array - Original array. * @param string $key - new item key. * @param string $new - New item svalue. * @return array $array - Updated array. */ public static function push_at_to_associative_array( $array, $key, $new ) { $keys = array_keys( $array ); $index = array_search( $key, $keys, true ); $pos = false === $index ? count( $array ) : $index + 1; $array = array_slice( $array, 0, $pos, true ) + $new + array_slice( $array, $pos, count( $array ) - 1, true ); return $array; } /** * Ignore admin notice. * * @return void */ public static function c4wp_nocaptcha_plugin_notice_ignore() { $posted = filter_input_array( INPUT_POST ); // Grab POSTed data. $nonce = sanitize_text_field( $posted[ 'nonce' ] ); $notice_type = sanitize_text_field( $posted[ 'notice_type' ] ); // Check nonce. if ( empty( $nonce ) || ! wp_verify_nonce( $nonce, 'dismiss_captcha_notice' ) ) { wp_send_json_error( esc_html__( 'Nonce Verification Failed.', 'advanced-nocaptcha-recaptcha' ) ); } if ( 'multisite' == $notice_type ) { global $current_user; $user_id = $current_user->ID; $updated = add_user_meta( $user_id, 'nocaptcha_plugin_notice_ignore', 'true', true ); if ( method_exists( 'C4WP\\C4WP_Functions', 'c4wp_same_settings_for_all_sites' ) && C4WP_Functions::c4wp_same_settings_for_all_sites() ) { update_site_option( 'c4wp_network_notice_dismissed', true ); } else { update_option( 'c4wp_network_notice_dismissed', true ); } wp_send_json_success( $updated ); } elseif ( 'v3_fallback' == $notice_type ) { if ( method_exists( 'C4WP\\C4WP_Functions', 'c4wp_same_settings_for_all_sites' ) && C4WP_Functions::c4wp_same_settings_for_all_sites() ) { update_site_option( 'c4wp_v3_failover_available', false ); } else { update_option( 'c4wp_v3_failover_available', false ); } } wp_send_json_success(); } /** * Handles markup of the popup settings wizard. * * @return $markup - HTML markup. */ public static function wizard_markup() { $fields = self::get_fields(); // Add intro card if this is running in 'first time' mode. $show_wizard_intro = ( empty( C4WP_Functions::c4wp_get_option( 'captcha_version' ) ) && empty( $site_key ) && empty( $secret_key ) ) ? true : false; $logo_url = C4WP_PLUGIN_URL . 'assets/img/c4wp-logo-full.png'; $settings_url = method_exists( 'C4WP\\C4WP_Functions', 'c4wp_same_settings_for_all_sites' ) && C4WP_Functions::c4wp_same_settings_for_all_sites() ? network_admin_url( 'admin.php?page=c4wp-admin-settings' ) : admin_url( 'admin.php?page=c4wp-admin-settings' ); $intro_content = '
' . esc_html__( 'Getting started with the CAPTCHA 4WP plugin', 'advanced-nocaptcha-recaptcha' ) . '

' . esc_html__( 'Thank you for installing the CAPTCHA 4WP plugin. This wizard will help you get started with the plugin so you can configure CAPTCHA and protect your website from spam, and fake registrations and orders.', 'advanced-nocaptcha-recaptcha' ) . '

' . esc_html__( 'Next', 'advanced-nocaptcha-recaptcha' ) . ' ' . esc_html__( 'Cancel', 'advanced-nocaptcha-recaptcha' ) . '
'; $back_to_intro = '' . esc_html__( 'Back', 'advanced-nocaptcha-recaptcha' ) . ''; $method_select_upgrade_message = ( ! isset( C4WP_Method_Loader::$methods[ 'hcaptcha' ] ) ) ? '

Do you want to use hCaptcha or Cloudflare Turnstile for your website CAPTCHA? Upgrade to Business plan.

' : ''; $markup = '
' . $intro_content . '
' . $fields['captcha_version_title']['label'] . '

' . $fields['captcha_version']['label'] . '

' . self::callback( $fields['captcha_version'], true ) . ' ' . $method_select_upgrade_message . '
' . esc_html__( 'Next', 'advanced-nocaptcha-recaptcha' ) . ' ' . esc_html__( 'Cancel', 'advanced-nocaptcha-recaptcha' ) . '
' . $fields['site_key_title']['label'] . ' ' . $fields['site_key_subtitle']['label'] . '

' . $fields['site_key']['label'] . ' ' . self::callback( $fields['site_key'], true ) . '

' . self::callback( $fields['key_validation'], true ) . '

' . esc_html__( 'Proceed to secret key', 'advanced-nocaptcha-recaptcha' ) . ' ' . esc_html__( 'Back', 'advanced-nocaptcha-recaptcha' ) . '
' . esc_html__( 'Step 4: Configure a failover action for reCAPTCHA v3 failure', 'advanced-nocaptcha-recaptcha' ) . '

' . esc_html__( 'reCAPTCHA v3 is fully automated. This means that by default, if the CAPTCHA check fails the website visitor cannot proceed with what they are doing unless you configure a failover action. Use the below setting to configure the failover action.', 'advanced-nocaptcha-recaptcha' ) . '

' . $fields['failure_action']['label'] . ' ' . self::callback( $fields['failure_action'], true ) . '

' . $fields['failure_redirect']['label'] . ' ' . self::callback( $fields['failure_redirect'], true ) . '

' . $fields['failure_v2_site_key']['label'] . ' ' . self::callback( $fields['failure_v2_site_key'], true ) . '

' . $fields['failure_v2_secret_key']['label'] . ' ' . self::callback( $fields['failure_v2_secret_key'], true ) . '

' . self::callback( $fields['failure_key_validation'], true ) . '

' . esc_html__( 'Next', 'advanced-nocaptcha-recaptcha' ) . ' ' . esc_html__( 'Back', 'advanced-nocaptcha-recaptcha' ) . ' ' . esc_html__( 'Cancel', 'advanced-nocaptcha-recaptcha' ) . '
' . esc_html__( 'All done - you can now add CAPTCHA checks to your website', 'advanced-nocaptcha-recaptcha' ) . '

' . esc_html__( "Now that your chosen CAPTCHA service is fully integrated you can use the optional settings to fine-tune CAPTCHA to your requirements.", 'advanced-nocaptcha-recaptcha' ) . '

All the CAPTCHA settings are optional and with them you can configure aspects such as look and feel and CAPTCHA sensitivity. When you are ready navigate to the Settings & Placements page to configure where you\'d like to add the CAPTCHA checks.

' . esc_html__( 'Finish', 'advanced-nocaptcha-recaptcha' ) . '
'; return $markup; } /** * Handles markup for showing the 'launch wizard' buttons as well as current plugin config. * * @return $markup - HTML Markup */ public static function wizard_launcher_area() { $site_key = trim( C4WP_Functions::c4wp_get_option( 'site_key' ) ); $secret_key = trim( C4WP_Functions::c4wp_get_option( 'secret_key' ) ); $captcha_version = trim( C4WP_Functions::c4wp_get_option( 'captcha_version' ) ); $failure_action = trim( C4WP_Functions::c4wp_get_option( 'failure_action' ) ); $reset_nonce = wp_create_nonce( 'reset_captcha_nonce' ); if ( $site_key && $secret_key ) { $markup = '
' . esc_html__( 'Reconfigure CAPTCHA integration', 'advanced-nocaptcha-recaptcha' ) . ' ' . esc_html__( 'Remove CAPTCHA integration', 'advanced-nocaptcha-recaptcha' ) . ' '; $markup .= ' '; } else { if ( isset( C4WP_Method_Loader::$methods[ 'hcaptcha' ] ) ) { $markup = '
' . esc_html__( 'Configure CAPTCHA integration', 'advanced-nocaptcha-recaptcha' ) . ' '; } else { $markup = '
' . esc_html__( 'Configure Google reCAPTCHA integration', 'advanced-nocaptcha-recaptcha' ) . ' '; } } return $markup; } /** * Reset current version and keys. * * @return void */ public static function c4wp_reset_captcha_config() { $posted = filter_input_array( INPUT_POST ); // Grab POSTed data. $nonce = sanitize_text_field( $posted[ 'nonce' ] ); // Check nonce. if ( empty( $nonce ) || ! wp_verify_nonce( $nonce, 'reset_captcha_nonce' ) ) { wp_send_json_error( esc_html__( 'Nonce Verification Failed.', 'advanced-nocaptcha-recaptcha' ) ); } C4WP_Functions::c4wp_update_option( 'site_key' ); C4WP_Functions::c4wp_update_option( 'secret_key' ); C4WP_Functions::c4wp_update_option( 'captcha_version' ); wp_send_json_success(); } /** * Adds a setting to allow for testing different CAPTCHA results. * * @param array $fields - Current settings array. * @return array $fields - Modified array. */ public static function add_logging_and_testing_settings( $fields ) { $stored = C4WP_Functions::c4wp_get_option( 'c4wp_recent_results' ); $nice_display = ''; $additonal_options['override_result'] = array( 'label' => esc_html__( 'Override validation response.', 'advanced-nocaptcha-recaptcha' ), 'section_id' => 'google_keys', 'type' => 'select', 'class' => 'regular', 'std' => 'no_override', 'options' => array( 'no_override' => esc_html__( 'Do no override', 'advanced-nocaptcha-recaptcha' ), 'return_false' => esc_html__( 'Return false (failure)', 'advanced-nocaptcha-recaptcha' ), 'return_true' => esc_html__( 'Return true (pass)', 'advanced-nocaptcha-recaptcha' ), ), 'desc' => '', ); $additonal_options['recent_verification_results'] = array( 'section_id' => 'google_keys', 'type' => 'html', 'label' => sprintf( '

' ), 'class' => 'wrap-around-content c4wp-wizard-captcha-version', ); $fields = self::push_at_to_associative_array( $fields, array_key_last( $fields ), $additonal_options ); return $fields; } public static function add_delete_data_settings( $fields ) { $additonal_hide_fields = array( 'disable_submit_title' => array( 'section_id' => 'forms', 'type' => 'html', 'class' => 'wrap-around-content', 'label' => sprintf( '%1$s', esc_html__( 'Disable submit button untill CAPTCHA response is provided?', 'advanced-nocaptcha-recaptcha' ) ), ), 'disable_submit_subtitle' => array( 'section_id' => 'forms', 'type' => 'html', 'class' => 'wrap-around-content', 'label' => sprintf( '

%1$s

', esc_html__( 'When using a visible CAPTCHA method (V2 checkbox etc), should we disable the submit button untill the CAPTCHA challenge is completed?', 'advanced-nocaptcha-recaptcha' ) ), ), 'disable_submit' => array( 'label' => esc_html__( 'Disable submit button', 'advanced-nocaptcha-recaptcha' ), 'section_id' => 'forms', 'std' => 0, 'type' => 'checkbox', 'class' => 'checkbox', ), 'pass_on_no_captcha_found_title' => array( 'section_id' => 'forms', 'type' => 'html', 'class' => 'wrap-around-content', 'label' => sprintf( '%1$s', esc_html__( 'Should CAPTCHA 4WP pass or fail a submission if no CAPTCHA field is found?', 'advanced-nocaptcha-recaptcha' ) ), ), 'pass_on_no_captcha_found_subtitle' => array( 'section_id' => 'forms', 'type' => 'html', 'class' => 'wrap-around-content', 'label' => sprintf( '

%1$s

', esc_html__( 'If a form is passed through our plugin for verification and no CAPTCHA field is present, you can choose to either allow the submission or return a failure.', 'advanced-nocaptcha-recaptcha' ) ), ), 'pass_on_no_captcha_found' => array( 'label' => esc_html__( 'Disable CAPTCHA tests for logged in users', 'advanced-nocaptcha-recaptcha' ), 'section_id' => 'forms', 'type' => 'radio', 'class' => 'regular remove-space-below remove-radio-br', 'std' => 'proceed', 'options' => array( 'proceed' => esc_html__( 'Proceed with submission', 'advanced-nocaptcha-recaptcha' ), 'fail' => esc_html__( 'Fail submission', 'advanced-nocaptcha-recaptcha' ), ), ), 'delete_data_subtitle' => array( 'section_id' => 'forms', 'type' => 'html', 'class' => 'wrap-around-content', 'label' => sprintf( '%1$s', esc_html__( 'Do you want delete all plugin data when uninstalling the plugin?', 'advanced-nocaptcha-recaptcha' ) ), ), 'delete_data_enable' => array( 'label' => esc_html__( 'Delete data', 'advanced-nocaptcha-recaptcha' ), 'section_id' => 'forms', 'std' => 0, 'type' => 'checkbox', 'class' => 'checkbox', ), ); $fields = \C4WP_Settings::push_at_to_associative_array( $fields, array_key_last( $fields ), $additonal_hide_fields ); return $fields; } } //END CLASS
Warning: call_user_func_array() expects parameter 1 to be a valid callback, class 'C4WP_Settings' not found in /var/www/html/planilhando.com.br/web/forum/wp-includes/class-wp-hook.php on line 307
Page not found – Planilhando

4cup-tea4

Opa! Página não encontrada..!

A página que você está procurando não existe.