Boost Block - Button: Flush Page's Cache
mikeytown2 - February 3, 2009 - 05:44
| Project: | Boost |
| Version: | 6.x-1.x-dev |
| Component: | Caching logic |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed |
Description
On the "Boost page cache status" Block, adding a button to del that page's cached file would be a nice feature. Also being able to delete the static page via an action would be nice as well. Thus using a rule, if the content is updated you can clear the cache.

#1
I was just thinking along the same line.
Currently Boost removes cache file regardless if it was changed as per the time given in the cache lifetime.
It would be even more efficient if a page would only be updated when it is changed or new comment posted etc etc.
What do you think?
#2
giorgio79, it is already implemented in boost_nodeapi and boost_comment hooks
#3
wow, I may be behind a few versions then :D fantastic, let me check it.
#4
creating an action for boost_cache_expire() would allow one to clear that pages cache via rules, correct? What about clearing the cache for boosted views and other things that are not connected to a node, comment or user? using something like boost_cache_expire(boost_file_path($_GET['q'])). Trying to think of a way to generalize this.
#5
I think this should be accomplishedable with rules or actions..
However it won't be perfect IMO..
As an example, if a user adds a comment, then every page which have recent comments block may need to be refreshed, TRUE ?
#6
Thinking about this more... do this via AHAH or Form API? Add a button to the block that says something like "clear page from cache"; call
boost_cache_expire(). When the page is live, the button says "cache this page"; call drupal_http_request() to get page as an anonymous user.#7
#8
drupal_get_form() will load a form in a block. Creating an action will allow for people to get creative with this; VBO - generate cache, stuff like that. Next step is to write some code.
#9
think we should stay in the simple, but effective. It is supposed to always know the URL of the current page. We are therefore able to empty the cache for this page. (use the $_SERVER['REQUEST_URI'])
In the case of adding a new page, no problem, the cache will activate the next visit to the page.
For the parameters, with the $_SERVER['REQUEST_URI'], the page domain.tld/cat/cat/node?toto=Good, i put in cache domain.tl/cat/cat/node.html => in .htaccess, you accept a GET parameters.
You wan't a block for control the cache ?
If the page is in cache, when you view the block if the page in cache is generated with no block ?
In cacheStatic, i use a javascript for fetch the toolbar, only if the user a permission.
#10
More of a proof of concept, its quite crude but you can flush the pages cache.
#11
Flush the core page cache for the page as well
#12
Committed
#13
Automatically closed -- issue fixed for 2 weeks with no activity.