function content_handler_filter_many_to_one::allowed_values in Content Construction Kit (CCK) 6.2
Same name and namespace in other branches
- 6.3 includes/views/handlers/content_handler_filter_many_to_one.inc \content_handler_filter_many_to_one::allowed_values()
1 call to content_handler_filter_many_to_one::allowed_values()
- content_handler_filter_many_to_one::get_value_options in includes/
views/ handlers/ content_handler_filter_many_to_one.inc
File
- includes/
views/ handlers/ content_handler_filter_many_to_one.inc, line 25 - The subclass simply adds properties, for field-specific subclasses to use if they need to.
Class
- content_handler_filter_many_to_one
- @file The subclass simply adds properties, for field-specific subclasses to use if they need to.
Code
function allowed_values() {
$field = $this->content_field;
$function = $field['module'] . '_allowed_values';
if ($this->value_form_type == 'select') {
// Select elements accept multidimensional arrays to support optgroups.
$options = function_exists($function) ? $function($field) : content_allowed_values($field, FALSE);
// For selects, HTML should be filtered out and entities left unencoded.
// See content_allowed_values / content_filter_xss / filter_xss.
content_allowed_values_filter_html($options);
}
else {
$options = function_exists($function) ? $function($field) : content_allowed_values($field);
}
return (array) $options;
}