content_clear_type_cache

Versions
5
content_clear_type_cache()
6
content_clear_type_cache($rebuild_schema = FALSE)

Clear the cache of content_types; called in several places when content information is changed.

▾ 25 functions call content_clear_type_cache()

content_alter_db_cleanup in contrib/cck/includes/content.admin.inc
Helper function for handling cleanup operations when schema changes are made.
content_copy_import_form_submit in contrib/cck/modules/content_copy/content_copy.module
Submit handler for import form. For each submitted field: 1) add new field to the database 2) execute the imported field macro to update the settings to the imported values
content_disable in contrib/cck/content.install
Implementation of hook_disable().
content_display_overview_form_submit in contrib/cck/includes/content.admin.inc
Submit handler for the display overview form.
content_enable in contrib/cck/content.install
Implementation of hook_enable().
content_extra_field_weight in contrib/cck/content.module
Retrieve the user-defined weight for non-CCK node 'fields'.
content_field_instance_create in contrib/cck/includes/content.crud.inc
Create a new field instance.
content_field_instance_delete in contrib/cck/includes/content.crud.inc
Delete an existing field instance.
content_field_instance_update in contrib/cck/includes/content.crud.inc
Update an existing field instance.
content_field_overview_form in contrib/cck/includes/content.admin.inc
Menu callback; listing of fields for a content type.
content_field_overview_form_submit in contrib/cck/includes/content.admin.inc
content_module_delete in contrib/cck/includes/content.crud.inc
Delete all data related to a module.
content_notify in contrib/cck/content.module
Modules notify Content module when uninstalled, disabled, etc.
content_type_create in contrib/cck/includes/content.crud.inc
Make changes needed when a content type is created.
content_type_delete in contrib/cck/includes/content.crud.inc
Make changes needed when a content type is deleted.
content_type_update in contrib/cck/includes/content.crud.inc
Make changes needed when an existing content type is updated.
content_update_6001 in contrib/cck/content.install
Rename node_field and node_field_instance tables.
content_update_6002 in contrib/cck/content.install
Get rid of automatic per content tables for content types that have no fields. Switching to adding those tables only when needed.
nodereference_node_type in contrib/cck/modules/nodereference/nodereference.module
Implementation of hook_node_types.
nodereference_update_6000 in contrib/cck/modules/nodereference/nodereference.install
All fields must allow NULL values to indicate empty fields.
nodereference_update_6001 in contrib/cck/modules/nodereference/nodereference.install
Create an index by node reference column for all fields.
number_update_6000 in contrib/cck/modules/number/number.install
Rename old decimal fields, which were really floats, to float
text_update_6001 in contrib/cck/modules/text/text.install
Set all columns to accept NULL values and set empty string values in the database to NULL.
userreference_update_6001 in contrib/cck/modules/userreference/userreference.install
Create an index by user reference column for all fields.
userreference_update_6002 in contrib/cck/modules/userreference/userreference.install
Convert 'referenceable_status' option from array to integer to match the change in the field settings form where the element has been changed from a checkboxes element (array) to a radios element (integer).

Code

contrib/cck/content.module, line 1547

<?php
function content_clear_type_cache($rebuild_schema = FALSE) {
  cache_clear_all('*', content_cache_tablename(), TRUE);
  _content_type_info(TRUE);

  // Refresh the schema to pick up new information.
  if ($rebuild_schema) {
    $schema = drupal_get_schema(NULL, TRUE);
  }

  if (module_exists('views')) {
    // Needed because this can be called from .install files
    module_load_include('module', 'views');
    views_invalidate_cache();
  }
}
?>