=== YearAlert — Footer Year Auto-Updater ===
Contributors: yearalert
Tags: copyright, footer, year, copyright year, automatic
Requires at least: 5.0
Tested up to: 7.1
Requires PHP: 7.0
Stable tag: 1.0.1
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Keeps the copyright year in your footer fresh — automatically, forever. Zero configuration: just activate. No account, no settings, no code to paste.

== Description ==

An outdated copyright year in your footer — a stale `© 2021` — makes your site look abandoned. **YearAlert** fixes that automatically and permanently.

Activate the plugin and it keeps the year in your footer current on every page load. There is **nothing to configure** — no account, no API key, no settings page, no code to paste. It runs entirely inside your own site: no data is sent anywhere, and there is no server to depend on.

**It's careful about what it changes.** YearAlert only updates a 4-digit year when it is:

* in a **copyright context** — the same text contains ©, "Copyright" or "(c)"; **or**
* in the **footer zone** — the bottom of the page, where copyright lines live.

That means project or product names ("Apollo 2020") outside the footer are **left untouched**, and a 4-digit run inside a longer number — an order or registration id — or a phone number is never rewritten. Founding dates ("Est. 1998", "Family owned since 2012", "desde 2011") are never touched anywhere, not even in the footer next to your ©, and in a line with a © only the copyright year itself moves.

**Features**

* Zero configuration — activate and you're done.
* Updates single years (`© 2021`) and year ranges (`2019–2024` → updates only the end year).
* Idempotent — never rewrites a year that is already current.
* Leaves founding dates, product names and long ID numbers alone.
* Opt-out per element: add `data-yearalert-ignore` to any element to exclude it and its contents.
* Wrapped so it can never break your page.
* No external requests, no tracking, no account.

== Installation ==

1. In your WordPress admin, go to **Plugins → Add New → Upload Plugin**.
2. Choose the `yearalert.zip` file and click **Install Now**.
3. Click **Activate**.

That's it. There are no settings — the copyright year in your footer now stays current automatically.

== Frequently Asked Questions ==

= Do I need to configure anything? =

No. Activate the plugin and it works. There is no settings page by design.

= Will it change other years on my page, like a founding date? =

No. It only updates a year that is next to a ©/"Copyright"/"(c)" token or that sits in the footer zone at the bottom of the page. Founding dates ("Established 2008", "since 2015", "Founded in 2009") are never touched, even in the footer; product names and long ID numbers are not touched either.

= Does it send my data anywhere? =

No. The plugin loads one small script file that reads the current date in the visitor's browser and updates the year locally. Nothing is sent to any external server, and there is no account.

= How do I stop it from touching a specific element? =

Add the attribute `data-yearalert-ignore` to that element. The element and everything inside it will be left alone.

= Does this improve my SEO? =

No, and we won't claim it does — the copyright year is not a search-ranking factor. What it improves is the impression a human visitor forms: a current year makes your business look active and open.

= Does it work with page builders and caching plugins? =

Yes. The script runs in the browser after the page loads and re-checks briefly to catch footers that builders inject late, so it works with common builders and caching.

== Screenshots ==

1. Before and after: a stale `© 2021` footer becomes the current year automatically.
2. Activate and done — no settings page to configure.

== Changelog ==

= 1.0.1 =
* The script is now enqueued as a proper asset via `wp_enqueue_script()` (WordPress.org Plugin Check compliance). Behavior is unchanged.

= 1.0.0 =
* Initial release. Zero-config client-side footer copyright-year updater with copyright-context and footer-zone gating, range support, idempotency, and per-element opt-out.

== Upgrade Notice ==

= 1.0.1 =
Internal packaging improvement (enqueued script). No behavior change.
