You are here

function akamai_nodeapi in Akamai 6

Same name and namespace in other branches
  1. 6.2 akamai.module \akamai_nodeapi()

Implementation of hook_nodeapi().

When nodes are modified, clear URL from the Akamai cache. Clear base node/% url as well as aliases.

File

./akamai.module, line 80
akamai.module Integration with the Akamai CDN Cache Control Web Service.

Code

function akamai_nodeapi(&$node, $op) {
  switch ($op) {
    case 'update':
    case 'delete':
      $url = base_path() . "node/{$node->nid}";
      akamai_clear_url($url, array(
        'email' => AKAMAI_EMAIL_DISABLE,
      ), $node);
      break;
  }
}