You are here

auto_nodetitle.install in Automatic Nodetitles 7

Installation file for the automatic nodetitle module.

File

auto_nodetitle.install
View source
<?php

/**
 * @file
 * Installation file for the automatic nodetitle module.
 */

/**
 * Implements hook_install().
 */
function auto_nodetitle_install() {
  db_update('system')
    ->fields(array(
    'weight' => 5,
  ))
    ->condition('name', 'auto_nodetitle', '=')
    ->execute();
}

/**
 * Implements hook_uninstall().
 */
function auto_nodetitle_uninstall() {
  foreach (node_type_get_names('names') as $type => $type_name) {
    variable_del('ant_' . $type);
    variable_del('ant_pattern_' . $type);
    variable_del('ant_php_' . $type);
  }
}

Functions