=== CraftRoq Forms ===
Contributors: craftroq
Tags: contact form, form builder, smtp, calculator, survey
Requires at least: 6.5
Tested up to: 7.1
Requires PHP: 8.1
Stable tag: 1.0.0
License: GPL-3.0-or-later
License URI: https://www.gnu.org/licenses/gpl-3.0.html

Drag and drop form builder with 25 free field types, calculations, order forms, built-in SMTP, entries, spam protection and GDPR tools.

== Description ==

CraftRoq Forms is a fast, accessible form builder for WordPress. Drag fields onto your form, set them up in the sidebar, and embed the form with a block or a shortcode. Every submission is saved as an entry you can search, star and export.

= Builder =

* Drag and drop builder with a live preview, smooth animations, undo and redo, inline label editing, desktop/tablet/mobile preview and keyboard shortcuts.
* All 25 field types free: single line text, paragraph, email, number, dropdown, multiple choice, checkboxes, name, phone, website, date, hidden field, consent (GDPR), file upload with drag and drop, star rating, range slider, address, signature, repeater, product, calculation, order total, section heading, custom HTML and page break.
* Repeater fields let visitors add as many rows as they need, such as attendees or gift recipients.
* Multi-step forms with a progress bar or step titles and validation on every step.
* Ready-made templates: contact form, newsletter signup, feedback survey, quote request, job application, multi-step registration and order form.
* Duplicate fields and forms, activate or deactivate forms, preview before you publish.

= Calculations & order forms =

* Calculation fields with formulas such as `{field:3} * {field:4}`, brackets and round(), ceil(), floor(), min(), max(), abs(), sqrt() and pow().
* Product fields with a fixed price, quantities, or price options as a dropdown, radio buttons or checkboxes.
* An order total that updates as visitors choose, in your currency.
* Results update live in the browser, but the server works out every number again, so stored values cannot be tampered with.

= Submissions =

* Submits without reloading the page, with inline, screen-reader friendly errors. Also works with JavaScript turned off.
* Unlimited forms and entries, stored in their own database tables.
* Entries screen with search, unread/starred/trash views, bulk actions and CSV export.
* Confirmation message, redirect to a page, or redirect to a URL.
* Any number of email notifications per form, with smart tags such as {field:2}, {all_fields}, {form_title} and {user_email}, and Reply-To set to the visitor.

= Email & SMTP =

* Send notifications, or every email from your site, through any SMTP server.
* Presets for Gmail, Microsoft 365, Yahoo, Zoho, SendGrid, Mailgun, Brevo, Postmark, Amazon SES and MailerSend.
* Password stored encrypted, or set it in wp-config.php.
* Send a test email and see the SMTP server's replies.
* Email log of the last 50 notifications.

= Spam protection =

* Honeypot field and a signed submit-time check on every form, with no setup.
* Optional Google reCAPTCHA v2 or v3, hCaptcha or Cloudflare Turnstile.

= Privacy =

* Integrates with WordPress's personal data export and erase tools.
* Choose whether to store IP addresses and browser details.
* Automatically delete entries after a number of days.

= Developers =

* `[crforms id="1"]` shortcode, a "CraftRoq Form" block and `crforms_render( 1 )`.
* Every colour and size is a CSS custom property.
* Actions and filters for fields, validation, submissions, notifications and the builder. Register your own field types with `crforms_register_fields`.

= CraftRoq Forms Pro =

The Pro add-on adds conditional logic, Stripe and PayPal payments, scheduling and entry limits, a form styler, webhooks, Mailchimp, HubSpot, ActiveCampaign, Google Sheets and more templates. Your forms and entries stay where they are when you add it.

== Installation ==

1. Upload the `craftroq-forms` folder to `/wp-content/plugins/`, or install it from Plugins › Add New.
2. Activate the plugin.
3. Go to CraftRoq Forms › Add New, pick a template and build your form.
4. Add the "CraftRoq Form" block to a page, or paste the form's shortcode.

== Frequently Asked Questions ==

= Emails are not arriving. =

Many hosts block or spam-filter mail sent from PHP. Go to CraftRoq Forms › Settings › Email & SMTP, choose "SMTP server", pick your provider and send a test email. If it fails, the SMTP conversation shown below the test tells you why.

= Does it work with page caching? =

Yes. Forms do not rely on nonces, so cached pages keep working. Spam protection uses a honeypot, a signed time token and an optional CAPTCHA.

= Can I style the forms? =

Override the CSS custom properties on `.crforms-wrap`, for example `--crforms-primary`, `--crforms-radius` and `--crforms-border`. Turn off the plugin's styles in Settings to style forms from your theme.

= How do calculations work? =

