=== N-Software Email Validator ===
Contributors: mpasic
Tags: email validation, email verification, spam protection, forms, woocommerce
Requires at least: 6.2
Tested up to: 7.1
Stable tag: 1.3.26
Requires PHP: 8.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Real-time email validation for WordPress. Uses the free Email Validator API at email-validaton.com.

== Description ==

N-Software Email Validator is a **free WordPress plugin** that checks email addresses in real time. It connects to the **free** Email Validator service at [email-validaton.com](https://email-validaton.com/).

Create a free account on [email-validaton.com](https://email-validaton.com/), copy your free API key, and paste it in **Settings**. The plugin uses that free API for registration, comments, WooCommerce checkout, contact forms, bulk checks, and Email Health scans.

Plugin homepage: [n-software.net/n-software-email-validator](https://n-software.net/n-software-email-validator/)

= Free service =

This plugin does not include a built-in email checker. Validation is performed by the free Email Validator API at [email-validaton.com](https://email-validaton.com/). Other free tools on that site (domain health, email finder, blacklist monitor) use the same service. You only need a free API key.

= Features =

* Real-time checks via the free [email-validaton.com](https://email-validaton.com/) API
* Registration and comment protection
* Form integrations: Contact Form 7, WPForms, Gravity Forms, WooCommerce, Ninja Forms, Fluent Forms, Formidable, Forminator, MC4WP, WS Forms, Mailster
* Bulk validation from CSV/TXT (up to 5,000 emails)
* Email Health scan of existing users, customers, and comments
* Result caching
* Validation logs and dashboard stats (live vs all)
* Catch-all, mailbox full, disposable, invalid, and other API statuses

= API statuses =

* **valid** — Mailbox confirmed
* **invalid** — Mailbox does not exist
* **risky** — Low confidence
* **catch_all** — Domain accepts all addresses
* **over_quota** — Mailbox is full (allowed through)
* **rate_limited** — Temporary API rate limit
* **disposable** — Temporary / disposable provider
* **unknown** — No definitive answer
* **error** — Check failed

Invalid, disposable, and error are blocked. Valid, risky, catch-all, unknown, and over-quota are allowed.

= Requirements =

* WordPress 6.2 or higher
* PHP 8.0 or higher
* A free API key from [email-validaton.com](https://email-validaton.com/)

== Installation ==

1. Upload the plugin folder to `/wp-content/plugins/`
2. Activate the plugin through the Plugins menu in WordPress
3. Get a free API key at [email-validaton.com](https://email-validaton.com/)
4. Go to **N-Software Email Validator → Settings** and enter the API key
5. A green indicator confirms the free API is connected

== Frequently Asked Questions ==

= Where do I get an API key? =

Sign up for a free account at [email-validaton.com](https://email-validaton.com/) and copy the API key into plugin Settings.

= Is this plugin free? =

Yes. The plugin is free. It uses the free Email Validator API at [email-validaton.com](https://email-validaton.com/).

= What happens when remaining checks run out? =

Forms still submit. Validation pauses until the free API key has remaining checks again. Check your free account at [email-validaton.com](https://email-validaton.com/).

= What email statuses are blocked? =

Invalid, disposable, and error are blocked. Valid, risky, catch-all, unknown, and over-quota are allowed.

= Does this slow down form submissions? =

The API typically responds in under 500 ms. Caching avoids repeating the same address.

= What if the API is unreachable? =

Configure error handling in Settings. Default: emails pass through so forms never break.

= Can I validate emails in bulk? =

Yes. Go to **N-Software Email Validator → Bulk Validate**, upload a CSV/TXT (one email per row, up to 5,000).

== External services ==

This plugin does not validate emails locally. It connects to the Email Validator API at [email-validaton.com](https://email-validaton.com/).

When validation runs (registration, comments, enabled forms, dashboard test, bulk validate, or Email Health), the plugin sends the email address and your API key to that service. The service returns a status (valid, invalid, disposable, catch-all, and others). No data is sent until you save an API key and a check actually runs.

Privacy policy: https://email-validaton.com/privacy
Terms of service: https://email-validaton.com/terms

== Screenshots ==

1. Dashboard — Account overview, today's stats, and single-email validation
2. Settings — API key with connected indicator, validation rules, and form integrations
3. Bulk Validation — Upload and validate emails with a progress bar
4. Logs — Validation history
5. Frontend — Inline validation messages on forms

== Changelog ==

= 1.3.26 =
* Settings: optional “Delete data on uninstall” (off by default — keeps tables/settings on Delete)

= 1.3.25 =
* Plugin Check: silence false-positive InterpolatedNotPrepared on pre-escaped status IN() lists

= 1.3.24 =
* Plugin Check: fix PreparedSQLPlaceholders count for Email Health status IN() queries

= 1.3.23 =
* Package slug n-software-email-validator (matches Text Domain; removes restricted "wp" slug)
* Plugin Check: health SQL prepare, uninstall prefixes, activator table checks

= 1.3.22 =
* Fix critical error on Email Health: restore missing health table creation (ensure_health_tables)

= 1.3.21 =
* WordPress.org review: unique north_ev prefixes (AJAX, options, transients, localize object)
* API key sanitization no longer uses sanitize_text_field (preserves secret characters)
* Documented Email Validator API, privacy, and terms URLs
* Contributors list includes mpasic

= 1.3.20 =
* Bulk Summary and dashboard stats now include catch_all
* Plugin URI set to https://n-software.net/n-software-email-validator/
* Description and UI point only to the free Email Validator API at email-validaton.com

= 1.3.19 =
* Plugin Check: sanitize Email Health AJAX offset/limit/batch_size; prepare dynamic IN queries without interpolated SQL
* Tested up to WordPress 7.1

= 1.3.18 =
* Dashboard stats: separate Live vs All today (Email Health included in All)
* Monthly totals split into Live / Email Health / All
* Validation logs tag source as live or email_health; daily stats use WP timezone

= 1.3.17 =
* Email Health: Delete Selected works for large scans (~20k+) via server-side category delete
* Email Health: load results/emails in chunks so restore no longer fails on huge JSON payloads
* Delete categories use DB counts (button no longer stays disabled when only stats load)

= 1.3.16 =
* Fix WooCommerce customer lookup: use canonical `email` column (detect `email` vs `user_email` at runtime)
* API client: treat HTTP 5xx / empty body / timeouts as retryable (clear wait instead of silent hang)
* Settings: API timeout max raised to 300s for self-hosted deep SMTP verification
* Filter `north_ev_api_base_url` for self-hosted API base URL

= 1.3.15 =
* Fix black-on-black button/badge text under WP admin color schemes and dark mode

= 1.3.14 =
* Fix Email Health freeze after Pause/Stop during net retry or active validation
* Abort in-flight validate AJAX on Pause/Stop; single save when scan loop exits

= 1.3.13 =
* Fix Save Progress false "busy" error when incremental flush lock was held (data was already saved)

= 1.3.1 =
* Fix Save Progress false error "snapshot meta write failed" (WordPress update_option returns false when value unchanged)

= 1.3.0 =
* CRITICAL: Email Health Save Progress rewritten — MySQL UPSERT, never truncates on save
* Previous file-based save cleared results before writing chunks (data loss if any chunk failed)
* Results stored in wp_north_ev_health_results / wp_north_ev_health_emails tables
* Save verifies server row count before reporting success

= 1.2.2 =
* Users → All Users: new Email Status column (Valid / Invalid / Risky / …)
* Status is stored in user meta after validation, registration, and Email Health scans
* Falls back to latest validation log when meta is missing

= 1.2.1 =
* Email Health: Save Progress now writes a full in-memory snapshot to disk (uploads/nev-health-scan/)
* Email Health: fixed silent AJAX failures that cleared the pending queue without saving
* Email Health: file-locked JSONL storage avoids wp_options race/size data loss

= 1.2.0 =
* Email Health: incremental server-side persistence (results no longer lost on tab change)
* Email Health: fixed Pause/Continue (duplicate DOM id broke the Pause button)
* Email Health: interruptible pacing; Stop keeps progress as paused for Continue
* Email Health: Save Progress flushes pending batches reliably
* Dashboard stats: Mailbox Full instead of obsolete Catch-All

= 1.0.0 =
* Initial release
* Real-time email validation via the free email-validaton.com API
* WordPress registration and comment validation
* Contact Form 7, WPForms, Gravity Forms, WooCommerce integrations
* Ninja Forms, Fluent Forms, Formidable, Forminator integrations
* Bulk CSV/TXT validation
* Result caching with configurable TTL
* Dashboard widget
* API connection indicator
* Validation logs with auto-cleanup
