MYW Contact Form

By mywdotit

0+ active installationsVersion 0.2.0

A lightweight, customizable contact form with a compact embedded layout and an optional popup, configurable fields

Description

MYW Contact Form provides a simple contact form without requiring third-party services or frontend libraries. English is the plugin source language; translations are handled by WordPress using the text domain myw-contact-form.

Features:
* Compact, centered embedded form using [myw_contact_form].
* Optional site-wide popup triggered by links to #mywcf-contact.
* Configurable recipient, subject and confirmation messages.
* Configurable form fields (text, email, telephone, URL and textarea).
* Theme-inherited, default and custom color styles.
* Honeypot and configurable question-and-answer challenge.
* Basic IP-based rate limiting.
* No message database or external service.

Privacy

The plugin does not store submitted messages in the WordPress database and does not contact external services by default. Messages are sent to the configured recipient using the site’s WordPress mail system (wp_mail()).

To apply basic rate limiting, the plugin stores a short-lived counter in the WordPress transient system. The transient key contains a salted hash of the visitor IP address; the raw IP address is not stored by this plugin. The counter expires after the configured rate-limit window.

Installation

  1. Upload the plugin folder to /wp-content/plugins/ or install the ZIP through the WordPress Plugins screen.
  2. Activate MYW Contact Form.
  3. Open Settings > MYW Contact Form.
  4. Configure the recipient and options.
  5. Add [myw_contact_form] to a page or post.

To enable the popup, activate it in the settings and add a link with href=”#mywcf-contact”.

FAQ

How do I display the form?

Add [myw_contact_form] to a page, post or shortcode-capable area.

How do I open the popup?

Enable the popup in Settings > MYW Contact Form, then link to #mywcf-contact.

Are messages stored in WordPress?

No. The plugin sends submissions using wp_mail() and does not create a message archive.

Changelog

0.2.0

  • Improved frontend shortcode detection, including nested blocks and reusable blocks.
  • Separated frontend and administration stylesheets.
  • Kept the frontend CSS delivery option (external file or inline) and load styles only when the shortcode or popup is needed.
  • Deferred inline stylesheet reading until the frontend assets are required.
  • Kept popup JavaScript limited to pages where the popup is enabled.

0.1.10

  • Escaped generated CAPTCHA and popup form markup with an explicit HTML allowlist.
  • Read the public status query parameter without triggering nonce verification warnings.
  • Retrieved submitted form fields through PHP input filtering and retained field-specific sanitization.

0.1.9

  • Updated plugin and readme metadata; removed the unused Domain Path header.
  • Removed source-code comments except for the required plugin header.

0.1.8

  • Added a setting to load frontend CSS as an external file or inline it.
  • Kept frontend JavaScript limited to enabled popup mode and loaded it in the footer.
  • Refined the default form style.
  • Changed the honeypot wrapper and default field name to website.
  • Shortened the readme short description.

0.1.7

  • Set English as the plugin source language and rely on WordPress translation loading.
  • Removed bundled PO and MO files; retained the updated POT template.
  • Added a dedicated compact layout for the embedded shortcode form, separate from the popup.
  • Kept frontend and admin assets in enqueued CSS and JavaScript files.

0.1.6

  • Sanitize the submitted redirect URL at the point of input.

0.1.5

  • Updated tested WordPress version to 7.1.
  • Removed discouraged textdomain loader and retained bundled translation fallback.
  • Improved sanitization and malformed input handling for form submissions.
  • Clarified read-only status and nonce-protected redirect processing.

0.1.4

  • Added configurable honeypot enable/disable and field name.
  • Prevented honeypot name collisions with visible form field keys.

0.1.3

  • Restored the Italian translation catalog and compiled translation.
  • Updated plugin metadata and translation loading.

0.1.2

  • Development build: consolidated the implementation into one PHP file and shared assets.
  • Removed unused CAPTCHA provider framework.

0.1.1

  • Development build.

0.1.0

  • Initial development build.