=== M SEO Editor ===
Contributors: majevski
Author: Vitold Majevski
Author URI: https://majevski.com
Plugin URI: https://majevski.com/m-seo-editor
Tags: seo, meta, open graph, sitemap, schema
Requires at least: 6.5
Tested up to: 7.0
Requires PHP: 7.4
Stable tag: 1.1.2
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Lightweight SEO: meta titles and descriptions, Open Graph, Twitter Cards, XML sitemaps, and Schema.org structured data, with WooCommerce support.

== Description ==

M SEO Editor makes any WordPress site easy to optimise for Google, Bing, and social networks — without the bloat. Install it, and sensible defaults take over immediately; open the SEO box on any post to fine-tune.

**Search engine optimisation**

* Edit the meta title and meta description of any post, page, product, or custom post type
* Live Google snippet preview with character and pixel-width guidance
* Title templates with variables (`%%title%%`, `%%sitename%%`, `%%sep%%`, `%%excerpt%%`, `%%category%%`, and more)
* Canonical URL override, noindex and nofollow controls per post
* Clean `<title>` handling through the WordPress title API — no output buffering

**Social sharing (Open Graph & Twitter Cards)**

* Automatic Open Graph tags for every page: `og:title`, `og:description`, `og:image`, `og:type`, `og:url`, `og:site_name`, `og:locale`
* Override the social title, description, image, and og:type per post
* Twitter Card tags with automatic large-image/summary selection
* Default social image fallback for content without images

**XML sitemaps**

* Fast sitemap index at `/sitemap.xml` with per-content-type sitemaps
* Accurate `lastmod` dates, image entries, and a readable browser view (XSL)
* WooCommerce product sitemap including gallery images
* Noindexed and excluded content is left out automatically
* `Sitemap:` line added to robots.txt

**Schema.org structured data**

* A single JSON-LD graph per page: WebSite, Organization or Person, WebPage, BreadcrumbList, and Article
* WooCommerce Product schema with price, availability, sale dates, brand, GTIN, and review ratings — replacing WooCommerce's default output so nothing is duplicated
* Knowledge-graph settings: organisation or person, name, logo, and social profiles

**WooCommerce**

* Product Open Graph tags (`product:price:amount`, `product:price:currency`, `product:availability`) for Facebook catalogues and Pinterest Rich Pins
* Rich Product schema for simple and variable products
* Shop page and product category archives handled correctly

**Lightweight by design**

* No frameworks, no build step, no jQuery, no cron jobs, no custom tables
* Frontend output is a handful of tags computed on the fly — fully page-cache safe
* Stands down automatically (with a notice) when another SEO plugin is active

== Installation ==

1. Upload the `m-seo-editor` folder to `/wp-content/plugins/`, or install the ZIP via Plugins → Add New → Upload.
2. Activate the plugin through the Plugins screen.
3. Defaults work immediately. Visit **M SEO** in the admin menu to set your separator, knowledge-graph details, default social image, and sitemap preferences.
4. Edit any post, page, or product and use the **SEO — M SEO Editor** box to fine-tune titles, descriptions, and social previews.

== Frequently Asked Questions ==

= Does it work with the block editor and the classic editor? =

Yes. The SEO box appears below the editor in both, and on WooCommerce product screens.

= Do I need to configure anything for the sitemap? =

No. `/sitemap.xml` works right after activation (the plugin flushes permalinks for you). On sites using plain permalinks the sitemap is served at `/?mse_sitemap=index` and robots.txt points there automatically.

= Why do I not see the plugin's tags in my page source? =

If another SEO plugin (Yoast SEO, Rank Math, All in One SEO, SEOPress, The SEO Framework) is active, M SEO Editor stands down to avoid duplicate tags and shows an admin notice. Your data is kept, so you can switch at any time. If your sitemap shows another plugin's output or a 404, check for a physical `sitemap.xml` file in your web root or a server rewrite rule that intercepts the URL before WordPress.

= Which template variables can I use? =

