Boost: add rudimentary plugin system to cache system #40091
Labels
[Boost Feature] Page Cache
[Plugin] Boost
A feature to speed up the site and improve performance.
[Type] Enhancement
Changes to an existing feature — removing, adding, or changing parts of it
We should allow sites to customize or interact with the caching process when pages are served, but that code loads before most of WordPress. This code can still use actions and filters, since they are loaded very early. As part of a separate PR, we should add more filters and hooks to the caching system.
We will need to load this code and execute it when advanced-cache.php loads.
The loader will check for the existence of a particular file and load that, executing it as a PHP script. By default, that should be wp-content/boost-cache/extend.php
Since the wp-content/boost-cache/ directory is made by the web server, the site owner may not have write access to it, so we should first check for a constant that points at where the file should be. That constant can be defined in wp-config.php, which again might not be writable, but it's one modification vs many modifications to a file in a read-only directory.
I'll leave it up to the implementation to decide on what constant to use.
The text was updated successfully, but these errors were encountered: