My gallery is completely made up of images under 1024x768 resolution, which means Flickr only assigns small, medium and original sizes. This means my images say "this photo is currently unavaliable", because dfGallery appears to only be able to view the large image size. Can you please insert an option or include documentation on how to set dfGallery to get different size images? Thanks in advance
Comments
Does anyone know if the last comment works? I've tried it and have gotten a JSON error. I'm currious what the "..." in the code is/was. If anyone can clarify this code and whether it's working, that would be great! Thanks.
-E
I added some code in Album_Manager.php:
in class CI_Album_Manager:
function flickr_get_sizes($photo_id){
$sizes=array();
$p_sizes=$this->_flickr_api_invoke('flickr.photos.getSizes',array("photo_id"=>$photo_id));
foreach ($p_sizes['sizes']['size'] as $z) {
$size[$z['label']] = array('width' => $z['width'], 'height' => $z['height'], 'source' => $z['source']);
}
return $size;
}
and in function process_album_flickr_set
into foreach ($page['photoset']['photo'] as $photo) {
$im_s=$this->flickr_get_sizes($photo['id']);
$image = array();
....
//$image['thumbnail'] = "http://farm$photo[farm].static.flickr.com/$photo[server]/$photo[id]_$photo[secret]_s.jpg";
//$image['image'] = "http://farm$photo[farm].static.flickr.com/$photo[server]/$photo[id]_$photo[secret]$max_size.jpg";
$image['thumbnail'] = $im_s['Square']['source'];
$image['image'] = $im_s['Large']['source'];
Just found out the image URL for the Original size is different to the URL dfGallery gets. For example, the file name for resized images is:
1234567890_20a0ed0067_b.jpg (large)
1234567890_20a0ed0067.jpg (medium)
1234567890_20a0ed0067_m.jpg (small)
1234567890_20a0ed0067_t.jpg (thumbnail)
1234567890_20a0ed0067_s.jpg (square)
But the original image file name is completely different, for example: 1234567890_761bd0b81e_o.jpg
The rest of the image urls are exactly the same.
Is there any possible way to get dfgallery to grab the original size images instead?
Post new comment