You are here

function flickrfield_field_info in Flickr 7

Same name and namespace in other branches
  1. 5 field/flickrfield.module \flickrfield_field_info()
  2. 6 field/flickrfield.module \flickrfield_field_info()

Implements hook_field_info().

File

field/flickrfield.module, line 24
Defines a Flickr field type.

Code

function flickrfield_field_info() {
  $sizes = array_keys(flickr_photo_sizes());
  return array(
    'flickrfield' => array(
      'label' => 'Flickr Photo',
      'description' => t('Store Flickr Photo or Photoset IDs and display the photos in nodes and views.'),
      'default_widget' => 'flickrfield',
      'default_formatter' => $sizes[0],
    ),
    'flickrfield_photoset' => array(
      'label' => 'Flickr photo set',
      'description' => t('Field for storing a reference to a Flickr photo set.'),
      'default_widget' => 'flickrfield_flickrid',
      'default_formatter' => 'photoset_primaryphoto_size' . $sizes[0] . '_nolink',
    ),
  );
}