function theme_brightcove_field_entity_image_style in Brightcove Video Connect 7.2
Theme callback for imagecache image
Parameters
$element: Element with the Video ID.
Return value
Link HTML code.
1 string reference to 'theme_brightcove_field_entity_image_style'
- brightcove_field_theme in brightcove_field/
brightcove_field.module - Implementation of hook_theme().
File
- brightcove_field/
brightcove_field.formatters.inc, line 311 - Formatters for video field.
Code
function theme_brightcove_field_entity_image_style($variables) {
$video_id = isset($variables['element']['video_id']) ? $variables['element']['video_id'] : NULL;
list($style, $field) = explode('__', str_replace('entity_link_image_', '', $variables['display']['type']));
if (isset($video_id)) {
$video = brightcove_video_load($video_id);
$image = theme('image_style', array(
'style_name' => $style,
'path' => empty($video->{$field}) ? brightcove_get_default_image() : brightcove_remote_image($video->{$field}),
));
return theme("brightcove_field_formatter_entity_image_{$field}", array(
'element' => $variables['element'],
'image' => $image,
));
}
return '';
}