=== Mozedia Forms – Simple Contact Form & Customizable Custom Forms ===
Contributors: jumedeenkhan, mozedia
Donate link: https://buymeacoffee.com/jumedeenkhan
Tags: contact form, contact form plugin, custom form, form builder, forms
Requires at least: 6.8
Tested up to: 7.1
Requires PHP: 7.4
Stable tag: 1.0.2
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

The best contact form plugin for WordPress. Create simple, fast & lightweight contact forms and custom forms with easy form builder.

== Description ==

Mozedia Forms is a simple, fast, and lightweight **contact form plugin** for WordPress. Create clean **contact forms and custom forms** without the complexity and bloat found in many large form builder plugins.

Many form plugins come packed with advanced visual builders, dozens of form types, custom post types, and a long list of settings. That can be useful for complex websites, but sometimes you just need a **simple contact form that works**.

That is where **Mozedia Forms** comes in. ⚡

Create a reliable contact form, choose the fields you need, configure your email settings, and add the form anywhere on your website using a **shortcode or Gutenberg block**.

No unnecessary features. No jQuery. No third-party dependencies.

## ⚡ Simple, Fast & Lightweight

Mozedia Forms is designed for websites that need a **fast contact form without unnecessary overhead**.

The plugin only loads its CSS and JavaScript assets on pages where the form is actually displayed. Its frontend JavaScript is written in lightweight, dependency-free vanilla JavaScript and is **less than 5 KB**.

That means less unnecessary code and a cleaner experience for your visitors.

## 📝 Contact Forms Made Simple

Create a simple contact form with the fields your website actually needs.

* Name, Email, and Message fields are always available.
* Optional Subject, Phone, Company, Website, and Address fields.
* Customize field labels, placeholders, messages, and submit button text.
* Use AJAX submission or a traditional page reload.
* Add forms with a Gutenberg block or `[mozedia-form]` shortcode.
* Customize individual form placements without creating unnecessary separate forms.

Whether you need a basic **contact form**, an inquiry form, an advertising form, or another simple custom form, Mozedia Forms keeps the setup straightforward.

## 🛡️ Built-In Spam Protection & Security

Security and spam protection are built into the plugin from the start.

* Honeypot spam protection.
* Per-IP rate limiting.
* Server-side validation.
* Message-content validation and limits.
* Link limits and blocked keyword rules.
* Privacy Policy consent checkbox.
* Safe email handling through WordPress.
* No unnecessary external services.

The goal is simple: help you receive genuine messages while reducing unwanted form submissions.

## 📧 Reliable Contact Form Email Delivery

Mozedia Forms uses the WordPress email system by default, so you can start receiving contact form messages without configuring an external service.

Need better email delivery? **SMTP support** is available for websites that require it.

You can also send a **test email** directly from the plugin settings to verify your email configuration before putting your contact form live.

## 🔒 Privacy Focused

Mozedia Forms does not store contact form submissions in your WordPress database and does not send form data to third-party services.

Messages are sent directly to your configured recipient through WordPress's mail system, helping keep your website lightweight while reducing unnecessary storage of personal information.

## 🎨 Easy Form Customization

Customize your contact form from one organized settings area.

Configure:

* Form fields and visibility.
* Field labels and placeholders.
* Submit button text.
* Success, error, and validation messages.
* Email recipients and sender settings.
* HTML or plain-text email format.
* Spam protection and rate limiting.
* Form appearance and colors.
* Advanced submission and data options.

You can also import and export settings as JSON, reset your configuration, enable debug mode, or choose whether plugin settings should be removed during uninstall.

## 🧩 Gutenberg Block & Shortcode Support

Add your contact form wherever you need it.

Use the **Mozedia Forms** Gutenberg block for an easy block-editor workflow, or use the `[mozedia-form]` shortcode when you want more control.

Shortcode and block attributes allow individual form placements to use different settings, such as:

* Recipient email address.
* Form instance title.
* Submit button text.
* Success message.
* Redirect URL.
* Optional fields.
* Custom CSS classes and IDs.

This makes it possible to use the same global form configuration while adapting individual placements for different purposes.

## ✅ Features

