activity.install in Activity 5
Same filename and directory in other branches
Install file for activity module.
File
activity.installView source
<?php
/**
* @file
* Install file for activity module.
*/
/**
* Implementation of hook_install().
*/
function activity_install() {
switch ($GLOBALS['db_type']) {
case 'mysql':
case 'mysqli':
db_query("\n CREATE TABLE `activity` (\n `aid` int(11) NOT NULL,\n `uid` int(11) NOT NULL,\n `module` varchar(50) NOT NULL default '',\n `type` varchar(25) NOT NULL default '',\n `action` varchar(25) NOT NULL default '',\n `tokens` mediumtext NOT NULL,\n `timestamp` int(11) NOT NULL\n ) ENGINE=MyISAM DEFAULT CHARSET=latin1;\n ");
break;
case 'pgsql':
db_query("\n CREATE TABLE `activity` (\n `aid` int(11) NOT NULL,\n `uid` int(11) NOT NULL,\n `module` varchar(50) NOT NULL default '',\n `type` varchar(25) NOT NULL default '',\n `action` varchar(25) NOT NULL default '',\n `tokens` mediumtext NOT NULL,\n `timestamp` int(11) NOT NULL\n ) ENGINE=MyISAM DEFAULT CHARSET=latin1;\n ");
break;
}
}
Functions
Name | Description |
---|---|
activity_install | Implementation of hook_install(). |