/[drupal]/contributions/modules/gmapfield/gmapfield.install
ViewVC logotype

Contents of /contributions/modules/gmapfield/gmapfield.install

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (show annotations) (download) (as text)
Thu Nov 6 06:07:19 2008 UTC (12 months, 2 weeks ago) by binarybill
Branch: MAIN
CVS Tags: HEAD
Branch point for: DRUPAL-6--1
File MIME type: text/x-php
Initial cmooit of GMap Field module.
1 <?php
2 // $Id$
3 /**
4 * @file
5 * Install file for the Image Mapper Module
6 *
7 * @notes
8 *
9 * @todo
10 */
11
12 /**
13 * Implementation of hook_enable().
14 */
15 function gmapfield_enable() {
16 // CCK prep
17 drupal_load('module', 'content');
18 content_notify('enable', 'gmapfield');
19 // Set a message to the user
20 $t_array = array(
21 '@module' => 'GMap Field',
22 );
23 drupal_set_message(t('@module enabled;', $t_array));
24 }
25
26
27 /**
28 * Implementation of hook_disable().
29 */
30 function gmapfield_disable() {
31 // CCK prep
32 drupal_load('module', 'content');
33 content_notify('disable', 'gmapfield');
34 // Set message
35 drupal_set_message(t('@module disabled.', array('@module' => 'GMap Field')));
36 }
37
38 /**
39 * Implementation of hook_install().
40 */
41 function gmapfield_install() {
42 // CCK prep
43 drupal_load('module', 'content');
44 content_notify('install', 'gmapfield');
45 // Set message
46 drupal_set_message(t('@module installed.', array('@module' => 'GMap Field')));
47 }
48
49
50 /**
51 * Implementation of hook_uninstall().
52 */
53 function gmapfield_uninstall() {
54 // CCK prep
55 drupal_load('module', 'content');
56 content_notify('uninstall', 'gmapfield');
57 // Get module variables
58 $results = db_query("select v.name from {variable} as v where name like '%s%%'", 'gmapfield');
59 // Remove variables
60 while($row = db_fetch_array($results)) {
61 variable_del($row['name']);
62 }
63 // Set message
64 drupal_set_message(t('@module uninstalled; Variables removed.', array('@module' => 'GMap Field')));
65 }

  ViewVC Help
Powered by ViewVC 1.1.2