function install_select_profile_form in Drupal 5
Same name and namespace in other branches
- 6 install.php \install_select_profile_form()
- 7 includes/install.core.inc \install_select_profile_form()
1 string reference to 'install_select_profile_form'
- install_select_profile in ./
install.php - Find all .profile files and allow admin to select which to install.
File
- ./
install.php, line 413
Code
function install_select_profile_form($profiles) {
foreach ($profiles as $profile) {
include_once $profile->filename;
// Load profile details.
$function = $profile->name . '_profile_details';
if (function_exists($function)) {
$details = $function();
}
// If set, used defined name. Otherwise use file name.
$name = isset($details['name']) ? $details['name'] : $profile->name;
$form['profile'][$name] = array(
'#type' => 'radio',
'#value' => 'default',
'#return_value' => $profile->name,
'#title' => $name,
'#description' => isset($details['description']) ? $details['description'] : '',
'#parents' => array(
'profile',
),
);
}
$form['submit'] = array(
'#type' => 'submit',
'#value' => st('Save configuration'),
);
return $form;
}