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

Contents of /contributions/modules/comment_subscribe/comment_subscribe.install

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


Revision 1.2 - (show annotations) (download) (as text)
Thu Mar 6 08:08:20 2008 UTC (20 months, 3 weeks ago) by zyxware
Branch: MAIN
CVS Tags: DRUPAL-6--1-0, DRUPAL-6--1-1, HEAD
Branch point for: DRUPAL-6--1
Changes since 1.1: +47 -28 lines
File MIME type: text/x-php
Comment_subscribe module ported to Drupal 6.1.
1 <?php
2 // $Id: comment_subscribe.install $
3
4
5 /**
6 * Implementation of hook_install().
7 */
8 function comment_subscribe_install() {
9 // Create tables.
10 drupal_install_schema('comment_subscribe');
11 }
12 /**
13 * Implementation of hook_uninstall().
14 */
15 function comment_subscribe_uninstall() {
16 // Remove tables.
17 drupal_uninstall_schema('comment_subscribe');
18 variable_del('comment_subscribe_default_mailtext');
19 variable_del('comment_subscribe_default_anon_mailalert');
20 variable_del('comment_subscribe_regged_checkbox');
21 variable_del('comment_subscribe_node_alert');
22 }
23 /**
24 * Implementation of hook_schema().
25 */
26 function comment_subscribe_schema() {
27 $schema['z_commentsubscribe'] = array(
28 'description' => t('Comment subscribe id.'),
29 'fields' => array(
30 'sid' => array(
31 'type' => 'serial',
32 'unsigned' => TRUE,
33 'not null' => TRUE,
34 'description' => t('Primary Key: Unique Comment Subscribe ID.'),
35 ),
36 'cid' => array(
37 'type' => 'int',
38 'not null' => TRUE,
39 'description' => t('The {comment}.cid commentid.'),
40 ),
41 'parents' => array(
42 'type' => 'varchar',
43 'length' => 255,
44 'description' => t('Comma-separated list of recipient e-mail addresses.'),
45 ),
46 'subscribe' => array(
47 'type' => 'int',
48 'not null' => TRUE,
49 'default' => 1,
50 'size' => 'tiny',
51 'description' => t('Subscribe status value if comment replies is selected.'),
52 ),
53 'subscribenode' => array(
54 'type' => 'int',
55 'not null' => TRUE,
56 'default' => 0,
57 'size' => 'tiny',
58 'description' => t("Susbcribe node status if node replies is selected."),
59 ),
60 ),
61 'primary key' => array('sid'),
62 );
63
64 return $schema;
65 }
66
67

  ViewVC Help
Powered by ViewVC 1.1.2