You are here

function content_init in Content Construction Kit (CCK) 6

Same name and namespace in other branches
  1. 5 content.module \content_init()
  2. 6.3 content.module \content_init()
  3. 6.2 content.module \content_init()

Implementation of hook_init().

File

./content.module, line 69
Allows administrators to associate custom fields to content types.

Code

function content_init() {
  drupal_add_css(drupal_get_path('module', 'content') . '/theme/content.css');
  if (module_exists('views')) {
    module_load_include('inc', 'content', 'includes/content.views');
  }
  if (module_exists('token') && !function_exists('content_token_values')) {
    module_load_include('inc', 'content', 'includes/content.token');
  }
  if (module_exists('diff') && !function_exists('content_diff')) {
    module_load_include('inc', 'content', 'includes/content.diff');
  }
  if (content_menu_needs_rebuild()) {
    content_clear_type_cache(TRUE);
    menu_rebuild();
    content_menu_needs_rebuild(FALSE);
  }
}