Break this code out into its own function

function boost_cache_expire($paths) {
...
  // Get filenames & hash from db
  foreach ($data as $dblookup) {
    $result = db_query("SELECT filename, hash FROM {boost_cache} WHERE page_callback = '%s' AND page_arguments = '%s' AND page_id = '%s'", $dblookup['page_callback'], $dblookup['page_arguments'], $dblookup['page_id']);
    while ($info = db_fetch_array($result)) {
      // Flush expired files
      boost_cache_kill($info['filename'], $info['hash']);
    }
  }
}

This will rock your socks off

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

mikeytown2’s picture

Status: Active » Needs review

This with the rules module will allow you to do this with views, if you know which views contain the node #453908: Hook for panel node types - expiration of static cache; panel containing multiple nodes. It's not automatic like the patch will be, but at least now it can be done.

mikeytown2’s picture

FileSize
2.08 KB
mikeytown2’s picture

FileSize
2.1 KB
mikeytown2’s picture

Status: Needs review » Fixed

committed

mikeytown2’s picture

Status: Fixed » Active

Let the "Boost: Pages cache configuration" block take full advantage of this.

mikeytown2’s picture

Status: Active » Needs review
FileSize
6.57 KB

Fixed an issue with multi sites & now the blocks use the code!

mikeytown2’s picture

Status: Needs review » Fixed

committed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.