function tripal_core_install

2.x tripal_core.install tripal_core_install()
3.x tripal_core.install tripal_core_install()
1.x tripal_core.install tripal_core_install()

Implementation of hook_install().

Related topics

File

tripal_core/tripal_core.install, line 13
Contains functions used to install/uninstall tripal_core.

Code

function tripal_core_install() {

  // make the data directory for this module
  $data_dir = file_directory_path() . "/tripal";
  if (!file_check_directory($data_dir, FILE_CREATE_DIRECTORY)) {
    $message = "Cannot create directory $data_dir. This module may not " .
      "behave correctly without this directory.  Please  create " .
      "the directory manually or fix the problem and reinstall.";
    drupal_set_message(check_plain($message), 'error');
    watchdog('tripal_core', $message, array(), WATCHDOG_ERROR);
  }

  // create the tables that manage materialized views and jobs
  drupal_install_schema('tripal_core');

}