=== editant Maintenance ===
Contributors: editant
Tags: maintenance, maintenance mode, coming soon, under construction, holding page
Requires at least: 6.0
Tested up to: 7.1
Requires PHP: 7.4
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Put your site into maintenance mode with a branded, configurable holding page while selected roles keep working behind it.

== Description ==

editant Maintenance shows a clean, self-contained holding page to your visitors while you work on the site. Administrators - and any other roles you choose - keep seeing the real site, so you can make and check changes while everyone else sees the maintenance page.

The holding page is styled with the editant brand out of the box and needs nothing from your active theme. You can set the heading, the message, the text colours, and a full-screen background image, replace the header with your own logo and name, and optionally show a contact email.

Front-end requests return an HTTP 503 (Service Unavailable) with a Retry-After header, which is the correct signal to send search engines during planned downtime, and the page is marked noindex so it is not cached in results.

= What's included =

* One-click enable and disable from Settings -> Maintenance Mode.
* Configurable title and subtitle.
* Colour pickers for the title and subtitle text.
* Optional full-screen background image from the media library, with a navy overlay for readability.
* Header you control: the editant logo and name by default, your own logo and/or name, or no header at all.
* Choose which roles bypass maintenance mode; administrators always bypass so you can never lock yourself out.
* Optional contact email shown as a mailto link, obfuscated against scrapers.
* Correct 503 status with Retry-After, and a noindex holding page.
* Automatic cache clearing for common caching plugins when you toggle maintenance mode (host, server, and CDN caches still need a manual purge).
* Self-contained, brand-styled page with bundled IBM Plex fonts - no dependency on the active theme.
* Translation-ready.

= Privacy =

editant Maintenance stores its settings in your own WordPress database and sends no data to any external service. The bundled fonts are served from your own site, not from a third-party font CDN.

== Installation ==

1. Upload the plugin to your `/wp-content/plugins/` directory, or install it via Plugins -> Add New.
2. Activate editant Maintenance through the Plugins menu.
3. Go to Settings -> Maintenance Mode.
4. Set your title, message, colours, and (optionally) a background image and contact email.
5. Tick "Enable maintenance mode" and save. Visitors now see the holding page; you and any bypass roles keep seeing the site.

Requirements:

* WordPress 6.0 or later
* PHP 7.4 or later

== Frequently Asked Questions ==

= Will I get locked out of my own site? =

No. The WordPress admin area and the login page are always reachable, and administrators always bypass maintenance mode regardless of the role settings. If you can log in, you can turn maintenance mode off again.

= Which visitors see the maintenance page? =

Everyone who is not logged in, plus any logged-in user whose roles are not on the bypass list. Administrators always bypass. AJAX, REST API, and cron requests are allowed through so scheduled jobs and integrations keep working.

= Does this hurt my SEO? =

No. While maintenance mode is on, front-end requests return an HTTP 503 with a Retry-After header - the response search engines expect during planned downtime - and the holding page is marked noindex. When you switch maintenance mode off, your normal pages return as usual.

= My visitors still see the normal site after I switched maintenance mode on. Why? =

This is almost always page caching. If a page was cached before you enabled maintenance mode, that cached copy keeps being served and WordPress never runs for those requests, so the maintenance page is never generated.

To confirm caching is the cause, visit your site with a unique query string, for example `https://yoursite.com/?x=12345`. If that shows the maintenance page while the normal address does not, a cache is serving the old copy.

There are two kinds of cache to think about:

* Caching plugins (WP Rocket, W3 Total Cache, WP Super Cache, LiteSpeed, WP Fastest Cache, SiteGround Optimizer, Cache Enabler, Nginx Helper, Autoptimize). editant Maintenance clears these automatically each time you switch maintenance mode on or off, so they normally need no action.
* Host, server, and CDN caches (a server-level Varnish or Nginx cache, or a CDN such as Cloudflare). These sit in front of WordPress and cannot be cleared by any plugin. If your site uses one, clear it once from your hosting control panel or CDN dashboard after enabling maintenance mode, or wait for its cache to expire. A quick check: if the response headers include `Via: ... Varnish`, `X-Varnish`, `X-Cache`, or `CF-Cache-Status`, a host or CDN cache is in play.

= How do I know which cache my host uses? =

Open your site in your browser's developer tools, look at the Network tab, and inspect the response headers for the main page. Headers such as `Via`, `X-Varnish`, `X-Cache`, `Age`, `X-LiteSpeed-Cache`, or `CF-Cache-Status` tell you a host, server, or CDN cache is active and will need a manual purge. Your host's documentation or support can tell you where to clear it.

= Can I use my own design? =

You can set the title, subtitle, text colours, and a full-screen background image, and choose what appears at the top of the page: the editant logo and name (the default), your own logo and/or name, or nothing at all. The page layout and typography are self-contained, so they look the same on any theme.

= Does it work on multisite? =

Yes. Each site keeps its own settings, and uninstalling removes the plugin's settings from every site in the network.

= How do I uninstall completely? =

Deactivate and delete the plugin from the Plugins page. The plugin's `uninstall.php` removes its single settings row. It creates no custom tables and no capabilities.

== Screenshots ==

1. The maintenance page shown to visitors, with the editant logo and name, title, and subtitle over the built-in background.
2. The Settings -> Maintenance Mode admin page: enable toggle, header choice, title and subtitle, colour pickers, background image, bypass roles, and contact email.

== Changelog ==

= 1.0.0 =

* Initial release: enable/disable maintenance mode, a configurable header (editant logo and name, your own logo and/or name, or none), configurable title and subtitle with colour pickers, an optional full-screen background image with a built-in default, per-role bypass with administrators always exempt, optional contact email, correct 503/Retry-After response, automatic cache clearing for common caching plugins on toggle, and a self-contained brand-styled holding page.

== Upgrade Notice ==

= 1.0.0 =

First release of editant Maintenance.
