You are here

function domain_theme_install in Domain Access 5

Same name and namespace in other branches
  1. 6.2 domain_theme/domain_theme.install \domain_theme_install()

Implement hook_install()

File

domain_theme/domain_theme.install, line 13
Install file for the Domain Theme module

Code

function domain_theme_install() {
  switch ($GLOBALS['db_type']) {
    case 'mysqli':
    case 'mysql':
      db_query("CREATE TABLE IF NOT EXISTS {domain_theme} (\n       domain_id int(11) NOT NULL default '0',\n       theme varchar(32) NOT NULL default '',\n       settings blob,\n       PRIMARY KEY (domain_id)\n      ) /*!40100 DEFAULT CHARACTER SET UTF8 */ ");
      break;
    case 'pgsql':
      db_query("CREATE TABLE {domain_theme} (\n       domain_id integer NOT NULL default 0,\n       theme varchar(32) NOT NULL default '',\n       settings bytea,\n       PRIMARY KEY (domain_id)\n      )");
      break;
  }
}