function theme_image_gallery_img in Image 5
Same name and namespace in other branches
- 5.2 contrib/image_gallery/image_gallery.module \theme_image_gallery_img()
- 6 contrib/image_gallery/image_gallery.pages.inc \theme_image_gallery_img()
- 7 contrib/image_gallery/image_gallery.pages.inc \theme_image_gallery_img()
1 theme call to theme_image_gallery_img()
- theme_image_gallery in contrib/
image_gallery/ image_gallery.module - Theme a gallery page
File
- contrib/
image_gallery/ image_gallery.module, line 373
Code
function theme_image_gallery_img($image, $size) {
$width = $size['width'];
// We'll add height to keep thumbnails lined up.
$height = $size['height'] + 75;
$content = '<li';
if ($image->sticky) {
$content .= ' class="sticky"';
}
$content .= " style='height : {$height}px; width : {$width}px;'>\n";
$content .= l(image_display($image, IMAGE_THUMBNAIL), 'node/' . $image->nid, array(), NULL, NULL, FALSE, TRUE);
$content .= '<h3>' . l($image->title, 'node/' . $image->nid) . '</h3>';
if (variable_get('image_gallery_node_info', 0)) {
$content .= '<div class="author">' . t('Posted by: !name', array(
'!name' => theme('username', $image),
)) . "</div>\n";
if ($image->created > 0) {
$content .= '<div class="date">' . format_date($image->created) . "</div>\n";
}
}
$content .= "</li>\n";
return $content;
}