function feed_path_publisher_install in Feed Path Publisher 5
Same name and namespace in other branches
- 6 feed_path_publisher.install \feed_path_publisher_install()
File
- ./
feed_path_publisher.install, line 3
Code
function feed_path_publisher_install() {
switch ($GLOBALS['db_type']) {
case 'mysql':
case 'mysqli':
db_query('CREATE TABLE {feed_path_publisher} (
fppid int(10) unsigned NOT NULL auto_increment,
title varchar(50) NOT NULL,
path_prefix varchar(100) NOT NULL,
feed varchar(200) NOT NULL,
weight int(11) NOT NULL,
PRIMARY KEY (fppid),
UNIQUE KEY path_prefix (path_prefix, feed),
KEY listing (weight, path_prefix, title)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;');
db_query('CREATE TABLE {feed_path_publisher_roles} (
fpprid int(10) unsigned NOT NULL auto_increment,
fppid int(10) unsigned NOT NULL,
show_hide varchar(50) NOT NULL,
rids varchar(100) NOT NULL,
PRIMARY KEY (fpprid)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;');
break;
case 'pgsql':
drupal_set_message('PostgreSQL is not currently supported.', 'error');
break;
}
}