spaces_ui.install in Spaces 5.2
File
spaces_ui.install
View source
<?php
function spaces_ui_install() {
switch ($GLOBALS['db_type']) {
case 'mysqli':
case 'mysql':
db_query("CREATE TABLE {spaces_features_ui} (\n feature varchar(30) NOT NULL default '',\n value longtext NOT NULL default '',\n PRIMARY KEY (feature)\n ) /*!40100 DEFAULT CHARACTER SET UTF8 */");
}
}
function spaces_ui_uninstall() {
db_query('DROP TABLE {spaces_features_ui}');
}
function spaces_ui_update_1() {
$update = array();
$update[] = update_sql("ALTER TABLE {spaces_features_ui} DROP COLUMN label");
$update[] = update_sql("ALTER TABLE {spaces_features_ui} DROP COLUMN description");
$update[] = update_sql("ALTER TABLE {spaces_features_ui} ADD COLUMN value longtext NOT NULL default '' AFTER feature");
return $update;
}