You are here

function simpleads_uninstall in SimpleAds 7.2

Same name and namespace in other branches
  1. 7 simpleads.install \simpleads_uninstall()

Implements hook_uninstall().

File

./simpleads.install, line 604
SimpleAds module install.

Code

function simpleads_uninstall() {
  field_delete_field('field_ad_category');
  field_delete_field('field_ad_type');
  field_delete_field('field_ad_image');
  field_delete_field('field_ad_flash');
  field_delete_field('field_ad_text');
  field_delete_field('field_ad_url');
  field_delete_field('field_ad_date');
  node_types_rebuild();
  $vid = db_select('taxonomy_vocabulary', 'tv')
    ->fields('tv', array(
    'vid',
  ))
    ->condition('machine_name', 'simpleads_groups')
    ->execute()
    ->fetchField();
  taxonomy_vocabulary_delete($vid);
  variable_del('menu_options_simpleads');
  variable_del('node_options_simpleads');
  variable_del('comment_simpleads');
  variable_del('simpleads_display_graphs');
}