You are here

function _photos_thumb_json in Album Photos 6.2

Same name and namespace in other branches
  1. 7.3 inc/photos.data.inc \_photos_thumb_json()

File

inc/photos.data.inc, line 122

Code

function _photos_thumb_json($image) {
  $t['file']['fid'] = $image['fid'];
  $t['file']['filename'] = $image['filename'];
  $t['user']['link'] = _photos_l('user/' . $image['uid']);
  $t['user']['name'] = $image['name'];
  $t['file']['album_title'] = $image['title'];
  $t['file']['album_link'] = _photos_l('photos/album/' . $image['pid']);
  if ($t['file']['des']) {
    $t['file']['des'] = $image['des'];
  }
  $t['original'] = _photos_l($image['original']);
  if (is_array($image['thumb'])) {
    foreach ($image['thumb'] as $key => $thumb) {
      $t['thumb'][$key] = _photos_l($thumb);
    }
  }
  return $t;
}