* Simple and lightweight contact form.
* Customizable form fields.
* Custom contact form messages.
* Gutenberg block support.
* Shortcode support.
* AJAX and standard form submission.
* Vanilla JavaScript with no jQuery dependency.
* Frontend assets loaded only when the form is displayed.
* Server-side and JavaScript validation.
* Honeypot spam protection.
* Per-IP rate limiting.
* Message and link limits.
* Blocked keyword protection.
* Privacy Policy integration.
* SMTP support.
* Send Test Email feature.
* HTML and plain-text emails.
* Theme-aware styling.
* Optional built-in color scheme.
* Import and export settings.
* Reset and debug options.
* Translation-ready.

## 💡 Why Choose Mozedia Forms?

Not every website needs a complicated form builder with dozens of features.

Mozedia Forms focuses on the essentials: a **simple contact form, useful customization options, reliable email delivery, built-in spam protection, and lightweight performance**.

It gives you the flexibility to create the forms you need without turning your WordPress dashboard into a complicated form management system.

**Simple forms. Less bloat. Better focus.**

## 🎨 Designed to Fit Your Website

Mozedia Forms automatically follows your active WordPress theme's colors by default, helping the contact form blend naturally into your website.

You can also enable the plugin's built-in color scheme when you want a consistent appearance across your forms.

For individual shortcode or block instances, you can use the `mzforms-default-colors` class to apply the plugin's built-in color scheme only where needed.

The plugin's settings page also follows your selected WordPress admin color scheme, making Mozedia Forms feel like a natural part of your WordPress dashboard.

== Installation ==

1. Upload the plugin to `/wp-content/plugins/mozedia-forms`, or install it directly from the **Plugins** screen in your WordPress admin.
2. Activate the plugin through the "Plugins" screen.
3. Go to **Settings → Mozedia Forms**, set your recipient email address under the **Mail** tab, and everything else works by default.
4. Add the form using the **Mozedia Forms** block or the `[mozedia-form]` shortcode. Use shortcode attributes if you want to customize individual forms.
5. That's it! Now you're ready to receive messages.

== Shortcode & Block Attributes ==

The `[mozedia-form]` shortcode and the "Mozedia Forms" block accept the same optional attributes, letting one placement differ from the global defaults:

* `title` - Not shown visually - identifies this form instance (e.g. "Advertise With Us") in its accessible name and in notification email subjects.
* `recipient` - Send this instance's submissions to a different email address.
* `from_name` - Overrides the notification email's "From" name for this instance.
* `success` - Custom success message for this instance.
* `redirect` - URL to send visitors to after a successful submission.
* `submit` - Custom submit button text for this instance.
* `class` / `id` - Extra CSS class(es) / an HTML id on the `<form>` element itself.
* `phone`, `company`, `website`, `address`, `subject` - `"1"` forces the field on, `"0"` forces it off, and leaving it out uses the global Settings toggle.

For example:

`[mozedia-form title="Advertise With Us" recipient="ads@example.com" company="1"]`

== Frequently Asked Questions ==

= Can I create multiple contact forms? =

Mozedia Forms uses one global contact form configuration from **Settings → Mozedia Forms**.

However, you can place the contact form multiple times on your website and customize individual placements using the shortcode or Gutenberg block. You can change options such as the recipient email address, submit button text, success message, redirect URL, and optional fields for each placement.

For example, you can use one placement as a General Contact form and another as an "Advertise With Us" form that sends messages to a different email address.

= Can I create a custom form? =

Yes. Mozedia Forms lets you customize the available form fields, labels, placeholders, messages, email settings, appearance, and other options to create a contact form that fits your needs.

You can also customize individual form placements using shortcode and block attributes.

= How do I add a contact form to my website? =

You can add a Mozedia Forms contact form using the **Mozedia Forms Gutenberg block** or the `[mozedia-form]` shortcode.

Simply add the block in the WordPress editor, or place the shortcode where you want the contact form to appear.

= Where are contact form submissions stored? =

Mozedia Forms does not store form submissions in the WordPress database.

Messages are sent directly to the configured recipient using WordPress's `wp_mail()` system. There is no submissions log or inbox inside the WordPress dashboard.

= Why did my contact form test email not arrive? =

Your website's mail system may not be configured to send email correctly. This is especially common on local or development environments such as `localhost`.

Use the **Send Test Email** option on the Mail tab to check your email configuration and view the underlying error.

If your website has email delivery problems, you can configure **SMTP** from the Mail tab.

= Does Mozedia Forms support SMTP? =

