=== PageSpeed.fr ===
Tags: performance, cache, images, optimization
Requires at least: 6.6
Tested up to: 7.1
Requires PHP: 8.1
Stable tag: 0.1.0
License: GPL-2.0-or-later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Conservative local page caching and targeted native media improvements for small WordPress websites. No external service required.

== Description ==

PageSpeed.fr provides local caching for single-site WordPress brochure websites. It keeps public HTML pages in a local disk cache, invalidates the cache when WordPress content changes and applies targeted image attribute corrections.

Developed by MetaLeads. Support: contact@pagespeed.fr. PageSpeed.fr is an independent project and is not affiliated with Google or the WordPress Foundation.

= Available in version 0.1.0 =

* Early HTML cache using an owned advanced-cache.php drop-in.
* Maximum cache lifetime of five minutes, reduced when origin freshness directives require it.
* Purge when posts, comments, navigation, themes, plugins or selected site settings change.
* Progressive warmup of up to ten local URLs via WP-Cron.
* Asynchronous image decoding when no decoding attribute was provided.
* Reliable missing dimensions for full-size WordPress attachment images when the source matches attachment metadata exactly.
* Removal of lazy loading from an image already explicitly marked with high fetch priority.
* A French-language settings page with diagnostics, pause, purge and warmup actions.

WordPress already provides responsive images and loading-priority decisions. PageSpeed.fr preserves that native behavior; it does not claim those core features as a new proprietary engine.

= Conservative cache exclusions =

The extension bypasses requests containing any cookie, query string, authentication or range headers. It does not cache logged-in sessions, protected content, forms, nonce-bearing HTML, private/no-cache responses, most Vary responses, or non-200 responses. The cache is limited to 500 entries and pages no larger than 1 MiB. Multisite, WooCommerce and Easy Digital Downloads are not supported by this version.

An existing third-party advanced-cache.php file is never overwritten. If WP_CACHE is already defined with an incompatible value, the existing definition is preserved and activation stops with a diagnostic.

= Files and configuration changes =

Installing the plugin alone does not turn on the optimizations. An administrator must explicitly select "Activer les optimisations" in Settings > PageSpeed.fr.

That action creates wp-content/cache/pagespeed-fr and an identified advanced-cache.php file. When needed and permitted, it inserts an identified, reversible WP_CACHE block into wp-config.php. Nonstandard or non-writable configurations require administrator assistance.

Pausing removes the owned cache reader and managed configuration block. If a different cache owner has replaced the reader, its file and WP_CACHE dependency are preserved. Deactivation stops the scheduled task and clears PageSpeed.fr HTML entries. Uninstall removes the plugin's remaining settings and owned cache support files. Unexpected files and third-party cache files are preserved.

= External services and privacy =

This version does not connect to any external service, create accounts, collect analytics, send email or transfer site content to PageSpeed.fr. Warmup uses WordPress' safe HTTP client to request up to ten URLs on the site's own configured host, without visitor cookies. No third-party fonts or scripts are loaded by the administration screen.

Do not use cached HTML as a backup. It is public content and is automatically discarded. Test the plugin on a copy of your site before enabling it on a production site.

= Not included in this release =

Remote image conversion to WebP/AVIF, CDN delivery, critical CSS generation, JavaScript scheduling and a remote dashboard are not implemented in version 0.1.0. No subscription or API key is required. This is not a trial of locked local features. No PageSpeed score, Core Web Vitals result or search ranking is guaranteed.

== Installation ==

1. Download the pagespeed-fr ZIP.
2. In WordPress, open Plugins > Add New Plugin > Upload Plugin.
3. Select the ZIP, install it and activate PageSpeed.fr.
4. Open Settings > PageSpeed.fr and review the compatibility information.
5. On a copy of your site first, click "Activer les optimisations".
6. Verify a public page twice without cookies. The X-PageSpeed-Fr-Cache response header should change from MISS to HIT if the page is eligible.
7. Check menus, forms, media, mobile layouts and a publication update before enabling it in production.

== Frequently Asked Questions ==

= Does the plugin require an account or payment? =

No. This extension does not use an external optimization service.

= Why is my page not cached? =

The cache deliberately bypasses cookies, URL parameters, forms, nonces, private responses and unsupported application flows. A missing HIT is not necessarily an error. The original WordPress page continues to be served.

= Will this convert my images or deliver them through a CDN? =

No. Those features are not included in 0.1.0. Existing media files are not rewritten or converted.

= Does it change the theme, CSS or JavaScript? =

The plugin does not rewrite theme files, minify CSS, delay scripts or remove resources. It applies documented image-attribute changes to generated HTML and caches eligible complete pages.

= Is the original HTML restored when paused? =

Pausing disables media filters and removes the owned early cache reader. WordPress generates the original pages again. Another upstream cache may need its own purge; PageSpeed.fr does not control unrelated hosting caches.

= How fresh is the cache? =

At most five minutes, sometimes less according to the origin response. WordPress content events purge entries immediately. Updates made directly to files or an external database may require the manual purge button.

= What happens if WordPress cron is disabled? =

Warmup does not progress until a scheduler runs WordPress cron. Eligible public visits still fill the cache normally. The diagnostic counter reports attempted warmup tasks, not guaranteed cache hits.

= Can I use this alongside another cache plugin? =

Not without a compatibility review. The extension refuses to overwrite another advanced-cache.php. Host-level caches may not use that file and still require manual review.

= What should I do if an issue appears? =

Use Settings > PageSpeed.fr > Suspendre. If the administration area is unavailable, deactivate PageSpeed.fr using the normal WordPress recovery method. Keep a recent backup and contact contact@pagespeed.fr with the plugin version, affected URL and reproduction steps, without credentials.

== Screenshots ==

1. Local optimization status, activation and reversible suspension controls.
2. Cache diagnostics and compatibility information.

== Changelog ==

= 0.1.0 =

* Local caching: guarded early HTML cache, explicit activation and ownership-aware cleanup.
* Conservative request/response eligibility, revision-based purging and bounded warmup.
* Native media attribute corrections and a French diagnostics screen.
* No external service dependency.

== Upgrade Notice ==

= 0.1.0 =

Initial release. Test on a copy of your site before using it on production. Back up your files and database.
