1.12.x views.api.php hook_views_invalidate_cache()
1.10.x views.api.php hook_views_invalidate_cache()
1.11.x views.api.php hook_views_invalidate_cache()
1.7.x views.api.php hook_views_invalidate_cache()

Allow modules to respond to the Views cache being invalidated.

This hook should fire whenever a view is enabled, disabled, created, updated, or deleted.

See also

views_invalidate_cache()

Related topics

File

modules/views/views.api.php, line 972
Describe hooks provided by the Views module.

Code

function hook_views_invalidate_cache() {
  cache('mymodule')->deletePrefix('views:');
}