You are here

og_vocab.install in OG Vocabulary 5

Same filename and directory in other branches
  1. 6 og_vocab.install
  2. 7 og_vocab.install

File

og_vocab.install
View source
<?php

function og_vocab_install() {
  switch ($GLOBALS['db_type']) {
    case 'mysql':
    case 'mysqli':
      db_query("CREATE TABLE {og_vocab} (\n            nid INT NOT NULL DEFAULT 0,\n            vid INT NOT NULL DEFAULT 0,\n            KEY `nid` (`nid`)\n          )\n          /*!40100 DEFAULT CHARACTER SET utf8 */ COMMENT = 'relate group nodes to vocabularies';");

      // Update 1
      db_query("UPDATE {system} SET weight = %d WHERE name = '%s'", 5, 'og_vocab');
  }
}

/**
 * Need to increase the weight so that this module will execute after taxonomy
 */
function og_vocab_update_1() {
  db_query("UPDATE {system} SET weight = %d WHERE name = '%s'", 5, 'og_vocab');
}

Functions

Namesort descending Description
og_vocab_install
og_vocab_update_1 Need to increase the weight so that this module will execute after taxonomy