PluginProbe
The WP Remote WordPress Plugin / 6.36
The WP Remote WordPress Plugin v6.36
6.72 6.69 6.65 6.62 6.48 6.47 4.87 4.97 5.05 5.09 5.16 5.22 5.24 5.25 5.38 5.41 5.42 5.45 5.47 5.53 5.56 5.65 5.68 5.72 5.73 All 53 releases
wpremote / form_testing / handlers / wp_form.php

wp_form.php in The WP Remote WordPress Plugin 6.36, at form_testing/handlers/wp_form.php

34 lines 756 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 if (!defined('ABSPATH')) exit;
4 if (!class_exists('BVWPFormHandler')) :
5
6 class BVWPFormHandler {
7 private $form_id;
8 private $bypass_params = array();
9
10 public function __construct($form_id, $bypass_params) {
11 $this->form_id = $form_id;
12 $this->bypass_params = $bypass_params;
13 }
14
15 public function bypass() {
16 if (array_key_exists('should_bypass_captcha', $this->bypass_params)) {
17 $this->bypassCaptcha();
18 }
19
20 if (array_key_exists('should_bypass_email', $this->bypass_params)) {
21 $this->bypassEmail();
22 }
23 }
24
25 public function bypassCaptcha() {
26 add_filter('wpforms_process_bypass_captcha', '__return_true', PHP_INT_MAX);
27 }
28
29 public function bypassEmail() {
30 add_filter('wpforms_entry_email', '__return_false', PHP_INT_MAX);
31 }
32 }
33
34 endif;