Callback request form in WordPress
A callback request form: French phone number checked and formatted, topic, working day and time slot, with explicit consent to the call.
Here is an excerpt of this component's code in WordPress. The full code is free for members, ready to copy into your project.
This component also comes in
The code in WordPress
<?php
/**
* Plugin Name: Forge, Formulaire de demande de rappel
* Description: Un formulaire de demande de rappel : téléphone français contrôlé et mis en forme, sujet, jour ouvré et plage horaire, avec accord explicite pour l’appel. Ajoute la composition « Formulaire de demande de rappel » à l'éditeur de blocs.
* Version: 1.0.0
* Requires at least: 6.6
* Requires PHP: 8.1
* Author: Forge
* License: GPL-2.0-or-later
* License URI: https://www.gnu.org/licenses/gpl-2.0.html
* Text Domain: forge-formulaire-demande-rappel
*<!-- wp:html -->
<form class="fdr" data-fdr novalidate aria-labelledby="fdr-titre">
<p class="fdr-eyebrow">Appel gratuit · du lundi au vendredi</p>
<h2 class="fdr-title" id="fdr-titre">Être rappelé par un conseiller</h2>
<div class="fdr-field">
<label class="fdr-label" for="fdr-nom">Prénom et nom</label>
<input class="fdr-input" id="fdr-nom" name="nom" autocomplete="name" aria-describedby="fdr-err-nom">
<p class="fdr-error" id="fdr-err-nom" data-fdr-error="nom"></p>
</div>
<div class="fdr-field">
<label class="fdr-label" for="fdr-tel">Numéro de téléphone</label>
<input class="fdr-input" id="fdr-tel" name="tel" type="tel" inputmode="tel" autocomplete="tel" placeholder="06 12 34 56 78" aria-describedby="fdr-aide-tel fdr-err-tel">(() => {
if (!document.querySelector(".fdr")) return;
document.querySelectorAll("[data-fdr]").forEach((root) => {
const on = (el, type, fn) => el.addEventListener(type, fn);
const name = root.querySelector('[name="nom"]');
const phone = root.querySelector('[name="tel"]');
const topic = root.querySelector('[name="sujet"]');
const day = root.querySelector('[name="jour"]');
const agree = root.querySelector('[name="accord"]');
const slots = [...root.querySelectorAll('[name="plage"]')];
const status = root.querySelector("[data-fdr-status]");
const iso = (date) => date.toLocaleDateString("sv-SE");:root {
--fdr-card: #ffffff;
--fdr-text: #14231c;
--fdr-muted: #45574e;
--fdr-accent: #0f6b4a;
--fdr-line: #c5d5cc;
--fdr-soft: #e9f5ef;
--fdr-error: #b42318;
--demo-formulaire-demande-rappel-bg: #e6efea;
--demo-formulaire-demande-rappel-text: #14231c;
}
Free component: copy it freely, including for commercial projects.
Other forms and inputs components in WordPress
Forms and inputs components in WordPress
A quote request form for tradespeople: the customer describes the work, picks a start date range and attaches up to six site photos, each with a preview, its size and a button to remove it.
- Tailwind
- React
- CSS
- WordPress

A quote request form whose labels, hints and error messages are full French sentences, still readable at 320 px: nothing overflows, nothing is cut off, and each error is tied to its field.
- Tailwind
- React
- CSS
- WordPress

Visitors pick a package and tick options: the pre-tax total, VAT and total including tax update live, and the summary is sent with the contact form.
- Tailwind
- React
- CSS
- WordPress

A short NPS survey: a 0 to 10 score as radio buttons, then a follow-up question adapted to whether the customer is a detractor, passive or promoter.
- Tailwind
- React
- CSS
- WordPress

An honest unsubscribe page: address prefilled from the link, choice between stopping everything or receiving less, optional reason and an undo.
- Tailwind
- React
- CSS
- WordPress

A SIRET or SIREN field that checks the Luhn key as you type, handles the La Poste exception, formats the number and links to the official business directory.
- Tailwind
- React
- CSS
- WordPress