function key_get_providers_as_options in Key 7.2
Same name and namespace in other branches
- 7 key.module \key_get_providers_as_options()
Gets all key providers as options, for use in forms.
Parameters
bool $all: A flag indicating whether to include plugins with unmet dependencies.
bool $reset: A flag indicating whether to clear the plugin cache. Otherwise, stale data may be returned if plugin properties have changed.
Return value
array An array of key providers, with names for keys and labels for values.
1 call to key_get_providers_as_options()
- key_config_form in includes/
key.admin.inc - Form constructor for the key configuration edit form.
File
- ./
key.module, line 257 - Provides the ability to manage keys, which can be used by other modules.
Code
function key_get_providers_as_options($all = TRUE, $reset = FALSE) {
$providers = key_get_providers($all, $reset);
$options = array();
foreach ($providers as $name => $provider) {
$options[$name] = $provider['title'];
}
return $options;
}