Yes. Mozedia Forms includes optional **SMTP configuration** for websites that need improved email delivery.

The plugin also includes a **Send Test Email** feature so you can verify your email settings before using the contact form on a live website.

= How does contact form spam protection work? =

Mozedia Forms includes built-in **honeypot spam protection** enabled by default.

You can also enable additional protection such as per-IP rate limiting, message length limits, link limits, and blocked keyword rules from the Protection tab.

= Is the contact form secure? =

Mozedia Forms includes server-side validation, message validation, honeypot protection, rate limiting, privacy consent support, and safe email handling through WordPress.

The plugin does not require unnecessary third-party services for its core contact form functionality.

= Does Mozedia Forms support AJAX contact form submission? =

Yes. You can choose between **AJAX submission** and a traditional page-reload submission.

When AJAX is disabled, the form uses a normal page submission with a Post/Redirect/Get flow, so refreshing the result page does not resend the form.

Success messages, error messages, and field-level validation remain available with either submission method.

= Can I customize the contact form with CSS? =

Yes. Mozedia Forms provides stable CSS class names such as `mzforms-form-wrapper`, `mzforms-form`, and `mzforms-field`.

You can target these classes with your own CSS to customize the appearance of the contact form and its fields.

= Does Mozedia Forms work with Gutenberg? =

Yes. Mozedia Forms includes a dedicated **Gutenberg block** for adding contact forms directly from the WordPress block editor.

The block also supports attributes for customizing individual form placements.

= Can I use a contact form shortcode? =

Yes. You can add the form anywhere that supports shortcodes using:

`[mozedia-form]`

The shortcode supports optional attributes for things such as the recipient email address, submit button text, success message, redirect URL, optional fields, CSS classes, and IDs.

= Does Mozedia Forms work on WordPress Multisite? =

Yes. Mozedia Forms supports WordPress Multisite with separate settings for each site.

When network activated, default settings are seeded for each site, but each site's administrator manages its own Mozedia Forms configuration.

= Will uninstalling Mozedia Forms delete my settings? =

Not by default.

Your settings are preserved when the plugin is deleted and reinstalled unless **Delete Data on Uninstall** is enabled from the Advanced tab.

== Screenshots ==

1. Settings - General tab: standard/optional fields, Privacy Policy, appearance, and performance options.
2. Settings - Form tab: field labels, placeholders, submit button, and Privacy Policy checkbox text.
3. Settings - Mail tab: recipient, sender identity, email format, and SMTP configuration/testing.
4. Settings - Message tab: success/error messages, privacy notices, and inline validation messages.
5. Settings - Protection tab: honeypot, message limits, rate limiting, and blocked keywords.
6. Settings - Advanced tab: submission behavior, import/export, reset, data control, and debug mode.
7. User Guide: getting started, block and shortcode usage, and supported attributes.
8. Mozedia Forms block with sidebar settings in the block editor.
9. The contact form displayed on the frontend.
10. Plugin setting option in wp-admin bar.

== Upgrade Notice ==

= 1.0.2 =

* Fixed an issue where the `[mozedia-form]` shortcode could be rendered inside `<pre>` and `<code>` elements.
* Improved shortcode handling for code examples and feed content.

= 1.0.1 =

* Fixes missing email Subject, block Privacy Policy validation mismatch, and rate limit behavior.
* Hardens email header values by stripping line breaks.
* Tested with WordPress 7.1.

== Changelog ==

= 1.0.2 =

* Fixed `[mozedia-form]` being rendered inside `<pre>` and `<code>` elements.
* Added protection for shortcode examples displayed in code blocks.
* Prevented the form shortcode from being rendered in feeds.
* Improved shortcode processing reliability and content handling.

= 1.0.1 =

* Tested with WordPress 7.1.
* Verified admin, block, and frontend form flows with WordPress 7.1.
* Fixed: Subject missing from notification emails.
* Fixed: Block's Privacy Policy override not enforced server-side.
* Fixed: Rate limit was consuming attempts on invalid submissions.
* Hardened: Email header values now explicitly stripped of line breaks.

= 1.0.0 =

* Initial public release.
* Added the Mozedia Forms block and shortcode.
* Added AJAX and standard form submission.
* Added spam protection and validation.
* Added SMTP support and test email.
* Added import/export settings.
* Added customizable form fields.
* Added translation support.
* Added uninstall cleanup option.
