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

Contents of /contributions/modules/photoblog/photoblog.install

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


Revision 1.2 - (show annotations) (download) (as text)
Sat Dec 30 07:38:46 2006 UTC (2 years, 11 months ago) by davidlesieur
Branch: MAIN
CVS Tags: HEAD
Changes since 1.1: +2 -4 lines
File MIME type: text/x-php
Added option to start from the first post instead of the latest post. Nice for slideshows.
1 <?php
2
3 /**
4 * Implementation of hook_uninstall().
5 */
6 function photoblog_uninstall() {
7 $vid = variable_get('photoblog_vocabulary', 0);
8 db_query("DELETE t FROM {term_data} td, {term_node} t WHERE td.vid = %d AND td.tid = t.tid", $vid);
9 db_query("DELETE t FROM {term_data} td, {term_hierarchy} t WHERE td.vid = %d AND td.tid = t.tid", $vid);
10 db_query("DELETE t FROM {term_data} td, {term_relation} t WHERE td.vid = %d AND (td.tid = t.tid1 OR td.tid = t.tid2)", $vid);
11 db_query("DELETE t FROM {term_data} td, {term_synonym} t WHERE td.vid = %d AND td.tid = t.tid", $vid);
12 db_query("DELETE td FROM {term_data} td WHERE td.vid = %d", $vid);
13 db_query("DELETE v, vt FROM {vocabulary} v, {vocabulary_node_types} vt WHERE v.vid = %d AND v.vid = vt.vid", $vid);
14 db_query("DELETE FROM {variable} WHERE name LIKE 'photoblog_%'");
15 cache_clear_all('variables', 'cache');
16 }

  ViewVC Help
Powered by ViewVC 1.1.2