`%%title%%`, `%%sitename%%`, `%%tagline%%`, `%%sep%%`, `%%excerpt%%`, `%%category%%` — plus `%%price%%` and `%%sku%%` when WooCommerce is active.

= Is it translatable? =

Yes, fully — the POT template ships in `/languages`, and wp.org language packs load automatically.

= Which filters can developers use? =

All output is overridable without editing the plugin. The most useful filters:

* `mse_settings` — filter the settings array at read time (e.g. per-language overrides with WPML/Polylang)
* `mse_title`, `mse_description`, `mse_canonical` — final values per request, receiving the resolved context
* `mse_og_tags`, `mse_twitter_tags`, `mse_og_type`, `mse_og_image` — social tag set and its inputs
* `mse_robots_flags` — noindex/nofollow decisions per context
* `mse_template_vars` — register your own `%%variables%%` (name => callable)
* `mse_schema_graph`, `mse_schema_product`, `mse_schema_article_types`, `mse_schema_search_action`, `mse_breadcrumb_trail` — structured data nodes before output
* `mse_sitemap_post_types`, `mse_sitemap_taxonomies`, `mse_sitemap_entry`, `mse_sitemap_term_entry`, `mse_sitemap_index`, `mse_sitemap_query_args`, `mse_sitemap_max_urls` — sitemap contents (return an empty entry to drop a URL)
* `mse_post_types`, `mse_metabox_post_types`, `mse_register_meta_args` — where the SEO box appears and how meta is registered
* `mse_context` — the resolved request context all other decisions key off
* `mse_seo_conflict` — return `''` to force output even when another SEO plugin is detected, or a name to stand down
* `mse_output_comment`, `mse_sitemap_taxonomy_choices` — cosmetic and UI tweaks

= Where do I get support? =

Write to pagalba@majevski.com or visit https://majevski.com — support is available in English and Lithuanian.

== Privacy ==

M SEO Editor does not collect, store, or transmit any personal data. It adds no cookies, makes no external requests, and does not ping search engines. The optional users/author sitemap is deliberately not generated.

== Changelog ==

= 1.1.2 =
* Fixed: an update that could not be downloaded now says why. WordPress gives a package download five minutes to finish, which is longer than any host allows a single admin request to run, so when the connection to majevski.com stalled the request was cut off before WordPress could report anything and the Plugins screen showed only the browser's own "Connection lost or the server is busy". Downloads of this plugin's releases are now capped at sixty seconds — far more than a release archive needs, and short enough that the real transport error is reported on the screen instead of the request dying silently.
* New: a Site Health check under Tools → Site Health → Status, "M SEO Editor can reach its update server". It makes the same two calls the installer makes — the release manifest, then the package itself — and prints the exact error when either fails, so a blocked outbound connection is named as such instead of appearing as a failed update.

= 1.1.1 =
* Fixed: new releases now appear on the Plugins screen within an hour instead of up to a day. WordPress only re-checks for updates every 12 hours by default and the release manifest was cached for another 12 — visiting the Plugins screen now forces a fresh check (at most hourly), and the manifest cache lasts one hour.
* New: a "Check for updates" link in this plugin's row on the Plugins screen — click it and, if a newer release exists, the native "update now" link is active immediately.

= 1.1.0 =
* New: automatic update checks against majevski.com. When a newer release is published, WordPress shows its standard update prompt with one-click install; a "View details" popup shows the changelog. The update channel is pinned to https://majevski.com over HTTPS, checks are cached and fail open, and equal or older versions are never offered.

= 1.0.0 =
* Initial release: meta title/description editing, Open Graph and Twitter Cards, canonical/noindex/nofollow controls, XML sitemaps with images and XSL view, Schema.org JSON-LD graph, WooCommerce product schema, OG tags, and product sitemap.

== Upgrade Notice ==

= 1.1.0 =
Adds self-hosted update checks: from this version on, new releases appear in the normal WordPress update flow. Install this version manually once — older versions do not know about the update channel yet.

