=== Plane SEO ===
Contributors: planehost
Tags: seo, schema, sitemap, redirects, arabic
Requires at least: 6.4
Tested up to: 7.1
Requires PHP: 8.1
Stable tag: 0.3.0-dev
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Original SEO toolkit for WordPress, Arabic and English, RTL ready.

== Description ==

Development build. Try it on a test site first.

* Titles and meta descriptions with templates (%title% %sep% %sitename% …) per post type, taxonomy and archive, plus per-post and per-term overrides.
* Canonical URLs, robots meta (index/noindex, nofollow, noarchive, nosnippet, noimageindex), Open Graph and X cards.
* Schema.org JSON-LD in one @graph: Organization or Person, WebSite with search, WebPage / CollectionPage / ProfilePage, BlogPosting / Article / NewsArticle, ImageObject, BreadcrumbList.
* XML sitemaps at /sitemap_index.xml (replaces wp-sitemap.xml), split per type, images, cached, human-readable view.
* robots.txt additions and automatic Sitemap line (a physical robots.txt file is detected).
* Breadcrumbs: [plane_seo_breadcrumbs] shortcode and plane_seo_breadcrumbs() for themes.
* Redirects 301/302/307/308/410/451 with exact, prefix and regex matching, loop and chain protection, CSV import/export.
* 404 monitor grouped by URL, bots filtered, no IP addresses stored, automatic clean-up.

If Yoast SEO, Rank Math, All in One SEO, SEOPress or The SEO Framework is active, Plane SEO does not print front-end tags (to avoid duplicates) until you deactivate the other plugin or force output in Settings → Advanced.

* Import from Yoast SEO and Rank Math (Plane SEO → Import, or `wp plane-seo import`), with one-click undo.

Not yet included: content analysis, Site Doctor, WooCommerce and Local SEO schema, Search Console.

== Installation ==

1. Upload the plugin from Plugins → Add New → Upload Plugin, or copy the `plane-seo` folder to `wp-content/plugins/`.
2. Activate it. Plane SEO creates its tables and settings automatically (also on every site of a Multisite network when network-activated).
3. Coming from Yoast SEO or Rank Math? Open Plane SEO → Import, run the import, check a few pages, then deactivate the old plugin.
4. Review Plane SEO → Settings and submit /sitemap_index.xml in Google Search Console.

== Frequently Asked Questions ==

= Does the import change my Yoast SEO or Rank Math data? =

No. Their data is only read, so you can switch back at any time. Plane SEO keeps a backup of its own values and offers one-click undo.

= Why are there no SEO tags on my pages? =

Another SEO plugin is still active. Plane SEO stays quiet to avoid duplicate tags until you deactivate it, or until you enable "force output" in Settings → Advanced.

= Does the 404 monitor store visitor IP addresses? =

No. It stores the URL, referrer, hit count and dates only, and deletes old rows automatically.

== Changelog ==

= 0.3.0-dev =
* Import from Yoast SEO and Rank Math: post/term titles, descriptions, focus keywords, canonicals, robots, social fields, schema type, settings and redirects. Read-only on the source, keeps existing values, resumable, one-click undo, WP-CLI `wp plane-seo import`.
* Tested against real Yoast SEO 28.9 and Rank Math 1.0.282 data. Imports the default article type and treats disabled author/date archives as noindex.
* Custom social title and description now render %variables%.
* Second review fixes: saving a category no longer drops imported fields the term screen does not show (social, focus keyword, breadcrumb title, extra robots flags); "//host" redirect targets rejected and regex results kept on this site; bulk redirect import validates in linear time; fresh installs create source_key directly and the backfill runs in batched updates; sitemap primes post terms when permalinks use %category%; new %currentdate% and %currentmonth% variables (imported from Yoast/Rank Math); editor counter fix.
* Redirects scale to large sites: exact redirects are looked up by an indexed key (one query) and only prefix/regex rules are cached. Tested with 20,000 redirects: cache 3 MB → 5 KB, lookup about 5× faster.
* Fixes from an external code review: sitemap cache keeps one entry per file; featured images loaded in one query; CSV redirect import checks rows in memory (fast on large files); wider CSV formula guard; imported relative image URLs made absolute; X/Twitter fields used when Facebook fields are empty; all focus keywords kept; Yoast logos read from attachment IDs; Yoast rows for deleted terms skipped; undo state correct when parts are undone separately; editor preview fills %variables%; admin CSS/JS enqueued as files; network deactivation cleans every site.

= 0.2.0-dev =
* SEO core: meta, social tags, schema graph, sitemaps, robots.txt, breadcrumbs, redirects, 404 monitor, settings screen, editor meta box, term fields.

= 0.1.0-dev =
* Core framework: container, module registry, typed settings, capabilities,
  versioned migrations, encrypted secrets, redacting logger, job queue.
