advanced_help.install in Advanced Help 5
Same filename and directory in other branches
advanced_help.install Contains install and update functions for advanced_help.
File
advanced_help.installView source
<?php
/**
* @file advanced_help.install
* Contains install and update functions for advanced_help.
*/
function advanced_help_install() {
drupal_set_message('Installing advanced_help.');
switch ($GLOBALS['db_type']) {
case 'mysql':
case 'mysqli':
db_query("CREATE TABLE {advanced_help_index} (\n sid int(10) unsigned NOT NULL default '0',\n module varchar(255) NOT NULL default '',\n topic varchar(255) NOT NULL default '',\n language varchar(12) NOT NULL default '',\n PRIMARY KEY (sid),\n KEY language (language)\n ) /*!40100 DEFAULT CHARACTER SET utf8 */");
break;
case 'pgsql':
db_query("CREATE TABLE {advanced_help_index} (\n sid integer NOT NULL default '0',\n module varchar(255) NOT NULL default '',\n topic varchar(255) NOT NULL default '',\n language varchar(12) NOT NULL default '',\n PRIMARY KEY (sid),\n )");
break;
}
}
function advanced_help_uninstall() {
drupal_set_message('Uninstalling advanced_help.');
switch ($GLOBALS['db_type']) {
case 'mysql':
case 'mysqli':
db_query("DROP TABLE {advanced_help_index}");
break;
case 'pgsql':
db_query("DROP TABLE {advanced_help_index}");
break;
}
variable_del('advanced_help_last_cron');
}
Functions
Name | Description |
---|---|
advanced_help_install | @file advanced_help.install Contains install and update functions for advanced_help. |
advanced_help_uninstall |