Opened 11 years ago
Closed 8 weeks ago
#26806 closed enhancement (wontfix)
Add support for custom SHORTINIT handlers
Reported by: | mgibbs189 | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 3.8 |
Component: | Bootstrap/Load | Keywords: | has-patch dev-feedback reporter-feedback close |
Focuses: | Cc: |
Description
I'm building ajax caching for a plugin and need a handler to conditionally determine whether to continue loading WP (based on whether a cached version exists).
Example handler file: https://gist.github.com/mgibbs189/8345521
The SHORTINIT
constant along with wp-load.php
isn't an option because it forces WP to exit early.
Drop-ins like advanced-cache.php, object-cache.php, or db.php won't work because only 1 plugin at a time can use them. I need for my caching to work in combination with these other plugins (e.g. W3 Total Cache)
Attachments (1)
Change History (10)
#5
in reply to:
↑ description
@
11 years ago
- Keywords reporter-feedback added
Hi @mgibbs189, thanks for the enhancement suggestion!
Replying to mgibbs189:
Drop-ins like advanced-cache.php, object-cache.php, or db.php won't work because only 1 plugin at a time can use them. I need for my caching to work in combination with these other plugins (e.g. W3 Total Cache)
The functionality of the attached gist seems perfect for something like advanced-cache.php
. I don't think we would want to add another directory to wp-content
, though it is kind of appealing to have a place for multiple sunrise type files to live.
I would lean toward the idea of manual advanced cache management in which this code would exist in the same file as the advanced cache code from Batcache or W3TC. Is there a reason this can't happen or is more a matter of installation convenience?
This ticket was mentioned in Slack in #core by jorbin. View the logs.
8 years ago
#8
@
4 months ago
- Keywords close added
The gist that wants to demonstrate usasge no longer is available. I also tend to agree with @jeremyfelt that using the existing dropins (or combining with them) is a better solution that adding a new directory and additional extremely early loading code.
As such, I'm going to recomend this be closed as wontfix
but will leave this open to hear objections.
Updated usage example: https://gist.github.com/mgibbs189/8355995