Skip to content
Corex

NewsletterSignupRenderer

Corex\Blocks\NewsletterSignupRenderer · class · Blocks layer

Server render for the Newsletter Signup block (spec 063, Phase 7). It renders a REAL double opt-in signup form wired to the existing corex/v1/newsletter/subscribe REST route (provided by the corex-newsletter add-on): email + explicit consent + a honeypot, an accessible live status region, and the endpoint/nonce carried on the form for the view script. It is gated on the optional corex-newsletter add-on (Principle IX) — when the add-on is inactive it renders an honest “unavailable” note, never a form that silently fails. No fabricated success: the visitor sees the real endpoint’s outcome (a confirmation email is sent for new/pending subscribers). With a captcha provider on, the form carries the provider’s check before its button, and the view script sends its token (spec 115, US-VIS-11).

__construct(PluginActivationInspector $pluginActivationInspector, FormChallenge $challenge)

Section titled “__construct(PluginActivationInspector $pluginActivationInspector, FormChallenge $challenge)”

render(array $attributes, string $content, object $block): string

Section titled “render(array $attributes, string $content, object $block): string”