Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion for-maintainers.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ into GitHub Actions but can also be run locally.

Launching:

`bash tools/run-tests.sh [all|wordpress|form-plugins] [local]`
`bash tools/run-tests.sh [all|form-plugins|form-plugins/formidable-forms] [local]`

To open the Cypress app:

Expand Down
2 changes: 1 addition & 1 deletion prosopo-procaptcha/prosopo-procaptcha.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
/**
* Plugin Name: Prosopo Procaptcha
* Description: GDPR compliant, privacy friendly and better value captcha.
* Version: 1.20.0
* Version: 1.20.1
* Author: Prosopo Team
* Author URI: https://prosopo.io/
* License: GPLv2 or later
Expand Down
7 changes: 5 additions & 2 deletions prosopo-procaptcha/readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Tags: Captcha, Procaptcha, antispam, anibot, spam.
Requires at least: 5.5
Tested up to: 6.8
Requires PHP: 7.4
Stable tag: 1.20.0
Stable tag: 1.20.1
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Expand Down Expand Up @@ -97,7 +97,7 @@ While only the items above are tested, overall, the Procaptcha plugin supports a
3. [JetPack](https://wordpress.org/plugins/jetpack/) (Forms) - Gutenberg form block: Add the Group block with the `prosopo_procaptcha` shortcode inside the target form block.
4. [WooCommerce](https://docs.prosopo.io/en/wordpress-plugin/woocommerce/) - My Account forms; Classic Checkout, Blocks Checkout, Order Tracking forms: enable protection in the `WooCommerce` tab of the plugin settings.
5. [Spectra](https://docs.prosopo.io/en/wordpress-plugin/spectra/) - Form block: add hidden input with the `prosopo_procaptcha` name
6. Beaver Builder - Contact, Subscribe forms: enabled protection in the target form settings; Login form: Procaptcha plugin settings->Account forms.
6. [Beaver Builder](https://wordpress.org/plugins/beaver-builder-lite-version/) - Contact, Subscribe forms: enabled protection in the target form settings; Login form: Procaptcha plugin settings->Account forms.

**Built-In Integrations**:

Expand Down Expand Up @@ -135,6 +135,9 @@ Absolutely! The plugin has a [public GitHub repository](https://github.com/proso

== Changelog ==

= 1.20.1 (2025-08-21) =
Enhancement: compatibility with the latest WPForms version

= 1.20.0 (2025-06-03) =
Fix: Procaptcha option in the Beaver builder modules

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,17 @@
class WPForms_Integration extends Procaptcha_Plugin_Integration implements Hookable {
public function get_target_plugin_classes(): array {
return array(
'WPForms\WPForms',
/**
* Instead of the main plugin class, we use the main field class.
*
* The reason is that the primary plugin class, 'WPForms\WPForms', itself is always loaded for all requests,
* but since recently contains the 'is_restricted_heartbeat()' method,
* which skips loading of the rest classes for most of the WordPress heartbeat requests.
*
* In this way, usage of the primary class would always create the Integration instances,
* which would try to extend the not-existing 'WPForms_Field' class.
*/
'WPForms_Field',
);
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import WooCheckoutClassic from "./woo-checkout-classic";
import { FormSubmitionSettings } from "@support/commands/submitForm";

const INTERCEPT_REQUEST_TIMEOUT_MS = 30 * 1000;

class WooCheckoutBlocks extends WooCheckoutClassic {
// Less, cause the form doesn't support auth.
itemsCountToRemove = 2;
Expand Down Expand Up @@ -47,7 +49,7 @@ class WooCheckoutBlocks extends WooCheckoutClassic {

wpData.dispatch("wc/store/cart").setBillingAddress(billingFields);

cy.wait("@cartData");
cy.wait("@cartData", { timeout: INTERCEPT_REQUEST_TIMEOUT_MS });
}

protected setCaptchaValue(wpData, captchaValue: string): void {
Expand All @@ -59,7 +61,8 @@ class WooCheckoutBlocks extends WooCheckoutClassic {
"prosopo-procaptcha/prosopo_procaptcha": captchaValue,
});

cy.wait("@captchaValue");
// for some reason, Woo doesn't always make this request - maybe only if the value was changed
// cy.wait("@captchaValue", { timeout: INTERCEPT_REQUEST_TIMEOUT_MS });
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ class WooOrderTracking extends FormTest {
captchaInput: "",
};
this.submitValues = {
orderid: "1602",
orderid: "1712",
order_email: "test@gmail.com",
};
this.messages = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,11 @@ class EverestFormsWithAjax extends EverestForms {
'input[name="settings[ajax_form_submission]"][type=checkbox]',
);

true === isActivation ? setting.check() : setting.uncheck();
// if the 'settings' tab is not active, then the input is hidden,
// so the "force" option is used to avoid the "Element is not visible" error.
true === isActivation
? setting.check({ force: true })
: setting.uncheck({ force: true });

cy.get(".everest-forms-save-button").click();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ class FormidableForms extends FormTest {
"input[type=text][name*=item_meta]:not(.frm_verify)": "John Doe",
};
this.messages = {
success: "Your responses were successfully submitted. Thank you!\n",
fail: "\n\tThere was a problem with your submission. Errors are marked below.",
success: "Your responses were successfully submitted. Thank you!",
fail: "There was a problem with your submission. Errors are marked below.",
};
}
}
Expand Down
7 changes: 4 additions & 3 deletions tests/cypress/e2e/form-plugins/jetpack/classes/jetpack.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,17 @@ class Jetpack extends FormTest {
formWithCaptcha: ".jetpack-form-with-captcha",
formWithoutCaptcha: ".jetpack-form-without-captcha",
successMessage: "#contact-form-success-header",
errorMessage: ".form-error h3",
errorFieldMessage: ".form-errors",
errorMessage: ".contact-form__error",
errorFieldMessage: "",
captchaInput: "",
};
this.submitValues = {
"input.name.grunion-field": "John Doe",
};
this.messages = {
success: "Your message has been sent",
fail: "Error!",
// as per 14.9.1, Jetpack shows a generic 'internet connection' issue for any form errors...
fail: "issue while submitting the form",
};
}

Expand Down
Loading