Permitted values in a select field type

29/02/2016

In Drupal 7:

// Load info field.
$info_field = field_info_field('field_name');
// Get allowed values from select field.
$options = list_allowed_values($info_field);

In Drupal 6:

$allowed_values = content_allowed_values(content_fields('field_name'));