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

Diff of /contributions/modules/blogroll/blogroll.install

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

revision 1.1, Wed Sep 23 14:09:19 2009 UTC revision 1.1.2.1, Wed Sep 23 14:09:19 2009 UTC
# Line 0  Line 1 
1    <?php
2    // $Id$
3    
4    /**
5     * @file
6     */
7    
8    /**
9     * Implementation of hook_install()
10     */
11    function blogroll_install() {
12     $path = drupal_get_path('module', 'blogroll');
13    
14    
15      if (!node_get_types('blog_blogroll')){
16      include (drupal_get_path('module', 'install_profile_api') . '/contrib/content_copy.inc');
17    drupal_set_message("I rule");
18        install_content_copy_import_from_file($path .'/blog_blogroll.inc');
19      }
20    
21    }
22    
23    /**
24     * Implementation of hook_uninstall()
25     */
26    function blogroll_uninstall() {
27      $result = db_query("SELECT nid FROM {node} WHERE type IN ('blog_blogroll')");
28          while ($node = db_fetch_object($result)) {
29            node_delete($node->nid);
30          }
31          node_type_delete('blog_blogroll');
32    
33    }

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.1.2.1

  ViewVC Help
Powered by ViewVC 1.1.2