function domain_conf_api in Domain Access 5
Same name and namespace in other branches
- 6.2 domain_conf/domain_conf.module \domain_conf_api()
- 7.3 domain_conf/domain_conf.module \domain_conf_api()
- 7.2 domain_conf/domain_conf.module \domain_conf_api()
Retrieves elements from hook_domainconf() and formats them as needed.
Parameters
$all: Should the function return all hook implementations or just those marked with the domain_settings flag. Defaults to FALSE. Used to determine if we are loading configuration options specific to the Domain Access module.
Return value
An array of form elements according to the FormsAPI or an empty array.
3 calls to domain_conf_api()
- domain_conf_default in domain_conf/
domain_conf.module - Special configuration options for the main domain.
- domain_conf_form_alter in domain_conf/
domain_conf.module - Implement hook_form_alter()
- domain_view in ./
domain_admin.inc - The main administration page, a list of active domains.
File
- domain_conf/
domain_conf.module, line 566 - Domain manager configuration options.
Code
function domain_conf_api($all = FALSE) {
$options = array();
$extra = module_invoke_all('domainconf');
if (!empty($extra)) {
foreach ($extra as $key => $value) {
if ($value['#domain_setting'] == TRUE || $all == TRUE) {
// Discard the #domain_setting flag; it is not needed.
unset($value['#domain_setting']);
// Set the $options array.
$options[$key] = $value;
}
}
}
return $options;
}