You are here

function custom_breadcrumbs_taxonomy_exit in Custom Breadcrumbs 6.2

Same name and namespace in other branches
  1. 7.2 custom_breadcrumbs_taxonomy/custom_breadcrumbs_taxonomy.module \custom_breadcrumbs_taxonomy_exit()

Implements hook_exit().

File

custom_breadcrumbs_taxonomy/custom_breadcrumbs_taxonomy.module, line 586
This module implements taxonomy_based breadcrumbs using a hybrid of methods developed for the custom_breadcrumbs and taxonomy_breadcrumbs modules. Breadcrumbs are provided for node and taxonomy term pages. If 'Use taxonomy hierarchy' is…

Code

function custom_breadcrumbs_taxonomy_exit() {

  // Optionally, do not cache page on which a taxonomy breadcrumb has been set.
  // For nodes with more than one vocabulary, the breadcrumb may depend on the sequence of pages visited.
  // If the page is cached for anonymous users (normal caching) for performance, the breadcrumb may not reflect
  // the correct sequence. This should not be a problem for authenticated users.
  if (variable_get('custom_breadcrumbs_taxonomy_uncache', FALSE) && isset($_SESSION['custom_breadcrumbs_taxonomy_set'])) {
    global $base_root;
    cache_clear_all($base_root . request_uri(), 'cache_page');
  }
}