summaryrefslogtreecommitdiff
path: root/kolab.org/www/drupal-7.26/profiles/minimal/minimal.install
diff options
context:
space:
mode:
Diffstat (limited to 'kolab.org/www/drupal-7.26/profiles/minimal/minimal.install')
-rw-r--r--kolab.org/www/drupal-7.26/profiles/minimal/minimal.install81
1 files changed, 81 insertions, 0 deletions
diff --git a/kolab.org/www/drupal-7.26/profiles/minimal/minimal.install b/kolab.org/www/drupal-7.26/profiles/minimal/minimal.install
new file mode 100644
index 0000000..9cf4fa2
--- /dev/null
+++ b/kolab.org/www/drupal-7.26/profiles/minimal/minimal.install
@@ -0,0 +1,81 @@
+<?php
+/**
+ * @file
+ * Install, update and uninstall functions for the minimal installation profile.
+ */
+
+/**
+ * Implements hook_install().
+ *
+ * Performs actions to set up the site for this profile.
+ *
+ * @see system_install()
+ */
+function minimal_install() {
+ // Enable some standard blocks.
+ $default_theme = variable_get('theme_default', 'bartik');
+ $values = array(
+ array(
+ 'module' => 'system',
+ 'delta' => 'main',
+ 'theme' => $default_theme,
+ 'status' => 1,
+ 'weight' => 0,
+ 'region' => 'content',
+ 'pages' => '',
+ 'cache' => -1,
+ ),
+ array(
+ 'module' => 'user',
+ 'delta' => 'login',
+ 'theme' => $default_theme,
+ 'status' => 1,
+ 'weight' => 0,
+ 'region' => 'sidebar_first',
+ 'pages' => '',
+ 'cache' => -1,
+ ),
+ array(
+ 'module' => 'system',
+ 'delta' => 'navigation',
+ 'theme' => $default_theme,
+ 'status' => 1,
+ 'weight' => 0,
+ 'region' => 'sidebar_first',
+ 'pages' => '',
+ 'cache' => -1,
+ ),
+ array(
+ 'module' => 'system',
+ 'delta' => 'management',
+ 'theme' => $default_theme,
+ 'status' => 1,
+ 'weight' => 1,
+ 'region' => 'sidebar_first',
+ 'pages' => '',
+ 'cache' => -1,
+ ),
+ array(
+ 'module' => 'system',
+ 'delta' => 'help',
+ 'theme' => $default_theme,
+ 'status' => 1,
+ 'weight' => 0,
+ 'region' => 'help',
+ 'pages' => '',
+ 'cache' => -1,
+ ),
+ );
+ $query = db_insert('block')->fields(array('module', 'delta', 'theme', 'status', 'weight', 'region', 'pages', 'cache'));
+ foreach ($values as $record) {
+ $query->values($record);
+ }
+ $query->execute();
+
+ // Allow visitor account creation, but with administrative approval.
+ variable_set('user_register', USER_REGISTER_VISITORS_ADMINISTRATIVE_APPROVAL);
+
+ // Enable default permissions for system roles.
+ user_role_grant_permissions(DRUPAL_ANONYMOUS_RID, array('access content'));
+ user_role_grant_permissions(DRUPAL_AUTHENTICATED_RID, array('access content'));
+}