| 开发者 | easycommerce |
|---|---|
| 更新时间 | 2026年9月16日 17:50 |
| PHP版本: | 7.4 及以上 |
| WordPress版本: | 7.1 |
| 版权: | GPLv2 or later |
| 版权网址: | 版权信息 |
wp-content/cache/nirocache/.DONOTCACHEPAGE or send Cache-Control: no-cache, no-store or private are respected.utm_source, gclid and fbclid share the page's cached copy instead of creating new ones.* wildcards), visitors carrying chosen cookies, or single pages ticked "Don't cache this page" in the editor.X-Niro-Cache: HIT, MISS or BYPASS) for troubleshooting.wp-content/advanced-cache.php: the standard WordPress early-cache file, copied from the plugin. It is only created if no other plugin owns it, and it is removed when you deactivate NiroCache.define( 'WP_CACHE', true ); in wp-config.php: added only if WP_CACHE is not already defined, and removed when you deactivate NiroCache. If wp-config.php is not writable, the settings screen tells you which line to add.wp-content/cache/nirocache/. That directory holds data only: rendered HTML, a small JSON settings file per site, and empty marker files. NiroCache reads them as data and never executes anything it writes there. They are deleted when you deactivate the plugin, and the whole directory is removed when you delete the plugin.
Privacy
NiroCache does not collect or send any data. The cache test makes two requests from your server to your own home page and nowhere else. Cached copies only ever contain pages as seen by visitors who are not logged in.
For developers
Filters:
nirocache_should_cache — return false to keep a rendered page dynamic.nirocache_excluded_urls — URL path patterns that are never cached.nirocache_bypass_cookies — cookie name prefixes that make a visitor bypass the cache.nirocache_ignored_query_params — query parameters that share the cached copy.nirocache_post_purge_urls — URLs cleared when a post changes.nirocache_site_wide_post_types — post types whose changes clear the whole cache.nirocache_conflicting_plugins — page cache plugins to warn about.nirocache_dropin_path and nirocache_wp_config_path — file locations NiroCache manages.nirocache_cache_created — a page was stored.nirocache_url_purged — a URL's cached copies were cleared.nirocache_cache_purged — the whole cache was cleared.nirocache_exclusions_changed — a page was ticked or unticked "Don't cache this page".NIROCACHE_CACHE_DIR constant in wp-config.php to store cached pages somewhere else.
nirocache folder to /wp-content/plugins/.wp-config.php is not writable, add this line near the top of wp-config.php, above the line that says "That's all, stop editing!":
define( 'WP_CACHE', true );Logged-in users always get freshly generated pages, so nobody ever sees someone else's personalised content. Click Run cache test on the NiroCache screen, or open your site in a private browser window, to see what visitors get.
Click Run cache test on the NiroCache screen. It requests your home page twice and reports whether the second request was served from the cache, or why it was not. You can also turn on Debug headers and look for X-Niro-Cache: HIT in your browser's developer tools while logged out.
Yes. Cart, checkout and account pages are never cached, visitors with items in their cart always get fresh pages, and product pages are cleared when their stock changes. Easy Digital Downloads checkout pages are excluded too.
Any server that runs WordPress: Apache, Nginx, LiteSpeed and others. NiroCache uses the standard WordPress early-cache file, so no server configuration is needed.
Running two page caches at once causes unexpected behavior, so NiroCache warns you when it detects one. Deactivate the other plugin's page cache, or turn off NiroCache's page cache. NiroCache never overwrites another plugin's advanced-cache.php.
Tick Don't cache this page in the NiroCache box of the page editor, or add its path under Exclusions > Never cache these URLs on the NiroCache screen. Use /members/* to exclude a section and everything below it.
WordPress form security tokens expire after 12 to 24 hours. Keep the cache lifespan at 10 hours (the default) or lower on sites with forms.
10 hours by default. Updating content clears the affected pages immediately, so the lifespan only matters for changes NiroCache cannot detect. You can choose from 1 hour to 7 days, or never expire.
Deactivating removes the early-cache file and the WP_CACHE line NiroCache added, and deletes cached pages; your settings are kept. Deleting the plugin also removes its settings and the whole cache directory.
wp-content/advanced-cache.php is now copied from a file that ships with the plugin instead of being generated. NiroCache no longer writes PHP anywhere.