function theme_video_formatter_video_nodelink in Video 6.4
Same name and namespace in other branches
- 6.5 video_formatter.inc \theme_video_formatter_video_nodelink()
1 theme call to theme_video_formatter_video_nodelink()
- theme_video_formatter_video_colorbox in ./video_formatter.inc
File
- ./video_formatter.inc, line 38
- Video formatter hooks and callbacks.
Code
function theme_video_formatter_video_nodelink($element, $imagecache = FALSE) {
if (empty($element['#item']['fid'])) {
return '';
}
module_load_include('inc', 'video', '/includes/video_helper');
$video_helper = new video_helper();
$thumbnail = $video_helper
->thumbnail_object($element);
$image = theme('video_image', $thumbnail, $thumbnail->alt, $thumbnail->title, '', TRUE, $imagecache);
$class = 'popups video video-nodelink video-' . $element['#field_name'];
return l($image, 'node/' . $element['#node']->nid, array(
'attributes' => array(
'class' => $class,
),
'html' => TRUE,
));
}