You are here

function theme_flickr_photo_box in Flickr 7

Same name and namespace in other branches
  1. 5 flickr.module \theme_flickr_photo_box()
  2. 6 flickr.module \theme_flickr_photo_box()

Theme Flickr photo box on a profile page.

1 theme call to theme_flickr_photo_box()
theme_flickr_photos in ./flickr.module
Theme Flickr photos on a profile page.

File

./flickr.module, line 823
The Flickr module.

Code

function theme_flickr_photo_box($variables) {
  $photo = $variables['photo'];
  $size = $variables['size'];
  $format = $variables['format'];
  $attribs = $variables['attribs'];
  $img = flickr_img($photo, $size, $attribs);
  $title = is_array($photo['title']) ? $photo['title']['_content'] : $photo['title'];
  $photo_url = flickr_photo_page_url($photo['owner'], $photo['id']);
  $output = "<div class='flickr-photo-box'>\n";
  $output .= "<a href='{$photo_url}'>{$img}</a>";
  $output .= "<a href='{$photo_url}'>";
  $output .= '<div class="flickr-photo-title">' . strip_tags($title) . "</div>\n";
  $output .= "</a>";
  $output .= "</div>\n";
  return $output;
}