'Drupal (minimal)', 'description' => 'Create a Drupal site with only required modules enabled.' ); } /** * Return a list of tasks that this profile supports. * * @return * A keyed array of tasks the profile will perform during * the final stage. The keys of the array will be used internally, * while the values will be displayed to the user in the installer * task list. */ function expert_profile_task_list() { } /** * Perform any final installation tasks for this profile. */ function expert_profile_tasks(&$task, $url) { // Enable some standard blocks. $values = array( array( 'module' => 'system', 'delta' => 'main', 'theme' => 'garland', 'status' => 1, 'weight' => 0, 'region' => 'content', 'pages' => '', 'cache' => -1, ), array( 'module' => 'user', 'delta' => 'login', 'theme' => 'garland', 'status' => 1, 'weight' => 0, 'region' => 'left', 'pages' => '', 'cache' => -1, ), array( 'module' => 'system', 'delta' => 'navigation', 'theme' => 'garland', 'status' => 1, 'weight' => 0, 'region' => 'left', 'pages' => '', 'cache' => -1, ), array( 'module' => 'system', 'delta' => 'management', 'theme' => 'garland', 'status' => 1, 'weight' => 1, 'region' => 'left', 'pages' => '', 'cache' => -1, ), array( 'module' => 'system', 'delta' => 'help', 'theme' => 'garland', '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(); } /** * Implement hook_form_alter(). * * Allows the profile to alter the site-configuration form. This is * called through custom invocation, so $form_state is not populated. */ function expert_form_alter(&$form, $form_state, $form_id) { if ($form_id == 'install_configure') { // Set default for site name field. $form['site_information']['site_name']['#default_value'] = $_SERVER['SERVER_NAME']; } }