Add a Calculation field and type a formula. Click a field tag below the formula box to insert it. Choice fields count the value of the chosen option, checkboxes add up their checked values, and product fields count their line total (price × quantity).

= Can I take payments? =

Product and total fields are free and work without payments, for example for quotes and orders you invoice later. CraftRoq Forms Pro sends the order total to Stripe Checkout or PayPal.

= Where is my data stored? =

In three tables: `{prefix}crforms_forms`, `{prefix}crforms_entries` and `{prefix}crforms_entrymeta`. They are removed on uninstall only if you turn on "Delete all data" in Settings › Privacy & data.

== External services ==

CraftRoq Forms does not contact any outside service by default. The services below are used only if you turn them on in CraftRoq Forms › Settings.

= Google reCAPTCHA =

Used to block spam when you choose reCAPTCHA v2 or v3 under Spam protection. Pages with a form load Google's reCAPTCHA script, which collects information about the visitor's browser and behaviour. When a form is submitted, the visitor's CAPTCHA response and IP address are sent to Google to check it. [Terms of Service](https://policies.google.com/terms), [Privacy Policy](https://policies.google.com/privacy).

= hCaptcha =

Used the same way when you choose hCaptcha. Pages with a form load the hCaptcha script, and on submit the CAPTCHA response and the visitor's IP address are sent to hCaptcha. [Terms of Service](https://www.hcaptcha.com/terms), [Privacy Policy](https://www.hcaptcha.com/privacy).

= Cloudflare Turnstile =

Used the same way when you choose Turnstile. Pages with a form load the Turnstile script, and on submit the CAPTCHA response and the visitor's IP address are sent to Cloudflare. [Terms of Service](https://www.cloudflare.com/website-terms/), [Privacy Policy](https://www.cloudflare.com/privacypolicy/).

= SMTP email providers =

By default WordPress sends email from your own server and no email service is contacted. When you choose "SMTP server" under CraftRoq Forms › Settings › Email & SMTP, the emails your site sends are delivered through the mail server you enter. Each email goes to that server in full: the sender and recipient addresses, the subject, and the message, which for form notifications includes the visitor's answers and any attached uploads. Your SMTP username and password are sent to the same server to log in. This happens each time an email is sent, and when you send a test email.

The plugin includes the server name, port and encryption of the providers below as presets, to save typing. Nothing is sent to a provider unless you select it, or enter its server yourself, and save your own account details.

* Gmail / Google Workspace (smtp.gmail.com): [Terms of Service](https://policies.google.com/terms), [Privacy Policy](https://policies.google.com/privacy).
* Outlook / Microsoft 365 (smtp.office365.com): [Services Agreement](https://www.microsoft.com/en-us/servicesagreement), [Privacy Statement](https://www.microsoft.com/en-us/privacy/privacystatement).
* Yahoo Mail (smtp.mail.yahoo.com): [Terms of Service](https://legal.yahoo.com/us/en/yahoo/terms/otos/index.html), [Privacy Policy](https://legal.yahoo.com/us/en/yahoo/privacy/index.html).
* Zoho Mail (smtp.zoho.com): [Terms of Service](https://www.zoho.com/terms.html), [Privacy Policy](https://www.zoho.com/privacy.html).
* SendGrid, a Twilio service (smtp.sendgrid.net): [Terms of Service](https://www.twilio.com/en-us/legal/tos), [Privacy Notice](https://www.twilio.com/en-us/legal/privacy).
* Mailgun (smtp.mailgun.org): [Terms of Service](https://www.mailgun.com/legal/terms/), [Privacy Policy](https://www.mailgun.com/legal/privacy-policy/).
* Brevo (smtp-relay.brevo.com): [Terms of Use](https://www.brevo.com/legal/termsofuse/), [Privacy Policy](https://www.brevo.com/legal/privacypolicy/).
* Postmark (smtp.postmarkapp.com): [Terms of Service](https://postmarkapp.com/terms-of-service), [Privacy Policy](https://postmarkapp.com/privacy-policy).
* Amazon SES (email-smtp.us-east-1.amazonaws.com): [Service Terms](https://aws.amazon.com/service-terms/), [Privacy Notice](https://aws.amazon.com/privacy/).
* MailerSend (smtp.mailersend.net): [Terms of Use](https://www.mailersend.com/legal/terms-of-use), [Privacy Policy](https://www.mailersend.com/legal/privacy-policy).

If you enter another SMTP server, that provider's own terms and privacy policy apply.

== Screenshots ==

1. The drag and drop builder, with every field type free.
2. Field options in the sidebar.
3. Start from a template.
4. An order form with a live total.
5. Entries, with unread and starred views.
6. Built-in SMTP with provider presets and a test email.

== Changelog ==

= 1.0.0 =
* First release.
